|
Acrobat Display. The default overprint settings are
subtly different in Acrobat than in other common viewers like
Chrome.
Acrobat allows you to choose whether to simulate overprint or
not. The settings for this are under the Page Display preferences.
The default value for this is "Only For PDF/X Files" so if a file
is seen to be is PDF/X, then overprint will be automatically set to
true. This is a little different from ABCpdf, Chrome and other
common viewers, which have a default value of false.
If you wish to detect PDF/X files so that you can set the
overprint flag, simply use a function of the following form.
bool IsPdfX(Doc doc) {
var cat = doc.ObjectSoup.Catalog;
var xmp = cat.Metadata != null ? cat.Metadata.GetText() : "";
if (xmp.Contains("GTS_PDFXVersion"))
return true;
var trailer = doc.ObjectSoup.Trailer;
var info = cat.Resolve(Atom.GetItem(trailer.Atom, "Info")) as DictAtom;
return info != null && info.Contains("GTS_PDFXVersion");
}
Function IsPdfX(ByVal doc As Doc) As Boolean
Dim cat = doc.ObjectSoup.Catalog
Dim xmp = If(cat.Metadata IsNot Nothing, cat.Metadata.GetText(), "")
If xmp.Contains("GTS_PDFXVersion") Then Return True
Dim trailer = doc.ObjectSoup.Trailer
Dim info = TryCast(cat.Resolve(Atom.GetItem(trailer.Atom, "Info")), DictAtom)
Return info IsNot Nothing AndAlso info.Contains("GTS_PDFXVersion")
End Function
|