2006/6/2, bruno <[EMAIL PROTECTED]>:
Nope. Name sounds fake ;)... at least it's not me - this is my first try in generating pdfs programmatically. After your email I tried to register in my email client with news://comp.text.pdf but it didn't work.
I use PDFGraphics2D because I have what I want to put in the pdf already in Java and I use a Grapgics2D object of a JComponent to display it on screen (althought for displaying I scale down the images to 72 dpi) - for printing I would like to have 300 dpi.
I know that - I am doing it already...
Yes, I know...quite nice method, instead of doing it "by hand" - that's why I asked, if there is a method to set e.g. 300 dpi and everything is done automatically by iText. E.g. Adobe Acrobat has something like this - I believe it is called Profiles: so a profile for screen, web, printing, press etc...depending on the profile the images are scaled down and compressed to jpg etc...
Cheers,
Andy
Andreas Schmidt wrote:
> I guess that I want to create my PDFs with PDFGraphics2D is clear.
No, it isn't clear why you want to use PdfGraphics2D.
If you are the so called 'John Smith' from news://comp.text.pdf
you have an existing PDF document with images, I can't understand
what this has to do with PdfGraphics2D.
Maybe you aren't the 'John Smith' from news://com.text.pdf
and in that case you got me confused by asking a very similar question.
Nope. Name sounds fake ;)... at least it's not me - this is my first try in generating pdfs programmatically. After your email I tried to register in my email client with news://comp.text.pdf but it didn't work.
I use PDFGraphics2D because I have what I want to put in the pdf already in Java and I use a Grapgics2D object of a JComponent to display it on screen (althought for displaying I scale down the images to 72 dpi) - for printing I would like to have 300 dpi.
iText can change the images into a Jpeg with a certain quality
if you create your Graphics2D object using this method:
http://itextdocs.lowagie.com/docs/com/lowagie/text/pdf/PdfContentByte.html#createGraphics(float,%20float,%20boolean,%20float)
I know that - I am doing it already...
The quality parameter is a float between 0f (0%) and 1f (100%).
By converting all images to Jpegs and choosing a quality of for instance
0.1f
you will see that the file size will be reduced enormously.
Yes, I know...quite nice method, instead of doing it "by hand" - that's why I asked, if there is a method to set e.g. 300 dpi and everything is done automatically by iText. E.g. Adobe Acrobat has something like this - I believe it is called Profiles: so a profile for screen, web, printing, press etc...depending on the profile the images are scaled down and compressed to jpg etc...
Cheers,
Andy
_______________________________________________ iText-questions mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/itext-questions
