black frames around tooltips in OSX Preview

I would like to get popups for acronyms giving their meaning at mouse hover.

The following works with pdflatex when viewed with acroread:

\usepackage{pdfcomment}
\usepackage{acronym}
\def\acp#1{\pdftooltip{\acs{#1}}{\acl{#1}}}


Hovering over an acronym as \acp{ADS} indeed shows its meaning.

It doesn't work in evince. So be it.

My big problem is that in MacOS Preview it works, but one sees ugly bad frames around each acronym making the text quite unreadable. My readers are likely to be Mac types, making this no go.

• Feb 5 '15 at 1:02

Kevin C: many thanks! The final item in your first link pointed me to the following solution, using another command from pdfcomment.sty:

%% popup acronym expansion

\gdef\acp#1{\pdfmarkupcomment[markup=Underline,color={1 1 1},author={{#1}}]{{#1}}{{\acl{#1}}}}


which together with \newacro{acronym}{full expansion} of the acronym-package indeed does the job, when the PDF is viewed in acroread and Adobe reader for Mac OS X. It does not open the popup in evince, okular, or Preview (Mac OS X built-in tool), but at least it does not generate the ugly black boxes in Preview, that I had from \pdftooltip. So I can stick these popups now in any PDF I produce and if my readers are smart enough to use Acrobat, they will get the popup explanation at any acronym they hover over. Should be standard in scientific papers! If they use another viewer, at least there is no fatal interference.

I hesitated about underlining such hoverable acronyms in blue, but chose not to mark the pop-ability at all. Let the reader discover by herself. Hence defining the white color.

Apologies for not knowing how to typeset the LaTeX code above. Typing in this site is fighting my emacs habits.

• Acronyms should not have under lengths, so it should not be a problem. But in this case you better use opacity=0 Feb 5 '15 at 18:19
• Next problem: \pdfmarkupcomment doesn't seem to work with \input or \include files. Apparently soul.sty then does not write a .upb file. So the above only works for simple files. Feb 7 '15 at 21:09
• Yes, it's a known problem and reported to the author of soulpos, but not fixed yet Feb 8 '15 at 7:54
• Feb 8 '15 at 8:05