0

is it possibile to add the progression dots specific to the subsection?

More specifically i would like to add the dots under the corresponding subsection.

enter image description here

Here there can be found the codes I used to produce the above.

\documentclass{beamer}
\usetheme{Szeged}

\setbeamertemplate{headline}{%
\leavevmode%
\begin{beamercolorbox}[wd=0.9\paperwidth,ht=2.5ex,dp=1.125ex, center] {palette quaternary}%
\insertsectionnavigationhorizontal {\paperwidth}{\hskip0pt plus1fill}{\hskip0pt plus1fill}
 \end{beamercolorbox} \\
\begin{beamercolorbox}[wd=0.9\paperwidth,ht=2.5ex,dp=1.125ex]{}%
\insertsubsectionnavigationhorizontal {\paperwidth}{\hskip0pt plus1fill}{\hskip0pt plus1fill}\\
\end{beamercolorbox}\\ 
  \vspace*{-0.025cm}
  \begin{beamercolorbox}[colsep=1pt]{lower separation line head}
  \end{beamercolorbox}}


\begin{document}
\section{Section 1}

\subsection{subsec. 1.1}
\begin{frame} \frametitle{Slide 1}\end{frame}
\begin{frame} \frametitle{Slide 2}\end{frame}

\subsection{subsect. 1.2}
\begin{frame} \frametitle{Slide 3}\end{frame}
\begin{frame} \frametitle{Slide 4} \end{frame}


\section{ Section 2}

\subsection{ subsection 2.1}
\begin{frame} \frametitle{Slide 5}\end{frame}
\begin{frame} \frametitle{Slide 6}\end{frame}

\subsection{ subsection 2.2}
\begin{frame} \frametitle{Slide 7}\end{frame}

\end{document}
  • The MWE does not compile. ! Missing \endcsname inserted. <to be read again> \hbox l.17 \begin{document} – user36296 Dec 3 '17 at 14:23
1

I might have came up with a solution: it is rather un-elegant but I have played around with some codes I found here trying to make them working the way I wanted

\documentclass{beamer}
\usetheme{Szeged}




\makeatletter

\newcount\beamer@xoff
\newcount\beamer@prev@section
\newcount\beamer@prev@miniframes
\beamer@xoff=0
\beamer@prev@section=0
\beamer@prev@miniframes=0

