I am trying to customize my themes, but also would like to use hyperref
to get quick links for ease of navigation. However, hyperref
seems to replace the color of all contents to its linkcolor
option.
The MWE shows that the section and subsection titles colors are blue but I actually sat them to orange and white.
The answer in Changing hyperlink color changes beamer section header colors proposes not using \hypersetup
, but I would like to use it anyway because colored equations referencing makes it easier to find equations quickly and see where they are used in text. Can I enable link coloring as normal but exclude sections and subsections?
Here is the result I want
\documentclass[aspectratio=169, xcolor={x11names}]{beamer}
\usecolortheme{seahorse}
\setbeamercolor{palette primary}{fg=black, bg=LemonChiffon2}
\setbeamercolor{palette secondary}{fg=white, bg=DarkOrange2}
\setbeamercolor{palette tertiary}{fg=black, bg=white}
\setbeamercolor{palette quaternary}{fg=black, bg=white}
\useoutertheme[]{miniframes}
\setbeamercolor{section in head/foot}{fg=DarkOrange2}
\setbeamercolor{subsection in head/foot}{fg=white}
\setbeamertemplate{section in head/foot shaded}[default][30]
\useinnertheme{inmargin}
\setbeamersize{sidebar width left=1cm, sidebar width right=1cm}
\setbeamersize{text margin left=0.5mm, text margin right=0.5mm}
\setbeamercovered{transparent=30}
\usepackage{hyperref}
\hypersetup{linkcolor=DodgerBlue3, colorlinks=true}
\begin{document}
\section{My Section}
\subsection{My Subsection}
\begin{frame}
contents
\end{frame}
\section{My Section}
\subsection{My Subsection}
\begin{frame}
contents
\end{frame}
\section{My Section}
\subsection{My Subsection}
\begin{frame}
contents
\end{frame}
\end{document}
\usepackage{hyperref}
, beamer already loads it for you