Can someone kindly help me understand how to implement dynamic features (e.g. enabling/disabling some property of displayed text on click) such as for example found in the left margin on page 4 of the microtype manual (Section 1).
The ability to make sidenotes like in the page referred to above is also very interesting and I would very much appreciate help on achieving that.
Text Formatting ⇒ Dynamic text features in PDF
Dynamic text features in PDF
Last edited by ushbayev on Thu Apr 28, 2011 6:21 pm, edited 1 time in total.
NEW: TikZ book now 40% off at Amazon.com for a short time.
- localghost
- Site Moderator
- Posts: 9202
- Joined: Fri Feb 02, 2007 12:06 pm
Dynamic text features in PDF
I suggest to ask the package author directly. Since in the CTAN directory of microtype there is no source to compile the manual directly, it would be difficult to find out by yourself how this feature has been integrated. I guess its done by Javascript. Feel free to report this new knowledge here.
Thorsten
Thorsten
How to make a "Minimal Example"
Board Rules
Avoidable Mistakes
¹ System: TeX Live 2025 (vanilla), TeXworks 0.6.10
Board Rules
Avoidable Mistakes
¹ System: TeX Live 2025 (vanilla), TeXworks 0.6.10
Re: Dynamic text features in PDF
Thank you, Thorsten
I have written an email to Robert Schlicht, and as soon I get an answer, I will post the relevant knowledge here.
Anuar
I have written an email to Robert Schlicht, and as soon I get an answer, I will post the relevant knowledge here.
Anuar
Dynamic text features in PDF
This is the relevant part of the response I got from Robert Schlicht if anyone is interested:
For the dynamic content I use the PDF feature of layers (optional content groups). The source is in microtype.dtx, which you should already have or find on ctan.
The relevant code starts with the line:
% the samples in the introduction, utilising nested optional content groups (aka. layers):
It's all quite ad-hoc, unfortunately, and not easily re-usable, but maybe you can get the idea. I've long wanted to turn this into a package
of its own, but never got around doing it. In the meantime, a package called ocgtools has cropped up, which should allow similar tricks, I haven't tried it though.
- localghost
- Site Moderator
- Posts: 9202
- Joined: Fri Feb 02, 2007 12:06 pm
Re: Dynamic text features in PDF
You can find the *.dtx file when following the link in my last reply. With the hints from the author you should be able to find the concerned parts of the code.
How to make a "Minimal Example"
Board Rules
Avoidable Mistakes
¹ System: TeX Live 2025 (vanilla), TeXworks 0.6.10
Board Rules
Avoidable Mistakes
¹ System: TeX Live 2025 (vanilla), TeXworks 0.6.10
Dynamic text features in PDF
Thanks, I've figured that out already 
By the way the ocgtools package does many desired features, I've tried it out today.
Thanks for the help again.

By the way the ocgtools package does many desired features, I've tried it out today.
Thanks for the help again.