I wanted to have coloured citation in beamer. I have used the following code,
\documentclass[12pt]{beamer}
\usetheme{CambridgeUS}
\usepackage[utf8]{inputenc}
\usepackage[english]{babel}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage[T1]{fontenc}
\usefonttheme[onlymath]{serif}
\usepackage{amssymb}
\usepackage{graphicx}
\usepackage{bm}
\usepackage{lmodern}
\usepackage{color}
%\usepackage{multimedia}
%\usepackage{movie15}
%\usepackage{tikz}
%\tikzset{
% every overlay node/.style={
% draw=black,anchor=north west,
% },
%}
%\def\tikzoverlay{%
% \tikz[baseline,overlay]\node[every overlay node]
%}%
%%for Justifying in itemised
\usepackage{ragged2e}
\let\olditem=\item%
\renewcommand{\item}{\olditem \justifying}%
%--------------------------------------------------
%for objective theorm enviroment
\makeatletter
\def\th@mystyle{%
\normalfont % body font
\setbeamercolor{block title example}{bg=red!80,fg=white}
\setbeamercolor{block body example}{bg=red!20,fg=black}
\def\inserttheoremblockenv{exampleblock}
}
\makeatother
\theoremstyle{mystyle}
\newtheorem*{Objective}{Objective}
%%-------------------------
\usepackage{csquotes}% Recommended
\usepackage[backend=biber,
style=authoryear,
]{biblatex}
\DeclareLanguageMapping{american}{american-apa}
\addbibresource{DP.bib}
\makeatletter
\let\abx@macro@citeOrig\abx@macro@cite
\renewbibmacro{cite}{%
\bibhyperref{%
\let\bibhyperref\relax\relax%
\abx@macro@citeOrig%
}%
}
\let\abx@macro@parenciteOrig\abx@macro@parencite
\renewbibmacro{parencite}{%
\bibhyperref{%
\let\bibhyperref\relax\relax%
\abx@macro@parenciteOrig%
}%
}%
\let\abx@macro@textciteOrig\abx@macro@textcite
\renewbibmacro{textcite}{%
\bibhyperref{%
\let\bibhyperref\relax\relax%
\abx@macro@textciteOrig%
}%
}%
\makeatother
%\usepackage[colorlinks]{hyperref}
\hypersetup{colorlinks,
citecolor=blue,
linkcolor=.,
menucolor=white,
filecolor=pink,
anchorcolor=yellow
}
\begin{document}
\begin{frame}{Multiple Model Switching Controllers}
\begin{itemize}
\item \textcite{greytak2007exponentially} gave control scheme which switches between Manifold Convergence Controller and LQR controller for underactuated Autonomous Surface Vessel (river) with just a propeller and rudder.
\item \textcite{hassani2012multiple} proposed multiple model adaptive controller consisting of four LQG controller. The controller switching occurs to compensate for different sea state.
\item \textcite{brodtkorb2014dynamic} demonstrated a control scheme with four different PID and sensor based observer for switching between them. Switching logic is based on spectral analysis of motion.
\item \textcite{hassani2013novel} simulated used Robust Multiple Model Adaptive Dynamic Positioning switching Controller designed using mixed $ \mu $ methodology for different sea state.
\end{itemize}
\end{frame}
\end{document}
The problem is the ending bracket when using \textcite{}
is not the same colour as hyperlink. What might be the issue. I'm doing this on sharelatex.
Best Answer
Based on https://tex.stackexchange.com/a/25972/36296 you could use:
Please note that you neither need
color
norgraphicx
with beamer, as beamer already provides this functionality.