Re: [iText] compression




"Ingo R. Homann" <ihomann_spam@xxxxxx> wrote in message
news:4404295a$0$13795$9b4e6d93@xxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Hi,

I am generating 2 documents with iText. I want to test, if the documents
are identical. (Background: I'm doing a refactoring and want to test if
the functionality remains the same.)

The documents look identical, but "diff" says that they are not.
Unfortunately, it doesn't tell me *what* differences are there, because
the files are binary.

My first idea was that there is a timestamp in the PDF that is not
displayed but of course is a difference.

I tried to filter the PDFs using "hexdump -C", but when comparing the
results with diff, it is obvious that there are *many* differences (or
perhaps it is only a small "offset-difference" that diff does not realize
correctly).

Anyhow, that kind of comparison does not work.

So, my question is: (How) can i tell iText to save a document
"uncompressed", so that the differeneces are more obvious and readable?

Or is there a completely different approch to my problem rather than
extract the ASCII out of the PDF at the end?

You might get better answers if you tried posting this question on the iText
forum (at the iText website). You may even find that this has been answered
already in the archive of that forum. The developers of iText are very
active in helping users solve problems with iText.

Here on comp.lang.java.programmer, you will find that most people have never
used iText and even some of us who have used it, have never tried to do file
comparisons between different versions of documents.

--
Rhino


.



Relevant Pages

  • [iText] compression
    ... I am generating 2 documents with iText. ... I tried to filter the PDFs using "hexdump -C", but when comparing the results with diff, it is obvious that there are *many* differences. ... Or is there a completely different approch to my problem rather than extract the ASCII out of the PDF at the end? ...
    (comp.lang.java.programmer)
  • Re: Headers & Footers
    ... Bill Segraves wrote: ... I used Pdftk quite a bit until I took the plunge into iText. ... Click on the "free" PDF Tools ... date to the bottom of the PDF). ...
    (comp.text.pdf)
  • Re: Kleinere iText Fragen
    ... Das ganze ist mittlerweile ziemlich gewachsen und sehr praktisch im Vergleich zu dem umständlichen Initialiseren, wie iText es eigentlich erwartet... ... Im>> Prinzip musst Du per setPageEvent einen eigenen Event-Handler>> installieren, der über den PDFContentByte bei einem Seitenwechsel>> direkt per lowlevel-Routinen einen Text ausgibt. ... Wie gesagt mache ich das über meine Factory-Methoden. ... PDF funktioniert aber sehr gut (wenn man sich erstmal ...
    (de.comp.lang.java)
  • Re: Kleinere iText Fragen
    ... lowlevel-Routinen einen Text ausgibt. ... Package), aber der Anspruch, auf dem iText aufbaut, nämlich auch andere ... PdfPTable und eine PdfTable. ... Leider unterstützt das aber nur das, was sowohl PDF als auch RTF ...
    (de.comp.lang.java)
  • Re: Kleinere iText Fragen
    ... Ich erzeuge eigentlich nie direkt die iText-Klassen, sondern habe mir eine ganze Reihe von Factory-Methoden zusammengestellt, die z.B. auch diverse Default-Parameter verwalten und ... Das ganze ist mittlerweile ziemlich gewachsen und sehr praktisch im Vergleich zu dem umständlichen Initialiseren, wie iText es eigentlich erwartet... ... PDF funktioniert aber sehr gut (wenn man sich erstmal ... Ich habe damit zumindest keine Probleme, aber der Zeilenabstand wird in meinen Factory-Methoden (hatte ich schon erwähnt, dass ich sowas ...
    (de.comp.lang.java)