# How to break text in subsection heading in Beamer using Copenhagen theme?

\documentclass[hyperref={pdfpagelabels=false}]{beamer}
\usetheme{Copenhagen}
\begin{document}
\title[Title]{}
\author[Author]{}
\institute[Test]{}
\date{\today}
\subject{Informatics}
{ \begin{frame}
\titlepage
\end{frame} }
\section{Introduction}
\subsection{Test subsection with a really long title and some additional words for the example}
\begin{frame}
\frametitle{Table}
Test Section
\end{frame}
\end{document}

• Now as it can bee seen that in 2nd slide the text of subsection does not appear completely and it does not shift to the next, i was having this problem, if anyone can help me out. – Ahmed Feb 24 '14 at 7:14

You can use the optional argument like

\subsection[test sub section]{Test subsection with a really long title and
some additional words for the example}


Full code:

\documentclass[hyperref={pdfpagelabels=false}]{beamer}
\usetheme{Copenhagen}
\begin{document}
\title[Title]{}
\author[Author]{}
\institute[Test]{}
\date{\today}
\subject{Informatics}
\begin{frame}
\titlepage
\end{frame}
\section{Introduction}
\subsection[test sub section]{Test subsection with a really long title
and some additional words for the example}
\begin{frame}
\frametitle{Table}
Test Section
\end{frame}
\end{document}


The optional argument is used for running content.

If you want to display the entire title (bad idea IMHO), here is an ugly way:

\documentclass[hyperref={pdfpagelabels=false}]{beamer}
\usetheme{Copenhagen}

{%
\leavevmode%
\end{beamercolorbox}%
\end{beamercolorbox}%
}

\begin{document}
\title[Title]{}
\author[Author]{}
\institute[Test]{}
\date{\today}
\subject{Informatics}
\begin{frame}
\titlepage
\end{frame}
\section{Introduction}
\subsection{\protect\parbox{0.5\linewidth}{Test subsection with a really long title and some additional words for the example}}
\begin{frame}
\frametitle{Table}
Test Section
\end{frame}
\end{document}


• But I want to display the title of whole subsection {Test subsection with a really long title and some additional words for the example} – Ahmed Feb 24 '14 at 7:42
• In this case only the text [test sub section] will be displayed. – Ahmed Feb 24 '14 at 7:44
• @Ahmed: It will be a bad idea to display big headings in the header. Doesn't look nice. – user11232 Feb 24 '14 at 7:46
• Any idea to keep this in a fixed width as given. Or to break the title in two lines. I know it doesn't look nice, but its need of the time. – Ahmed Feb 24 '14 at 7:48
• Yeah, you are right, the height of headline is increase, but it gives extra line spacing which makes the look of slide not that much good. – Ahmed Feb 24 '14 at 7:56