I am looking to change the font of only the links in the LaTeX as italics.
\hypersetup{%
linkcolor=black,
font=italics,
unicode%
}
I am looking to change the font of only the links in the LaTeX as italics.
\hypersetup{%
linkcolor=black,
font=italics,
unicode%
}
It's possible to modify the definition of colorlink to change the font to italics, similar to the existing frenchlinks option (which changes the font to small caps). Note that the definition should be provided after \begin{document}, otherwise hyperref can overwrite the modifications with the default values.
MWE:
\documentclass{article}
\usepackage[colorlinks]{hyperref}
\begin{document}
\makeatletter
\def\Hy@colorlink#1{\begingroup\fontshape{it}\selectfont}%
\makeatother
See \autoref{sec:first}.
\section{First section}
\label{sec:first}
\end{document}
Result:
\fontshape{\itdefault} in case the italic shape of the current font isn't called it.
– Phelype Oleinik
Jun 28 '18 at 11:34
frenchlinks (on which my answer is based) uses sc and not scdefault - but that doesn't mean that it's right of course :)
– Marijn
Jun 28 '18 at 12:04
\documentclass{article} \usepackage[garamond]{mathdesign} \usepackage[frenchlinks]{hyperref} \begin{document} \section{test}\label{sec:test} See~\ref{sec:test} \end{document}. I get a warning: Font shapeT1/mdugm/m/sc' undefined(Font) using T1/mdugm/m/n' instead. Should it be reported to the maintainer?
– Phelype Oleinik
Jun 28 '18 at 12:10
if used just once or twice,
\textit{\url{www.url.com}}
or
\textit{\href{https://url.com}{URL}}
& and #...
– Phelype Oleinik
Feb 10 '20 at 13:16
MWEof you coding? – MadyYuvi Feb 10 '20 at 13:24