[
https://issues.apache.org/jira/browse/PDFBOX-5539?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17682225#comment-17682225
]
Tilman Hausherr commented on PDFBOX-5539:
-----------------------------------------
I had a few minutes and looked, it's not as difficult as I thought. I still
don't have the time, but here are some thoughts if I (or somebody else) has the
time some day. Whatever needs to be done should start in
{{PDFDebugger.initTree()}} if my "third alternative view" suggestion is used.
{{PDFTreeModel}} would need another constructor and modifications in the three
large methods and in {{isLeaf}}, to handle something that is a bit like
{{DocumentEntry}} (that one is the for the page view). The menu would have to
be changed as well (that should be easier).
[~lehmi] getXrefTable() returns a map from object key to offset. How can we
obtain an COSObject from COSObjectKey? With getObjectFromPool()? This code
shows meaningful output:
{code}
Map<COSObjectKey, Long> xrefTable = document.getDocument().getXrefTable();
for (COSObjectKey objectKey : xrefTable.keySet())
{
COSObject cosObject = document.getDocument().getObjectFromPool(objectKey);
System.out.println(cosObject.getObject().getClass().getName());
}
{code}
> Show CRT in PDFDebugger
> -----------------------
>
> Key: PDFBOX-5539
> URL: https://issues.apache.org/jira/browse/PDFBOX-5539
> Project: PDFBox
> Issue Type: New Feature
> Components: Utilities
> Affects Versions: 2.0.27, 3.0.0 PDFBox
> Reporter: Moritz Flöter
> Priority: Major
>
> For analyzing potentially erroneous PDFs it would be quite helpful to be able
> to show the CRT (Cross Reference Table/xref) and navigate to its entries.
> Some software does provide rather technical (and therefore quite precise)
> information about errors in the PDF files mentioning the object number in the
> pdf file instead of page numbers. With PDF-Debugger, I currently have to
> navigate the Document Catalog Tree structure to find the object. Furthermore,
> navigating the tree structure does enable one to view unreferenced objects.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]