TransWikia.com

How can I remove the second bar of header and the bar of footer in Szeged in LaTeX

TeX - LaTeX Asked by user227196 on June 2, 2021

I want to make beamer presentation using Szeged theme in LaTeX. The problem is that there are three lines in header and I want to remove the last one and the footer below

documentclass[compress]{beamer}

usetheme{Szeged}

usecolortheme{default}
usefonttheme{default}

makeatletter
setbeamertemplate{footline}{
  leavevmode%
  hbox{%
  begin{beamercolorbox}[wd=.333333paperwidth,ht=2.25ex,dp=1ex,center]{author in head/foot}%
    usebeamerfont{author in head/foot}insertshortauthorexpandafterbeamer@ifemptyexpandafter{beamer@shortinstitute}{}{~~(insertshortinstitute)}
  end{beamercolorbox}%
  begin{beamercolorbox}[wd=.333333paperwidth,ht=2.25ex,dp=1ex,center]{title in head/foot}%
    usebeamerfont{title in head/foot}insertshorttitle
  end{beamercolorbox}%
  begin{beamercolorbox}[wd=.333333paperwidth,ht=2.25ex,dp=1ex,right]{date in head/foot}%
    usebeamerfont{date in head/foot}insertshortdate{}hspace*{2em}
    insertframenumber{} / inserttotalframenumberhspace*{2ex} 
  end{beamercolorbox}}%
  vskip0pt%
}
makeatother


title[sd]{Title}
author[d]{A:T inst{1}B.T inst{2}  C.A inst{1}}
date[sd]{xx.mm.yyyy}
 institute[]{inst{1}SomethingSomewhere inst{2} SomethingSomewhere}


begin{document}

begin{frame}
titlepage
end{frame}


section{First Section}
subsection{}
begin{frame}
frametitle{Hello}
textbf{here we go}



end{frame}

end{document}

One Answer

As far as I understand your demand, you only want to remove the third horizontal line from the top of the frame.

Here is a modified headline template definition taken from the beamerthemelined.sty existing theme.

% arara: lwpdflatex
documentclass[compress]{beamer}

usetheme{Szeged}

usecolortheme{default}
usefonttheme{default}

makeatletter
setbeamertemplate{footline}{
  leavevmode%
  hbox{%
  begin{beamercolorbox}[wd=.333333paperwidth,ht=2.25ex,dp=1ex,center]{author in head/foot}%
    usebeamerfont{author in head/foot}insertshortauthorexpandafterbeamer@ifemptyexpandafter{beamer@shortinstitute}{}{~~(insertshortinstitute)}
  end{beamercolorbox}%
  begin{beamercolorbox}[wd=.333333paperwidth,ht=2.25ex,dp=1ex,center]{title in head/foot}%
    usebeamerfont{title in head/foot}insertshorttitle
  end{beamercolorbox}%
  begin{beamercolorbox}[wd=.333333paperwidth,ht=2.25ex,dp=1ex,right]{date in head/foot}%
    usebeamerfont{date in head/foot}insertshortdate{}hspace*{2em}
    insertframenumber{} / inserttotalframenumberhspace*{2ex} 
  end{beamercolorbox}}%
  vskip0pt%
}
makeatother

% Taken from beamerthemelined.sty
setbeamertemplate{headline}[text line]
{%
  vbox{%
    vskip3pt%
    beamerline{insertnavigation{paperwidth}}%
    vskip1.5pt%
    insertvrule{2pt}{beamerstructure!50!averagebackgroundcolor}%
    vskip1.5pt%
    tinyline{color{beamerstructure}insertsubsectionhfill}
  }%
}


title[sd]{Title}
author[d]{A:T inst{1}B.T inst{2}  C.A inst{1}}
date[sd]{xx.mm.yyyy}
 institute[]{inst{1}SomethingSomewhere inst{2} SomethingSomewhere}


begin{document}

begin{frame}
titlepage
end{frame}


section{First Section}
subsection{}
begin{frame}
frametitle{Hello}
textbf{here we go}



end{frame}

end{document}

enter image description here

Answered by BambOo on June 2, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP