I have a PDF document which I want to add hyperlinks and tooltips to.
My goal is for a number of hyperlinks to be added to the text, each of which
links to some location in the document, but when the mouse is hovered over
the link, a brief summary of the destination appears in a popup instead (so
that the user doesn't have to actually follow the link). Basically, the
same thing that could easily be done with onmouseover in HTML and that a
million webpages do. The trouble is that I can't figure out how to make
this work in the PDF document.
I've looked at Link annotations, and they have the "Contents" key defined
for the Link annotation dictionary, however, Adobe viewer does not display
the contents of the Link's Contents key.
I tried adding the "PA" dictionary with the required keys to the Link
annotation as (I think) was suggested here:
http://programming.itags.org/tex/134379/
but nothing happened.
I've looked at Square annotations, and while they work great for the popup
summary, there doesn't appear to be any way to make them do anything when
clicked. Also, they leave small icons at their location, but I might be
able to fix that (it's clear from the text where the links are, the icons
aren't needed or wanted).
Text annotations used alone worked similar to Square, they just looked
different. They also had icons associated with them, but those can be made
invisible.
Putting a Link and a Square in the same place results in the Link not
functioning.
I tried putting an Additional Action dictionary in the Link annotation to do
something on mouse enter/exit, but it turns out those are only supported for
Widget and Screen.
I thought I might be able to replace the Link annotation with a pair of
annotations, a Screen to define the actions and a Text or Square to hold the
popup. My text annotations ignored the hidden flag unfortunately and were
always visible, even if it was set on them manually. Oddly, they obeyed the
NoView flag - but there is no way to control the NoView flag from an
annotation event (ToggleNoView is not usable here as the Text annotation has
to be shrunk very small to make room for the Screen annotation that actually
has the working link in it).
The promisingly named Popup annotation seems to be compatible only with
"markup" annotations, and neither Screen nor Link are considered markup
annotations, thus I can not use it. (Also, I'm not sure if editing the
Popup can be disabled).
When used with the Screen widget, my Square annotations just flickered
briefly when the mouse first touched the area, they didn't stay visible.
FreeText seems like it will obey the Hidden flag but it is a lot more
trouble because I need to specify the exact location where the text appears,
and I don't want to. All the other popup annotations just kind of picked a
place to display the text and it looked fine. Also, I haven't yet
absolutely confirmed that it works with a Screen widget to hide and show it.
I am running out of ideas. I would think that what I am doing should be
possible within the PDF format, but is it really? Does anybody have other
suggestions, or an unencrypted PDF that does this already, that I could
examine?
------------------------------------------------------------------------------
Enable your software for Intel(R) Active Management Technology to meet the
growing manageability and security demands of your customers. Businesses
are taking advantage of Intel(R) vPro (TM) technology - will your software
be a part of the solution? Download the Intel(R) Manageability Checker
today! http://p.sf.net/sfu/intel-dev2devmar
_______________________________________________
Pdfedit-support mailing list
Pdfedit-support@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/pdfedit-support