This content has been marked as final.
Show 3 replies
-
1. Re: Need help with PDDocEnumOCGs
(malkyt) Sep 2, 2008 5:27 AM (in response to andrejusc)That call returns you the optional content groups, which is the dictionary that contains the information such as
Required
Type - Must be "OCG"
Name - Name (as displayed to the user)
Optional
Intent - what the groups intent is (normally "View" or "Design")
Usage - Controls the state of the group.
This dictionary does not contain information on what content is contained in a OCG, you should read 4.10 of the PDF reference and it will explain how to find which elements are included in a OCG.
HTH
Malky -
2. Re: Need help with PDDocEnumOCGs
andrejusc Sep 2, 2008 5:48 AM (in response to andrejusc)In that mentioned 4.10 we have:
"Individual content elements in a document specify the optional content group or
groups that affect their visibility (see Section 4.10.2, Making Graphical Content
Optional). Any content whose visibility can be affected by a given optional content
group is said to belong to that group."
Does it mean that during enumeration of content elements I need additionally check their belonging to OCG? What API call should I use for that? Is it PDEElementGetOCMD?
Thanks in advance! -
3. Re: Need help with PDDocEnumOCGs
(Aandi_Inston) Sep 2, 2008 6:06 AM (in response to andrejusc)>Does it mean that during enumeration of content elements I need additionally check their belonging to OCG?
Yes. There is no path from OCG to a list of elements; just elements
may belong to an OCG. If there were to be an "enumerate elements in
OCG" call, it would have to be done as "enumerate all elements; check
membership; return if included".
I don't know if there is a specific PDFEdit API, or whether you just
have to track property lists.
Aandi Inston
