Do you own a Debenu Quick PDF Library 12/11/10/9/8/7? Upgrade to Debenu Quick PDF Library 13!

Foxit Quick PDF Library

Frequently Asked Question:

Return to FAQ Index

Do you have problems with missing text, images and shapes or inverted and backwards text?

Question

Do you have problems with missing text, images and shapes or inverted and backwards text?

Answer

Sometimes a PDF's page will have certain drawing commands that change the co-ordinate system or other graphics properties.

When new content is added to the existing content the graphics state is not what is expected and strange results can happen.

The solution is to first combine the layers into one and then "encapsulate" the layer. This adds a "save state" command to the start of the page and a "restore state" command at the end.

Once this has been done, any extra content added to the page should appear as expected.

Here's a quick example (using c#, but it works A-OK in Delphi too):

qp.LoadFromFile("Anomaly.pdf");
qp.CombineLayers();
qp.EncapsulateLayer();
qp.DrawText(100, 500, "Watermark");
qp.SaveToFile("Anomaly.pdf");

© 2015 Debenu & Foxit. All rights reserved. AboutBuyContactBlogNewsletterSupportFAQProduct UpdatesForum