I wanted to change the name in my beamer slide from Part to Theme.
So in the Google BOK if found:
\renewcommand*{\partname}{Theme}
I could not get to work. Then I start to switch off (%) everything that I added and found that:
\usepackage[english]{babel}
is the holder of the key.
An MWE:
\documentclass[compress,infolines,smaller]{beamer}
%\usepackage[english]{babel}
\useinnertheme[shadow=true]{rounded}
\usecolortheme{beaver}
\renewcommand*{\partname}{Theme}
\begin{document}
\AtBeginLecture{
\begin{frame}
\titlepage
\end{frame}
}
\part{Title}
\begin{frame}<beamer>
\partpage
\end{frame}
\section{test1}
\begin{frame}
Test
\end{frame}
\end{document}
Is there a way to get passed this?
Best Answer
This has obviously to do with how
babel
manages the "fixed tags" such as\partname
.It stores them in a macro called
\captions<language>
(in this case\captionsenglish
) that is executed as part ofor
The
\selectlanguage
command for the main language of the document is issued together\begin{document}
. Thus your\renewcommand
does nothing, because it's overridden by what's done by\selectlanguage{english}
.babel
has a provision for this:is what you're looking for.
Also
\AtBeginDocument{\renewcommand{\partname}{Theme}}
would work unless you loadbabel
with more than one language and issue some\selectlanguage
command in the document. To make an example:would result in
This wouldn't happen with the
\addto\captionsenglish
approach.