3

Good evening everyone!

I'm writing you because I face problem while I'm trying to create my own Beamertheme. Everything was fine, I have my Beamercolortheme, Beameroutertheme and Beamertheme.

I just face a layout problem with my title page. More precisely with the last institute address (formatting option are not the same as previous as visible on the following picture.

enter image description here

Strange "newlines" did appear. I tried another theme (Annarbor) and the problem disappeared. I tried to replace \\ by \newline, but the space between institute adress was too high.

I'll reproduce a part of my codes, if anybody could give me a piece of advice, any correction or any track, it will be greatly appreciated!

beameroutertheme :

  \makeatletter

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
% Background 
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\setbeamertemplate{background canvas}{%
  \ifnum\c@framenumber=1%1ere slide
  \includegraphics[width=\paperwidth,height=\paperheight]{Mainframe}
  \else%Autres slides
  \includegraphics[width=\paperwidth,height=\paperheight]{frame}
  \fi%
}


%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
% Page de titre
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\defbeamertemplate*{title page}{Title}{
  \vspace{0.25 \paperheight}%
  {\color{black}\huge\bf\textsc{\inserttitle}}
  \ifx\insertsubtitle\@empty\\[\baselineskip]
  \else{\\\color{firm@gray1}\insertsubtitle}\\[\baselineskip]
  \ifx\insertdate\@empty\\[\baselineskip]
  \else{\\\color{firm@gray3}\insertdate}\\[\baselineskip]
  \ifx\insertauthor\@empty\\[\baselineskip]
  \else{\\\color{firm@gray1}\insertauthor}\\[\baselineskip]
   \ifx\insertinstitute\@empty\\[\baselineskip]
  \else{\\\color{firm@gray1}\tiny{\insertinstitute}}\\[\baselineskip]
  \fi
  \vfill
}



%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
% Footline
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\defbeamertemplate*{footline}{theme}{
  \ifnum\c@framenumber=1%1ere slide
 \else%Autres slides
  \begin{beamercolorbox}[wd=\paperwidth,ht=5 pt,leftskip=0.1cm,rightskip=0.25cm,dp=1ex]{structure.fg}%
   \color{black}\insertshortauthor\hspace{8em}\color{black}\insertshorttitle \hspace{8em} \color{black}\insertshortdate\hfill \color{black}\insertframenumber{}\par
  \end{beamercolorbox}
  \fi%
}

\makeatother

Tex file :

\documentclass[compress,10pt]{beamer}
% version imprimable pour assistance
%\documentclass[10pt, green, handout]{beamer}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage[frenchb]{babel} % le document est en français
\usepackage{amsmath}
\usepackage{graphicx}       % pour insérer des figures
\usepackage{lmodern}
\usepackage{xcolor}         % pour définir plus de couleurs
\usetheme{Theme developped}  %Applique le theme développé (ce dernier doit être present dans le repertoire courant)
\setbeamertemplate{blocks}[rounded][shadow=true]
%-------------------------------------------------------------------------------
% Quelques options pdf
%-------------------------------------------------------------------------------
\hypersetup{
pdfpagemode = FullScreen, % afficher le pdf en plein écran
pdfauthor   = {Auteur},%
pdftitle    = {Titre principal},%
pdfsubject  = {},%
pdfkeywords = {Science,Impact},%
pdfcreator  = {PDFLaTeX,emacs,AucTeX},%
pdfproducer = {}%
}
%-------------------------------------------------------------------------------
\newcommand{\aua}{Melville Charlebois} % Prénom et Nom Auteur 1
\newcommand{\auasht}{M.Charlebois} % Prénom et Nom Auteur 1 (version courte pied de page)
\newcommand{\aub}{Inès Rousseau} % Prénom et Nom Auteur 2
\newcommand{\auc}{Cerise Patel} % Prénom et Nom Auteur 3
\newcommand{\aud}{Arnaud Séguelin} % Prénom et Nom Auteur 4
\newcommand{\aue}{Nathalie Du Trieux} % Prénom et Nom Auteur 5

\title[Lorem ipsum dolor sit amet]{Lorem ipsum dolor sit amet} % Le titre doit être court, il sera complété le cas échéant par un sous-titre. Le texte entre crochet apparaîtra en pied de page 
\subtitle{Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aliquam gravida} % N'est pas obligatoire si le titre se suffit à lui même
\author[\auasht \ \textit{et al.}]{\aua\inst{1}, \aub\inst{2}, \auc\inst{3}, \aud\inst{2} \& \aue\inst{1}} % Le texte entre crochet apparaîtra en pied de page 
\institute{
\par \inst{1} Laboratoire de la Fraise - Unité KFC - 39 Rue du Maréchal Auguste - Frais (Spain)
\par \inst{2} Laboratoire de biologie moléculaire - Unité cytK - 12 Impasse de l'Opéra - Marseille (France)
\par \inst{3} Laboratoire de la Faille des Falaises et des Ferry - Unité Joudon King François - 39 Avenue du Maréchal Auguste - Trifouilly-les-Oies (France)
} 
\date[17/11/2014]{Lundi 17 Novembre 2014}
%-------------------------------------------------------------------------------
\begin{document}
%-F1------------------------------------------------------------------------------
\begin{frame}
  \titlepage
\end{frame}
\section{Debut}
% --------- Sommaire ---------
\section*{Sommaire}
\begin{frame}{Sommaire}
\tableofcontents
\end{frame} 
%-F2------------------------------------------------------------------------------
\section{Présentation}
\begin{frame}{Première page}
\end{frame}  
\end{document}

Well, I hope that my question was clear enough. Thank you for taking time helping me to fix this tiny bug

7
  • 1
    Please provide the community with a minimal working example (MWE) that starts with \documentclass and ends with \end{document}. We want to copy-and-paste-and-compile and see exactly what you're seeing, thereby replicating the problem locally. Could you do that?
    – Werner
    Nov 17, 2014 at 20:52
  • Hi Werner, for sure I'll do that shortly!
    – Fackito
    Nov 17, 2014 at 21:38
  • Where can one find the Anses theme?
    – Werner
    Nov 17, 2014 at 22:02
  • Actually its the theme I'm developping
    – Fackito
    Nov 17, 2014 at 22:21
  • this is just a shot in the dark. try putting a blank line or \par after the last \inst and before the closing brace. this may be an artifact of a larger type used in an earlier line. Nov 17, 2014 at 22:22

1 Answer 1

3

The problem is caused by ending the final paragraph of the institutes without ending the paragraph. This means that when the paragraph is ended, the line spacing for that final paragraph is applied according to the current font size, which is normal. On the other hand, the first two paragraphs are ended while the font size is tiny and so the line spacing appropriate to that font size is applied.

I had to comment parts of your code and define some colours in order to persuade it to compile. I've also changed \bf, which was deprecated about 20 years ago, to \bfseries.

\documentclass[compress,10pt]{beamer}
% version imprimable pour assistance
%\documentclass[10pt, green, handout]{beamer}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage[frenchb]{babel} % le document est en français
\usepackage{amsmath}
\usepackage{graphicx}       % pour insérer des figures
\usepackage{lmodern}
\usepackage{xcolor}         % pour définir plus de couleurs
% \usetheme{Anses}  %Applique le theme Anses (ce dernier doit être present dans le repertoire courant)
\makeatletter
\colorlet{firm@gray1}{gray!50}
\colorlet{firm@gray3}{gray!75}

% \setbeamertemplate{background canvas}{%
%   \ifnum\c@framenumber=1%1ere slide
%   \includegraphics[width=\paperwidth,height=\paperheight]{example-image-a}
%   \else%Autres slides
%   \includegraphics[width=\paperwidth,height=\paperheight]{example-image-b}
%   \fi%
% }

\defbeamertemplate*{title page}{Title}{
  \vspace{0.25 \paperheight}%
  {\color{black}\huge\bfseries\textsc{\inserttitle}}
  \ifx\insertsubtitle\@empty\bigskip\par
  \else{\par\color{firm@gray1}\insertsubtitle\bigskip\par}
  \ifx\insertdate\@empty\par
  \else{\par\color{firm@gray3}\insertdate\bigskip\par}
  \ifx\insertauthor\@empty\par
  \else{\par\color{firm@gray1}\insertauthor\bigskip\par}
  \ifx\insertinstitute\@empty\par
  \else{\par\color{firm@gray1}{\tiny\insertinstitute\par}}
  \fi
  \vfill
}

\defbeamertemplate*{footline}{theme}{
  \ifnum\c@framenumber=1%1ere slide
  \else%Autres slides
  \begin{beamercolorbox}[wd=\paperwidth,ht=5 pt,leftskip=0.1cm,rightskip=0.25cm,dp=1ex]{structure.fg}%
    \color{black}\insertshortauthor\hspace{8em}\color{black}\insertshorttitle \hspace{8em} \color{black}\insertshortdate\hfill \color{black}\insertframenumber{}\par
  \end{beamercolorbox}
  \fi%
}
\setbeamertemplate{blocks}[rounded][shadow=true]
%-------------------------------------------------------------------------------
% Quelques options pdf
%-------------------------------------------------------------------------------
\hypersetup{
  pdfpagemode = FullScreen, % afficher le pdf en plein écran
  pdfauthor   = {Auteur},%
  pdftitle    = {Titre principal},%
  pdfsubject  = {},%
  pdfkeywords = {Science,Impact},%
  pdfcreator  = {PDFLaTeX,emacs,AucTeX},%
  pdfproducer = {}%
}
%-------------------------------------------------------------------------------
\newcommand{\aua}{Melville Charlebois} % Prénom et Nom Auteur 1
\newcommand{\auasht}{M.Charlebois} % Prénom et Nom Auteur 1 (version courte pied de page)
\newcommand{\aub}{Inès Rousseau} % Prénom et Nom Auteur 2
\newcommand{\auc}{Cerise Patel} % Prénom et Nom Auteur 3
\newcommand{\aud}{Arnaud Séguelin} % Prénom et Nom Auteur 4
\newcommand{\aue}{Nathalie Du Trieux} % Prénom et Nom Auteur 5

\title[Lorem ipsum dolor sit amet]{Lorem ipsum dolor sit amet} % Le titre doit être court, il sera complété le cas échéant par un sous-titre. Le texte entre crochet apparaîtra en pied de page
\subtitle{Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aliquam gravida} % N'est pas obligatoire si le titre se suffit à lui même
\author[\auasht \ \textit{et al.}]{\aua\inst{1}, \aub\inst{2}, \auc\inst{3}, \aud\inst{2} \& \aue\inst{1}} % Le texte entre crochet apparaîtra en pied de page
\institute{
  \par \inst{1} Laboratoire de la Fraise - Unité KFC - 39 Rue du Maréchal Auguste - Frais (Spain)
  \par \inst{2} Laboratoire de biologie moléculaire - Unité cytK - 12 Impasse de l'Opéra - Marseille (France)
  \par \inst{3} Laboratoire de la Faille des Falaises et des Ferry - Unité Joudon King François - 39 Avenue du Maréchal Auguste - Trifouilly-les-Oies (France)
}
\date[17/11/2014]{Lundi 17 Novembre 2014}
%-------------------------------------------------------------------------------
\begin{document}
  %-F1------------------------------------------------------------------------------
  \begin{frame}
    \titlepage
  \end{frame}
  \section{Debut}
  % --------- Sommaire ---------
  \section*{Sommaire}
  \begin{frame}{Sommaire}
    \tableofcontents
  \end{frame}
  %-F2------------------------------------------------------------------------------
  \section{Présentation}
  \begin{frame}{Première page}
  \end{frame}
\end{document}

title page

1
  • you're just willing to work harder than i am. Nov 17, 2014 at 22:25

You must log in to answer this question.

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