chore: autoformat with latexindent

This commit is contained in:
Johan Larsson 2024-01-11 09:09:54 +01:00
parent 47dcf8df1a
commit f4393f0591
1 changed files with 101 additions and 101 deletions

View File

@ -108,15 +108,15 @@
\ifx\inserttitle\@empty\else\usebeamertemplate*{title}\fi
\ifx\insertsubtitle\@empty\else\usebeamertemplate*{subtitle}\fi
\usebeamertemplate*{title separator}
% \end{macrocode}
%
% Beamer's definition of |\insertauthor| is always nonempty, so we have
% to test another macro initialized by |\author{...}| to see if the user has
% defined an author. This solution was suggested by Enrico Gregorio in an
% answer to \href{https://tex.stackexchange.com/questions/241306/}{this
% Stack Exchange question}.
%
% \begin{macrocode}
% \end{macrocode}
%
% Beamer's definition of |\insertauthor| is always nonempty, so we have
% to test another macro initialized by |\author{...}| to see if the user has
% defined an author. This solution was suggested by Enrico Gregorio in an
% answer to \href{https://tex.stackexchange.com/questions/241306/}{this
% Stack Exchange question}.
%
% \begin{macrocode}
\ifx\beamer@shortauthor\@empty\else\usebeamertemplate*{author}\fi
\ifx\insertdate\@empty\else\usebeamertemplate*{date}\fi
\ifx\insertinstitute\@empty\else\usebeamertemplate*{institute}\fi
@ -384,8 +384,8 @@
\vphantom{ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz()}%
}
\newcommand{\moloch@block}[1]{
\par\vskip\medskipamount%
\setlength{\parskip}{0pt}
\par\vskip\medskipamount%
\setlength{\parskip}{0pt}
% \end{macrocode}
%
% If a background color is defined for the block title or body, we need to
@ -406,11 +406,11 @@
% set a rightskip for a nice ragged-right block title.
%
% \begin{macrocode}
\ifbeamercolorempty[bg]{block title#1}{%
\begin{beamercolorbox}[rightskip=0pt plus 4em]{block title#1}}{%
\ifbeamercolorempty[bg]{block title}{%
\begin{beamercolorbox}[rightskip=0pt plus 4em]{block title#1}%
}%
\ifbeamercolorempty[bg]{block title#1}{%
\begin{beamercolorbox}[rightskip=0pt plus 4em]{block title#1}}{%
\ifbeamercolorempty[bg]{block title}{%
\begin{beamercolorbox}[rightskip=0pt plus 4em]{block title#1}%
}%
% \end{macrocode}
%
% Otherwise, if the |block title| has a background, we set the padding based
@ -419,34 +419,34 @@
% subtracting |\moloch@blockadjust| from the top and bottom padding.
%
% \begin{macrocode}
{%
\begin{beamercolorbox}[
{%
\begin{beamercolorbox}[
sep=\dimexpr\moloch@blocksep-\moloch@blockadjust\relax,
leftskip=\moloch@blockadjust,
rightskip=\dimexpr\moloch@blockadjust plus 4em\relax
]{block title#1}%
}}%
% \end{macrocode}
%
% We can now set the contents of the |block title|. The zero-width but
% positive-height box |\moloch@strut| ensures that the block title box
% has a consistent height, even if it lacks punctuation, ascenders, or
% descenders.
%
% \begin{macrocode}
% \end{macrocode}
%
% We can now set the contents of the |block title|. The zero-width but
% positive-height box |\moloch@strut| ensures that the block title box
% has a consistent height, even if it lacks punctuation, ascenders, or
% descenders.
%
% \begin{macrocode}
\usebeamerfont*{block title#1}%
\moloch@strut%
\insertblocktitle%
\moloch@strut%
\end{beamercolorbox}%
\end{beamercolorbox}%
% \end{macrocode}
%
% Next, we typeset the |block body|. This the code is similar to, but simpler
% than, the |block title| code since we don't need to adjust for any struts.
%
% \begin{macrocode}
\nointerlineskip%
\ifbeamercolorempty[bg]{block body#1}{%
\nointerlineskip%
\ifbeamercolorempty[bg]{block body#1}{%
\begin{beamercolorbox}[vmode]{block body#1}}{
\ifbeamercolorempty[bg]{block body}{%
\begin{beamercolorbox}[vmode]{block body#1}%
@ -456,19 +456,19 @@
}}%
\usebeamerfont{block body#1}%
\setlength{\parskip}{\moloch@parskip}%
}
% \end{macrocode}
%
% This concludes the auxiliary macro |\moloch@block|. Finally,
% we define the block beamer templates using this macro.
%
% \begin{macrocode}
\setbeamertemplate{block begin}{\moloch@block{}}
\setbeamertemplate{block alerted begin}{\moloch@block{ alerted}}
\setbeamertemplate{block example begin}{\moloch@block{ example}}
\setbeamertemplate{block end}{\end{beamercolorbox}\vspace*{0.2ex}}
\setbeamertemplate{block alerted end}{\end{beamercolorbox}\vspace*{0.2ex}}
\setbeamertemplate{block example end}{\end{beamercolorbox}\vspace*{0.2ex}}
}
% \end{macrocode}
%
% This concludes the auxiliary macro |\moloch@block|. Finally,
% we define the block beamer templates using this macro.
%
% \begin{macrocode}
\setbeamertemplate{block begin}{\moloch@block{}}
\setbeamertemplate{block alerted begin}{\moloch@block{ alerted}}
\setbeamertemplate{block example begin}{\moloch@block{ example}}
\setbeamertemplate{block end}{\end{beamercolorbox}\vspace*{0.2ex}}
\setbeamertemplate{block alerted end}{\end{beamercolorbox}\vspace*{0.2ex}}
\setbeamertemplate{block example end}{\end{beamercolorbox}\vspace*{0.2ex}}
% \end{macrocode}
% \end{macro}
% \end{macro}
@ -571,12 +571,12 @@
% exactly once at the end of each slide.
%
% \begin{macrocode}
\pretocmd{\beamer@reseteecodes}{%
\pretocmd{\beamer@reseteecodes}{%
\ifbool{moloch@standout}{
\endgroup
\boolfalse{moloch@standout}
}{}
}{}{}
}{}{}
% \end{macrocode}
%
% We set the fonts and the \centering alignment on the inner content,
@ -584,12 +584,12 @@
% formatting.
%
% \begin{macrocode}
\AtBeginEnvironment{beamer@frameslide}{
\AtBeginEnvironment{beamer@frameslide}{
\ifbool{moloch@standout}{
\centering
\usebeamerfont{standout}
}{}
}
}
% \end{macrocode}
% \end{macro}
%