\def\insertsubsectionnavigationhorizontalminiframes#1#2#3{%
  \hbox to #1{{%
    \usebeamerfont{subsection in head/foot}\usebeamercolor[fg]    {subsection in head/foot}%
    \beamer@currentsubsection=0%
    \def\sectionentry##1##2##3##4##5{}%
    \def\slideentry##1##2##3##4##5##6{%
      \ifnum##1>\beamer@prev@section%
        \beamer@xoff=##3\relax%
        \beamer@prev@miniframes=0\relax%
      \fi
      \ifnum##6=\c@part\ifnum##1=\c@section%
      \ifnum##2>\beamer@currentsubsection%
      \beamer@xoff=0\relax%
      \beamer@currentsubsection=##2%
      \box\beamer@sectionbox\hskip1.875ex plus1fill%
      \ifnum\beamer@prev@miniframes>0\relax%
        \beamer@tempdim=\beamer@boxsize%
        \multiply\beamer@tempdim by \beamer@prev@miniframes%
        \advance\beamer@tempdim by -\beamer@boxsize%
        \advance\beamer@tempdim by 2pt%
        \ifnum##2>1%
          \advance\beamer@tempdim by 1.875ex%
        \else
          \advance\beamer@tempdim by -\beamer@boxsize%
        \fi
      \else
        \beamer@tempdim=0pt%
      \fi
      \setbox\beamer@sectionbox=
      \hbox{\def\insertsubsectionhead{\kern\beamer@tempdim##5}%
         \def\insertsectionheadnumber{##1}%
         \def\insertsubsectionheadnumber{##2}%
         \def\insertpartheadnumber{##6}%
         \ifnum\c@subsection=##2%
        \beamer@link(##4){{\usebeamertemplate{subsection in head/foot}}}\else%
        \beamer@link(##4){{\usebeamertemplate{subsection in head/foot shaded}}}\fi}%
      \ht\beamer@sectionbox=1.875ex%
      \dp\beamer@sectionbox=0.75ex%
      \else%
      \beamer@prev@miniframes=##3%
      \fi%
              \setbox0=\hbox{\insertsectionhead\unskip}\ifdim\wd0>0pt\ifnum##3>0%
      \beamer@xpos=##3\relax%
  \advance\beamer@xpos by -\beamer@xoff%
  \hbox to 0pt{%
    \beamer@tempdim=0.5pt%
    \raise\beamer@tempdim\hbox{%
      \ifnum##2>0%
        \beamer@tempdim=\beamer@boxsize%
        \multiply\beamer@tempdim by\beamer@xpos%
        \advance\beamer@tempdim by -\beamer@boxsize%
        \advance\beamer@tempdim by 2pt%
        \advance\beamer@tempdim by \wd\beamer@sectionbox%
      \else%
        \beamer@tempdim=\beamer@boxsize%
        \multiply\beamer@tempdim by\beamer@xpos%
        \advance\beamer@tempdim by 1.875ex%
      \fi%
      \kern\beamer@tempdim\hbox{\beamer@link(##4){%
          \usebeamerfont{mini frame}%
          \ifnum\c@section=##1%
            \ifnum\c@subsection=##2%
              \usebeamercolor[fg]{mini frame}%
              \ifnum\c@subsectionslide=##3%
                \usebeamertemplate{mini frame}%
              \else%
                \usebeamertemplate{mini frame in current subsection}%
              \fi%
            \else%
              \usebeamercolor{mini frame}%
              \usebeamertemplate{mini frame in other subsection}%
            \fi%
          \else%
            \usebeamercolor{mini frame}%
            \usebeamertemplate{mini frame in other subsection}%
          \fi%
        }}}\hskip-10cm plus 1fil%
      }\fi\fi%
  \else%
  \fakeslideentry{##1}{##2}{##3}{##4}{##5}{##6}%
  \fi\fi%
  \beamer@prev@section=##1%
  \ignorespaces}%
#2\hskip.3cm\setbox\beamer@sectionbox=\hbox{}%
\hskip-1.875ex plus-1fill\dohead%
\box\beamer@sectionbox\hfil\hskip.3cm%
#3}}}

\setbeamercolor{mini frame}{parent=subsection in head/foot}



\makeatother

\setbeamertemplate{headline}{%
\leavevmode%
\begin{beamercolorbox}[wd=\paperwidth,ht=2.5ex,dp=1.125ex]{palette quaternary}%
 \insertsectionnavigationhorizontal{\paperwidth}{}{}
  \end{beamercolorbox}\\

   \begin{beamercolorbox}[wd=\paperwidth,ht=1.5ex,dp=1.125ex]{}%
\insertsubsectionnavigationhorizontalminiframes{0.9\paperwidth}{}{}
\end{beamercolorbox}%
  \\ 

  \vspace*{-0.025cm}
  \begin{beamercolorbox}[colsep=1pt,color=CLE]{lower separation line head}
  \end{beamercolorbox}
}

\begin{document}
\section{Section 1}

\subsection{subsec. 1.1}
\begin{frame} \frametitle{Slide 1}\end{frame}
\begin{frame} \frametitle{Slide 2}\end{frame}

\subsection{subsect. 1.2}
\begin{frame} \frametitle{Slide 3}\end{frame}
\begin{frame} \frametitle{Slide 4} \end{frame}

\section{ Section 2}

\subsection{ subsection 2.1}
\begin{frame} \frametitle{Slide 5}\end{frame}
\begin{frame} \frametitle{Slide 6}\end{frame}

\subsection{ subsection 2.2}
\begin{frame} \frametitle{Slide 7}\end{frame}

\end{document}

It is a trial-and-error solution, rather than something logical. Take it as is!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.