1

I am trying to compile a big beamer template (CCM beamer template 3) on overleaf. But because of the time out (lots of tikz figures) I am forced to switch to something else so I am trying TEXMaker.

The problem I have is the following: I have 4 .sty files and one .tex files in a folder, when I compile my .tex file on overleaf, I have the desired output (a simple blank frame with the text "Is someone here?") . But, when running the exact same file with the exact same directory organization on TEXMaker, the compiling does not output any pdf and I have a new error. In short, it works on overleaf but not on TEXMaker.

Is it that I have to configure something in particular to make it work on TEXMaker?
Did I mess up something (I have been using latex since a week so I am a complete beginner)?

The new error mentioned above are the following :

! Paragraph ended before \setbeamertemplate was complete.

There is one error both present on overleaf and TEXMaker (I don't know how to solve it):

! Too many }'s.

Both errors are at : beamerinnerthemeccm3.sty ; line 40

Versions used : MiKTeX-pdfTeX 4.15 (MiKTeX 23.5) overleaf - Tex Live 2022

Here are my files :

test.tex :

\documentclass{beamer}


\usepackage[utf8]{inputenc}

\usepackage[T1]{fontenc}
\usepackage[heuristica,vvarbb,bigdelims]{newtxmath}
\renewcommand*\oldstylenums[1]{\textosf{#1}}
\usepackage[sfdefault,scaled=.85]{FiraSans}

\usetheme{ccm3}

\begin{document}


\section{ Hello?} 

\begin{frame}
    Is someone here?

\end{frame}


\end{document}

beamercolorthemeccm3.sty:

\mode<presentation>


\setbeamercolor*{title page header}{fg=mostazaccm}
\setbeamercolor*{author}{fg=white}
\setbeamercolor*{date}{fg=white}
\setbeamercolor*{institute}{fg=white}
\setbeamercolor*{sectiontitle}{fg=white}
\setbeamercolor*{frametitle}{fg=mostazaccm}
\setbeamercolor*{framesubtitle}{fg=amarilloccm}
\setbeamercolor*{section in head/foot}{fg=white}
\setbeamercolor*{author in head/foot}{fg=white}
\setbeamercolor*{date in head/foot}{fg=white}

\setbeamercolor*{item}{fg=azulccm}

\setbeamercolor{block title}{use=structure,fg=white,bg=gristexto}
\setbeamercolor{block body}{fg=black,bg=gristexto!35}

\mode<all>

beamerinnerthemeccm3.sty:

\mode<presentation>


\defbeamertemplate*{title page}{CCM3}[1][]
{
    \begin{textblock}{4}(7,1)
  \end{textblock}

    \vspace*{3.2cm}
  
  
    \begin{beamercolorbox}[center,wd=\paperwidth,sep=1pt]{title page header}
      \usebeamerfont{title}{\setstretch{1.1} \scalefont{1.5} \inserttitle}\par%
    \end{beamercolorbox}
    
    \vspace*{0.01cm}
    
    \begin{beamercolorbox}[center,wd=\paperwidth]{date}
    \usebeamerfont{date}\insertdate%
    \end{beamercolorbox}
  
  
  \vspace*{\fill}
   \vspace*{1cm}
  \begin{beamercolorbox}[center,wd=\the\paperwidth]{author}
    {\usebeamerfont{author} \insertauthor}%
  \end{beamercolorbox}
  
  \begin{beamercolorbox}[center,wd=\the\paperwidth]{institute}
    {\usebeamerfont{institute}\insertinstitute}
  \end{beamercolorbox}
}

\setbeamertemplate{title page
%A definir la apareciencia de listas y tabla de contenidos
\setbeamertemplate{items}[circle]
\setbeamercolor{section in toc}{fg=black}
\setbeamertemplate{section in toc}{{\Huge \color{mostazaccm} \oldstylenums{\inserttocsectionnumber}.}~\inserttocsection}
\setbeamercolor{subsection in toc}{fg=gray}
\setbeamertemplate{subsection in toc}{\hspace{1.45em}{\color{gray}\rule[0.3ex]{3pt}{3pt}}~\inserttocsubsection\par}

\mode<all>

beamerouterthemeccm3.sty

\mode<presentation>

\setbeamerfont{sectiontitle}{size=\huge, shape=\scshape}

\defbeamertemplate*{frametitle}{ccm3}[1][]
{
  \begin{beamercolorbox}[wd=\the\paperwidth,ht=1.9cm]{frametitle}
    \begin{tikzpicture}
    \useasboundingbox (0,0) rectangle(\the\paperwidth,1.4);
    
      \ifx\insertframesubtitle\@empty%
       {\node[anchor=west, mostazaccm , font=\huge] at (0.85,0.82){\textbf{\insertframetitle}};}
       \else%
       {\node[anchor=west, mostazaccm, font=\huge] at (0.85, 1.02){ \textbf{\insertframetitle}};%
       \node[anchor=west, mostazaccm , font=\large] at (0.85, 0.53){\insertframesubtitle};}%
       \fi
     \end{tikzpicture}
   \end{beamercolorbox}
   \vskip-0.5cm
}


\defbeamertemplate*{sidebar left}{sidebar theme}
{
\ifnum\thepage>2

\vspace*{\fill}
\hspace{-0.25\paperwidth}\colorbox{azulccm}{\makebox[1.5\paperwidth][c]{\scriptsize \textcolor{white}{\begin{tabular}{
  p{\dimexpr.5\paperwidth-2\tabcolsep-1.3333\arrayrulewidth}% column 1
  |p{\dimexpr.25\paperwidth-2\tabcolsep-1.3333\arrayrulewidth}% column 2
  |p{\dimexpr.25\paperwidth-2\tabcolsep-1.3333\arrayrulewidth}|% column 3
  }
     \insertauthor & \centering \insertsection  & \raggedleft \insertframenumber\,/\,\inserttotalframenumber
\end{tabular}}}}

\fi
}

\mode<all>

beamerthemeccm3.sty

\mode<presentation>

%Paquete requerido
\RequirePackage{tikz}
\RequirePackage{graphicx}
\RequirePackage{amssymb}
\RequirePackage{xcolor}
\RequirePackage{lastpage}
\RequirePackage{setspace}
\RequirePackage{scalefnt}

\RequirePackage[absolute, overlay]{textpos}
\definecolor{rojotexto}{HTML}{A21916}
\definecolor{gristexto}{HTML}{B2B2B2}
\definecolor{amarilloccm}{HTML}{FDC600}
\definecolor{mostazaccm}{HTML}{C99C00}
\definecolor{azulccm}{HTML}{003062}


\usecolortheme{CCM3}
\useinnertheme{CCM3}
\useoutertheme{CCM3}

\setbeamertemplate{navigation symbols}{}
\setbeamertemplate{blocks}[rounded][shadow=true]

\mode<all>
3
  • Welcome to TeX.SE, thanks for including lots of details. Just to check about the errors, Overleaf tries to force through a document even if there are errors so the errors you are seeing in TeXmaker might be occurring on Overleaf, there should be a box or red thing in the bottom right corner of Overleaf showing errors when it compiles, are the errors there or are they solely in TeXmaker? Could you also share what version of TeX you are using in Overleaf (2022, 2021 etc) and on your local TeXmaker please, they could be different and it helps narrow down issues :)
    – JamesT
    Commented Jul 21, 2023 at 9:59
  • Do you have to use this template? It does some strange things ... like the empty textblock environment on the title page. Why adding it and then not putting anything inside? Commented Jul 21, 2023 at 10:16
  • Consider accepting the provided answer. Commented Apr 16 at 19:13

1 Answer 1

1

The line \setbeamertemplate{title page in your inner theme just ends in the middle of nowhere. I assume it should be something like \setbeamertemplate{title page}[CCM3] instead?

\documentclass{beamer}


\usepackage[utf8]{inputenc}

\usepackage[T1]{fontenc}
\usepackage[heuristica,vvarbb,bigdelims]{newtxmath}
\renewcommand*\oldstylenums[1]{\textosf{#1}}
\usepackage[sfdefault,scaled=.85]{FiraSans}

\mode<presentation>

%Paquete requerido
\RequirePackage{tikz}
\RequirePackage{graphicx}
\RequirePackage{amssymb}
\RequirePackage{xcolor}
\RequirePackage{lastpage}
\RequirePackage{setspace}
\RequirePackage{scalefnt}

\RequirePackage[absolute, overlay]{textpos}
\definecolor{rojotexto}{HTML}{A21916}
\definecolor{gristexto}{HTML}{B2B2B2}
\definecolor{amarilloccm}{HTML}{FDC600}
\definecolor{mostazaccm}{HTML}{C99C00}
\definecolor{azulccm}{HTML}{003062}


\mode<presentation>


\setbeamercolor*{title page header}{fg=mostazaccm}
\setbeamercolor*{author}{fg=white}
\setbeamercolor*{date}{fg=white}
\setbeamercolor*{institute}{fg=white}
\setbeamercolor*{sectiontitle}{fg=white}
\setbeamercolor*{frametitle}{fg=mostazaccm}
\setbeamercolor*{framesubtitle}{fg=amarilloccm}
\setbeamercolor*{section in head/foot}{fg=white}
\setbeamercolor*{author in head/foot}{fg=white}
\setbeamercolor*{date in head/foot}{fg=white}

\setbeamercolor*{item}{fg=azulccm}

\setbeamercolor{block title}{use=structure,fg=white,bg=gristexto}
\setbeamercolor{block body}{fg=black,bg=gristexto!35}

\mode<all>



\mode<presentation>


\defbeamertemplate*{title page}{CCM3}[1][]
{
    \begin{textblock}{4}(7,1)
  \end{textblock}

    \vspace*{3.2cm}
  
  
    \begin{beamercolorbox}[center,wd=\paperwidth,sep=1pt]{title page header}
      \usebeamerfont{title}{\setstretch{1.1} \scalefont{1.5} \inserttitle}\par%
    \end{beamercolorbox}
    
    \vspace*{0.01cm}
    
    \begin{beamercolorbox}[center,wd=\paperwidth]{date}
    \usebeamerfont{date}\insertdate%
    \end{beamercolorbox}
  
  
  \vspace*{\fill}
   \vspace*{1cm}
  \begin{beamercolorbox}[center,wd=\the\paperwidth]{author}
    {\usebeamerfont{author} \insertauthor}%
  \end{beamercolorbox}
  
  \begin{beamercolorbox}[center,wd=\the\paperwidth]{institute}
    {\usebeamerfont{institute}\insertinstitute}
  \end{beamercolorbox}
}

\setbeamertemplate{title page}[CCM3]
%A definir la apareciencia de listas y tabla de contenidos
\setbeamertemplate{items}[circle]
\setbeamercolor{section in toc}{fg=black}
\setbeamertemplate{section in toc}{{\Huge \color{mostazaccm} \oldstylenums{\inserttocsectionnumber}.}~\inserttocsection}
\setbeamercolor{subsection in toc}{fg=gray}
\setbeamertemplate{subsection in toc}{\hspace{1.45em}{\color{gray}\rule[0.3ex]{3pt}{3pt}}~\inserttocsubsection\par}

\mode<all>



\mode<presentation>

\setbeamerfont{sectiontitle}{size=\huge, shape=\scshape}

\defbeamertemplate*{frametitle}{ccm3}[1][]
{
  \begin{beamercolorbox}[wd=\the\paperwidth,ht=1.9cm]{frametitle}
    \begin{tikzpicture}
    \useasboundingbox (0,0) rectangle(\the\paperwidth,1.4);
    
      \ifx\insertframesubtitle\@empty%
       {\node[anchor=west, mostazaccm , font=\huge] at (0.85,0.82){\textbf{\insertframetitle}};}
       \else%
       {\node[anchor=west, mostazaccm, font=\huge] at (0.85, 1.02){ \textbf{\insertframetitle}};%
       \node[anchor=west, mostazaccm , font=\large] at (0.85, 0.53){\insertframesubtitle};}%
       \fi
     \end{tikzpicture}
   \end{beamercolorbox}
   \vskip-0.5cm
}


\defbeamertemplate*{sidebar left}{sidebar theme}
{
\ifnum\thepage>2

\vspace*{\fill}
\hspace{-0.25\paperwidth}\colorbox{azulccm}{\makebox[1.5\paperwidth][c]{\scriptsize \textcolor{white}{\begin{tabular}{
  p{\dimexpr.5\paperwidth-2\tabcolsep-1.3333\arrayrulewidth}% column 1
  |p{\dimexpr.25\paperwidth-2\tabcolsep-1.3333\arrayrulewidth}% column 2
  |p{\dimexpr.25\paperwidth-2\tabcolsep-1.3333\arrayrulewidth}|% column 3
  }
     \insertauthor & \centering \insertsection  & \raggedleft \insertframenumber\,/\,\inserttotalframenumber
\end{tabular}}}}

\fi
}

\mode<all>


\setbeamertemplate{navigation symbols}{}
\setbeamertemplate{blocks}[rounded][shadow=true]

\mode<all>


\begin{document}


\section{ Hello?} 

\begin{frame}
    Is someone here?

\end{frame}


\end{document}

enter image description here

(I added a gray background to the image, otherwise the white font wouldn't be visible)

3
  • Thank you so much. The fast build works in texmaker. I spent hours looking for this, I can't believe it was this kind of mistake. Nevertheless, I think I understand better how overleaf works now, I thought that overleaf corrected the errors in the .tex file but I suppose it does during the build and does not modify the .tex file. Is that right?
    – P.O.
    Commented Jul 21, 2023 at 11:47
  • @P.O. You're welcome! Commented Jul 21, 2023 at 11:48
  • @P.O. By default Overleaf runs in non-stop mode, which means the compiler will attempt to keep going when it encounters an error. If you hit a timeout, this could be because of an accumulation of errors that the compiler could not handle. The recommendation is to set the compile mode to "stop on first error" and to fix the errors as they are encountered. overleaf.com/learn/how-to/… Commented Jul 21, 2023 at 16:29

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .