# Tag Info

## New answers tagged hyperref

2

The problem with your used document class MastersDoctoralThesis is that it defined already the call of hyperref. If you add \usepackage[hyperfootnotes=false]{hyperref} you get an option class clash error for package hyperref. Just use \PassOptionsToPackage{hyperfootnotes=false}{hyperref} in the line before \documentclass (see line 11 of MWE). With this ...

1

This should really be solved by hyperref, but here's a hack that seems to work (for the colon); however, the best thing, when babel-french is involved, is not to use colons in labels. \documentclass{article} \usepackage[T1]{fontenc} \usepackage[utf8]{inputenc} \usepackage[french]{babel} \usepackage{etoolbox} \usepackage{hyperref} \makeatletter % patch ...

2

Following recommendations I will post a brief answer. Christian Hupfer suggested to use ocgx package, to be found here https://www.ctan.org/pkg/ocgx . As a minimal working example consider \documentclass{article} \usepackage{ocgx} \begin{document} \switchocg{name_int}{Button} \begin{ocg}{name_ext}{name_int}{1} This text is either hidden or revealed ...

4

The mandatory argument to \hyperref is actually managed by the auxiliary macro \label@@hyperref and it would be wrong to redefine \hyperref, because this disrupts all the setup the command must do for neutralizing special characters in link references. \documentclass{article} \usepackage{amsfonts} \usepackage{etoolbox} \usepackage{hyperref} % last one ...

2

Set the corresponding \hyperref entry with the font declaration \upshape: \documentclass{article} \usepackage{hyperref,amsfonts} \newtheorem{theorem}{Theorem} \begin{document} \begin{theorem}\label{def:bounded_sequence} Some bounded sequence theorem. \end{theorem} \begin{theorem} Each \hyperref[def:bounded_sequence]{\upshape bounded sequence} in ...

2

Something like this? \documentclass[10pt,a5paper]{report} \usepackage{xcolor} \usepackage{fontspec} \usepackage{lipsum} \usepackage[linktoc=all,hidelinks,bookmarksnumbered,pagebackref,xetex]{hyperref} \begin{document} \chapter{Chapter 1}\hypertarget{chapter::\theHchapter}{}% \lipsum[1-2] \section{Section 1} \lipsum[3-5] \section{Section ...

1

I propose a possible tool to achieve what you want. This defines 3 new page numbering styles. They were not written by me, but I can't remember who did, probably at my request, to solve some problem of old-style typography. The 3 styles are: scroman (roman style with small caps), osroman (like roman, except if page number in consecutive is, the last i is ...

0

enotez works well, but we had a problem when it was used together with a large collection of style files. Instead, defined a simple mod of endnotes that worked in that environment. Also used two options where you can click either on the note number or on the text marked with that number. The latter seems useful for small font displayed on a tablet when it is ...

1

Since rsc.bst does not define a dedicated DOI macro we need to add that ourselves. Find rsc.bst copy it to a location LaTeX can find it and rename it to, say, rsc-hcn.bst Open rsc-hcn.bst and locate FUNCTION {format.doi} replace it by FUNCTION {format.doi} { use.doi.all { doi empty$'skip$ { link.doi { ...

1

BTW, I don't know what package \Raggedleft comes from. This is why a full MWE is better than snippets. \documentclass{article} \usepackage{marginnote} \usepackage{tikz} \usepackage{hyperref} \newcommand{\evidcirlce}[1]{ \raisebox{1pt}{% \begin{tikzpicture}[baseline=(C.base)]%% \node[draw,circle,inner ...

3

Sure you can do it. \hypertarget is overlay aware, so you can say something like \hypertarget<4>{label}{\beamerbutton{I'm on the fourth slide}} to place the target just on the fourth slide of a frame and then use elsewhere \hyperlink{label}{\beamerbutton{I jump to fourth slide of next frame}} to activate a button that will take you to the fourth ...

2

This is due to the special field format removecomma used in \renewbibmacro*{journal} and defined as \DeclareFieldFormat{removecomma}{\mkbibnocomma{#1}}. Specifically, the space is introduced by the \scantokens command in \newcommand*\mkbibnocomma[1]{% \begingroup \catcode\, = 9\relax \scantokens{#1}% \endgroup } Refer also to @egreg's answer ...

3

\edef\@currentlabel{#1} must be replaced by \protected@edef\@currentlabel{#1} otherwise the expansion of the argument fails. \documentclass{article} \usepackage{fontspec} % xelatex ext font support \usepackage{enumitem} % Add easy custom list support \usepackage{menukeys} % Demonstrate labeling of macros \usepackage{hyperref} % Add ref support ...

1

\documentclass{article} \usepackage{auto-pst-pdf} \usepackage{hyperref} \usepackage{pst-barcode} \begin{document} \href{http://example.com}{% \begin{pspicture}(1in,1in) \psbarcode[]{http://example.com}{}{qrcode} \end{pspicture}} \end{document} works fine with pdflatex --shell-escape <file> If you still need xelatex to run, you can create the ...

1

"that’s kind of cheating and works in this case but will fail if chapters can start on any page (which is not the case for my current project). You could make your comment into an answer for the record, since it will be much more legible" (Tobi Sep 1 at 21:24) There should have been line-breaks in the code in my comment, but in comments those are ...

1

In case of pdfTeX, the box depth and height is taken from the current box, which is large, because of the math stuff in the same line. The box for the link can be reduced by putting the link into another box. However, the contents of the box is no longer broken across lines and spaces inside the box are fixed and do not shrink or stretch anymore. The ...

1

Inserting a modified \thechapter command just before the bookmark writing operation works (at least for a small document). \documentclass{book} \usepackage[bookmarksnumbered]{hyperref} \usepackage{xpatch} \let\origthechapter\thechapter \makeatletter \xpatchcmd{\addcontentsline}{% \Hy@writebookmark{\csname the#2\endcsname}% {#3}% ...

1

tufte-common.def sets \hypersetup{% pdfborder = {0 0 0}, bookmarksdepth = section, citecolor = DarkGreen, linkcolor = DarkBlue, urlcolor = DarkGreen, }% when hyperref is loaded. So in order to get the borders back, we can just restore the default \hypersetup{pdfborder = {0 0 1}} See also What do the first two numbers in the pdfborder option ...

0

As far as I see (and keepeing in mind that there are several pdf viewer available): No, at last it is not possible. Reasons: Showing effects when one is hovering with the curser/mouse ofer a text is not done by all pdf viewers. So you can't be sure if the reader will see it because you do not know which viewer the reader uses. The solutions I know ...

0

As I mentioned in my comment, I can not compile your code. So I rearrange it on the way, as I usually manage similar situation. any package in which is used in document I load only one package with option (as caption, subfig,...) I load separately Your construction of figure is very unusual and I doubt that the can be compiled (well, some comment report ...

1

I had the same issue her and I found this article solving the problem: Using setspace package breaks footnotes link In short, include the setspace package before hyperref package.

3

I think you missunderstand here something. Package hyperref is designed to add an clickable link into the internet to allow to open a special web site or to open a mail program to send an email to the defined adress. A computer, exactly a operating system (Linux, Unix, OS x or Windows), can this only do with the information which protocol is used for ...

3

Usually a simple redefinition is not as easy, because \url wants to read its argument with changed catcodes. However, redefines \url a little to support some "escaped" characters like \#, thus in this case using \# instead of # works: \documentclass{article} \usepackage[colorlinks]{hyperref} \begin{document} See `Q3.4: Can RANDOM.ORG help me win the ...

4

If you don't load hyperref, LaTeX will not make hyperlinks. However, viewers such as Preview, Skim and the TeXShop one use the Apple PDF libraries and, unfortunately, try to find URL and email addresses in the text. Compiling the simple example file \documentclass{article} \begin{document} alice@bob.com \end{document} will show a mailto: link when the ...

1

If you know the Javascript to validate a date or an email (I don't) you can adapt this example that I put together by reverse engineering some examples in the Acrobat specification (you won't find this in the hyperref documentation and I couldn't find any preexisting example in the context of hyperref). \documentclass{article} \usepackage{hyperref} ...

0

You can use \nolinkurl on the links you want to hide.

1

This colors the reference, not the frame: \documentclass{article} \usepackage[x11names]{xcolor} \usepackage{hyperref} \hypersetup{ colorlinks=true, citecolor=SpringGreen4 } \begin{document} \cite{Lam94} \bibliographystyle{alpha} \bibliography{biblio} \end{document}

0

Many thanks to Heiko and the others. That is perfect. This is just to add eqref to the answer: \documentclass[10pt,a4paper]{article} \usepackage[T1]{fontenc} \usepackage{lmodern} \usepackage{hyperref} \usepackage{twoopt} \newcommandtwoopt*{\myeqref}[3][][]{% \hyperref[{#3}]{% \ifx\\#1\\% Equation~% \else #1~% \fi (\ref*{#3})% ...

2

\hyperref with the optional argument can be used to link to labels with arbitray text: \hyperref[<label>]{<arbitrary text>} The star form \ref* sets a reference without additional link, since the link is already set by \hyperref. The following example defines \figref for figure references. The optional argument takes the subfigure number, the ...

2

As a bandaid fix you could redefine the \cref command and explictely add the hyperlink, which will give you the desired result. \documentclass{beamer} \usepackage{cleveref} \let\chyperref\cref % Save the orginal command under a new name \renewcommand{\cref}[1]{\hyperlink{#1}{\chyperref{#1}}} % Redefine the \cref command and explictely add the hyperlink. ...

1

As mentioned in the comments: The problem is probably due to an outdated hyperref and xetex. It can be avoided by adding \leavevmode (or something else that starts a paragraph) before the \ref.

Top 50 recent answers are included