Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

Using the hyperref package, is there a way to make the border around the link or whatever larger so that it is not tightly sticked to the text? Like adding some margin between the text and the box around it?

share|improve this question
1  
If you don't get an answer you can ask the question at comp.text.tex. The maintainer of packages hyperref is very active in this newsgroup. –  Marco Daniel Oct 28 '11 at 19:12
    
Should the border push the adjacent text and stuff away or cut through it? –  Andy Oct 28 '11 at 20:43
    
@Andy push away –  behzad.nouri Oct 29 '11 at 17:00

1 Answer 1

I am not sure what are are trying to accomplish. In principle, you can get that behavior with \marginbox from the adjustbox package. I made a small example for a hyperlink that shows the described feature.

\documentclass{book}

\usepackage[pdfborder={1 1 1},pdfborderstyle={/S/U/W 1}]{hyperref}
\usepackage{adjustbox}


\begin{document}
Foo \href{http://tex.stackexchange.com/questions/32994/hyperref-how-to-make-pdfborder-larger-or-add-some-margin-between-the-border}{\marginbox{2pt}{bar}} what?
\end{document}  

example link

If all links should automatically have that behavior, some more work is necessary.

share|improve this answer
    
i want to do exactly what you have done, but i do not know how to use this workaround for things like \ref{01.fig} –  behzad.nouri Oct 28 '11 at 19:57
    
@runnerup: Do you only want this to be done for things like \ref{...}? –  Werner Oct 28 '11 at 21:20
    
@Werner for some documents, yes –  behzad.nouri Oct 29 '11 at 17:01

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.