You should have a look at the AddImageToPDF example, and the ImageToPDF tool in the source code download.

You have have to adjust the page size in "new PDPage".

However all this is a terrible idea because it will take a long time and use a lot of memory (you need 300dpi at least, better 1200dpi). Why not tell the people that annotations are important?

An alternative would be to support the "flattening" of annotations like we do for Acroform fields.

Tilman

Am 10.06.2018 um 14:24 schrieb JZ Q:
Hi Tilman,

thank you for the quick reply. The link you posted will convert each page
to png file. How do I merge the converted png into a simple PDF witch one
PNG per page?

On Sun, Jun 10, 2018 at 8:20 AM, Tilman Hausherr <[email protected]>
wrote:

Am 09.06.2018 um 23:54 schrieb JZ Q:

Hi Tilman,

In my case, the client prints the PDF using the ctrl+P and then pick
printers. All the annotations have the printing flag set, but if the user
does not select print "document and markup" option, the markups are not
printed at all.

Is there any way to convert all the contents including annotation to
image?

https://stackoverflow.com/questions/23326562/apache-pdfbox-
convert-pdf-to-images

Tilman


So regardless of what the end user selects, everything will be printed on
paper. Thanks.

On Thu, Jun 7, 2018 at 12:37 PM, Tilman Hausherr <[email protected]>
wrote:

PDFBox 2.0 doesn't create the appearance stream for annotations, so many
annotations won't be printed at all. Besides, some annotations don't have
the printing flag set.

Your text is unclear, how do you print? With PDFBox or with another tool?

Tilman

Am 07.06.2018 um 18:15 schrieb JZ Q:

Hi everyone,
I created PDF document with markups (annotation), but when I send it to
client for printing, some of them does not select to print markup, hence
missing the annotations on the printout.

Is there anyway to convert any markup to be a printable image? what i am
doing now is to print it to virtual printer called "microsoft pdf" and
then
save the file. It is better to do it automatically.

Thanks in advance for any suggestion.


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]





---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to