[pdftex] Re: hiding optional content

RS w.m.l at gmx.net
Thu Jan 12 17:46:47 CET 2006

On 06.01.2006 02:52, I wrote:
> I've been experimenting with optional content groups (OCGs), putting
> them on top of each other with only one being visible at a time
> (which one can be chosen by the user). Now, a PDF viewer that does
> not support PDF 1.5 will display all layers at the same time. What I
> would like to find is a way to make the optional content -- well...
> optional. Is there any trick to hide the OCGs from older viewers?

It turns out that there is a ridiculously simple solution to this
dilemma: Just place another OC group containing a white box in the last
but one layer, whose state is set to OFF. Old viewers will ignore the
OCG state, hence the white box will hide all underlying layers; recent
viewers will follow it and not display the white box, so that all layers
are (potentially) visible. Just what I needed.


More information about the pdftex mailing list