Тема для латекса класса бимер


Некоторое время назад я создал стиль, чтобы быть использованы для слайдов и плакатов на бимер класса. Я опубликовал его на GitHub, так как латекс-beamertheme-ibadai. По сути, это была моя первая попытка на написание такой пакет, и я ищу советы, как улучшить его.

Он поставляется с несколько вариантов, самое основное это показано на изображении ниже. Пожалуйста, посетите репозитория дополнительные примеры, а я немного мало места здесь.

screenshot mwe, also see https://github.com/polyluxus/latex-beamertheme-ibadai/blob/master/demo/mwe/mwe.preview.png

Я в основном ищу советы по основной файл beamerthemeMito.styЭто одна связывая все это вместе. Я старался быть как можно более четкими, и он до сих пор работал для моих целей, но я хотел бы знать, где я могу улучшить его, или если я сделал некоторые ошибки новичков, которые просто работают по стечению обстоятельств.

\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{beamerthemeMito}[2016/12/12]  

%%%%%
% Required packages to be loaded
%
\RequirePackage{adjustbox}
\RequirePackage{etoolbox}

%%%%%
% Create toggles for options
%
\providetoggle{poster}
\providetoggle{alternativetitle}
\providetoggle{light}

%%%%%
% List options
%
\DeclareOption{beamer}{\togglefalse{poster}}
\DeclareOption{alttitle}{\toggletrue{alternativetitle}}
\DeclareOption{poster}{\toggletrue{poster}}
\DeclareOption{light}{\toggletrue{light}}
\DeclareOption{dark}{\togglefalse{light}}
\DeclareOption*{\PackageWarning{beamerthemeMito}{Unknown ‘\CurrentOption’}}
\ExecuteOptions{beamer,dark}
\ProcessOptions\relax

%%%%%
% Define a standard length based on the normal fontsize
%
\newlength{\normaltextsize}
\AtBeginDocument{\setlength{\normaltextsize}{\f@size pt}}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

%%%%%
% Predefined Fonts and Colours
%
% Both themes (dark/light) use the same palette,
% the difference is only that the templates for 
% the title(s) switch fg and bg
\iftoggle{light}{
  \usecolortheme[light]{ibadai}
}{%
  \usecolortheme{ibadai}
}
% Poster uses larger fonts for title, author, etc
\iftoggle{poster}{%
  \usefonttheme[poster]{ibadai}
}{%
  \usefonttheme[beamer]{ibadai}
}

%%%%%
% Modify Inner theme
%
% Choose triangles for the itemize environment
% this really doesn't have much of an effect since it is redefinedi later
\setbeamertemplate{itemize items}[triangle]
% Two levels should be quite enough
\setbeamertemplate{itemize item}{\raisebox{0.12ex}{$\blacktriangleright$}\hskip0.1em}
\setbeamertemplate{itemize subitem}{\raisebox{0.12ex}{$\triangleright$}\hskip0.1em}
% There are no (should not be) sections in a poster
\iftoggle{poster}{%
}{%
  \setbeamertemplate{sections/subsections in toc}[sections numbered]
  % Provide additional level for itemize environment
  \setbeamertemplate{itemize subsubitem}{\raisebox{0.12ex}{$\triangleright$}\hskip0.1em}
}

% enumerated figures, tables (,and schemes if defined)
\setbeamertemplate{caption}[numbered]     

%%%%%
% Modify Outer theme
%
\useoutertheme{default} %fallback

% Don't use navigation symbols
\beamertemplatenavigationsymbolsempty

%%%%%
% New templates
%
% The theme doesn't use a headline on standard frames.
% Define a headline template which can be used as 
% the title for a poster
\defbeamertemplate{headline}{ibadai-poster}{%
  \begin{beamercolorbox}%
        [wd=1\paperwidth,sep=0.02\paperwidth,
 leftskip=0.01\paperwidth,rightskip=0.01\paperwidth]%
        {use=frametitle,fg=frametitle.bg.bg=frametitle.fg}%
    \parbox[b][0.16\paperwidth]{0.68\paperwidth}{%
      \raggedleft
      {\usebeamerfont{title}\inserttitle\strut\par}%
      \ifx\insertsubtitle\@empty%
      \else%
        {\usebeamerfont{subtitle}\insertsubtitle\strut\par}%
      \fi
      {\usebeamerfont{author}\usebeamercolor[fg]{author}\insertauthor\strut\par}%
      \ifx\insertinstitute@empty\vfill%
      \else%
        {\usebeamerfont{institute}\usebeamercolor[fg]{normal text}\insertinstitute\strut\par}
      \fi\vskip0ex % Ignore depth
    }\hfill%
    \ifx\inserttitlegraphic\@empty%
    \else%\hfill%%
      \adjustbox{max height=0.16\paperwidth,%
                 max width=0.25\paperwidth,%
          keepaspectratio,valign=B}{\inserttitlegraphic}%
      \fi\par
  \end{beamercolorbox}
  \nointerlineskip
  \begin{beamercolorbox}[wd=1\paperwidth,ht=0.2\normaltextsize]{frametitle}
  \end{beamercolorbox}%
}

% Define how the title for a slide is set
% This is the default for the dark theme
\defbeamertemplate{frametitle}{ibadai-frametitle}{%
  \nointerlineskip
  \begin{beamercolorbox}%
        [wd=1\paperwidth,sep=0.01\paperwidth,
 leftskip=0.01\paperwidth,rightskip=0.01\paperwidth]%
        {frametitle}%
    \usebeamerfont{frametitle}\insertframetitle\strut\par
    \ifx\insertframesubtitle\@empty%
    \else%
    {\usebeamerfont{framesubtitle}\insertframesubtitle\strut\par}%
    \fi
  \end{beamercolorbox}
  \nointerlineskip
  \begin{beamercolorbox}[wd=1\paperwidth,ht=0.1\normaltextsize]{separation line head}
  \end{beamercolorbox}%
}

% Define footline as a single box for a slide
\defbeamertemplate{footline}{ibadai}{%
  \begin{beamercolorbox}[wd=1\paperwidth,ht=0.1\normaltextsize]{separation line foot}
  \end{beamercolorbox}%
  \nointerlineskip
  \begin{beamercolorbox}%
        [wd=1\paperwidth,ht=3ex,dp=1.5ex,leftskip=1em,rightskip=1em]%
        {footline}%
    \usebeamerfont{footline}%
    \insertshortauthor{} (\insertshortinstitute)\hfill\insertframenumber/\inserttotalframenumber%
  \end{beamercolorbox}%
}

% Define alternative footline as a single box
% for a title page or the poster
% Provide a command to easily insert a custom footline
\providecommand{\insertcustomfootline}{}
\providecommand{\posterfootline}[1]{\renewcommand{\insertcustomfootline}{#1}}

\defbeamertemplate{footline}{ibadai-poster}{%
  \begin{beamercolorbox}[wd=1\paperwidth,ht=0.2\normaltextsize]{separation line foot}
  \end{beamercolorbox}%
  \nointerlineskip
  \begin{beamercolorbox}%
        [wd=1\paperwidth,sep=0.01\paperwidth,
 leftskip=0.01\paperwidth,rightskip=0.01\paperwidth]%
 {footline}
    \usebeamerfont{footline}%
    \ifx\insertcustomfootline\@empty%
      \ifx\insertdate\@empty\today%
      \else\insertdate\fi%
      \hfill\LaTeX
    \else%
      \insertcustomfootline%
    \fi
  \end{beamercolorbox}%
  \nointerlineskip
  \begin{beamercolorbox}[wd=1\paperwidth,ht=0.2\normaltextsize]{separation line foot}
  \end{beamercolorbox}%
}

% Redefine Titlepage 
%
% Make a titlepage
\def\maketitle{%
  \ifbeamer@inframe\titlepage%
  \else%
  \frame[plain]\titlepage
  \fi
}

\defbeamertemplate{title page}{ibadai-titlepage}
{
  %\vskip0pt
  \usebeamerfont{normal text}%
  \begin{beamercolorbox}[wd=1\paperwidth,ht=0.1\normaltextsize]{separation line head}
  \end{beamercolorbox}%
  \nointerlineskip
  \begin{beamercolorbox}%
        [wd=1\paperwidth,sep=0.04\paperwidth,
 leftskip=0.01\paperwidth,rightskip=0.01\paperwidth]%
        {title}%
    {\usebeamerfont{title}\inserttitle\strut\par}%
    \ifx\insertsubtitle\@empty%
    \else%
      {\usebeamerfont{subtitle}\insertsubtitle\strut\par}%
    \fi
  \end{beamercolorbox}
  \nointerlineskip
  \begin{beamercolorbox}[wd=1\paperwidth,ht=0.1\normaltextsize]{separation line head}
  \end{beamercolorbox}%
  \vspace{0.2\paperheight}
  \parbox[b][0.25\paperheight]{0.5\textwidth}{%
    {\usebeamerfont{author}\usebeamercolor[fg]{author}\insertauthor\strut\par}
    \ifx\insertinstitute@empty\vfill%
    \else%
      {\usebeamerfont{institute}\usebeamercolor[fg]{normal text}\insertinstitute\strut\par}
    \fi\vfill
    \ifx\insertdate@empty%
      {\usebeamerfont{date}\usebeamercolor[fg]{normal text}\today}\strut\par
    \else%
      {\usebeamerfont{date}\usebeamercolor[fg]{normal text}\insertdate}\strut\par
    \fi
  }\hfill%
  \ifx\inserttitlegraphic@empty\null%
  \else%
    \adjustbox{max height=0.25\paperheight,%
               max width=0.25\textwidth,%
           keepaspectratio,valign=B}{\inserttitlegraphic}%
  \fi\par
}

% Define an alternative layout for the titlepage
% Custom content on the alternative titlepage is available through:
\newcommand{\inserttitlepageextra}{}
\newcommand{\titlepageextra}[1]{\renewcommand{\inserttitlepageextra}{#1}}

\defbeamertemplate{title page}{ibadai-alt-titlepage}{%
  \begin{beamercolorbox}%
        [wd=1\paperwidth,sep=0.02\paperwidth,
 leftskip=0.01\paperwidth,rightskip=0.01\paperwidth]%
        {use=frametitle,fg=frametitle.bg.bg=frametitle.fg}%
    \parbox[b][0.16\paperwidth]{0.68\paperwidth}{%
      \raggedleft
      {\usebeamerfont{title}\inserttitle\strut\par}%
      \ifx\insertsubtitle\@empty%
      \else%
        {\usebeamerfont{subtitle}\insertsubtitle\strut\par}%
      \fi
      {\usebeamerfont{author}\usebeamercolor[fg]{author}\insertauthor\strut\par}%
      \ifx\insertinstitute@empty\vfill%
      \else%
        {\usebeamerfont{institute}\usebeamercolor[fg]{normal text}\insertinstitute\strut\par}
      \fi\vskip0ex % Ignore depth
    }\hfill%
    \ifx\inserttitlegraphic\@empty%
    \else%\hfill%%
      \adjustbox{max height=0.16\paperwidth,%
                 max width=0.25\paperwidth,%
          keepaspectratio,valign=B}{\inserttitlegraphic}%
      \fi\par
  \end{beamercolorbox}
  \nointerlineskip
  \begin{beamercolorbox}[wd=1\paperwidth,ht=0.2\normaltextsize]{separation line head}
  \end{beamercolorbox}
  \vskip0pt plus 1filll
  \begin{centering}
    \inserttitlepageextra\strut\par
  \end{centering}
  \vskip0pt plus 1filll
  \begin{beamercolorbox}[wd=1\paperwidth,ht=0.1\normaltextsize]{separation line foot}
  \end{beamercolorbox}
  \nointerlineskip
  \begin{beamercolorbox}%
        [wd=1\paperwidth,sep=0.01\paperwidth,
 leftskip=0.01\paperwidth,rightskip=0.01\paperwidth]%
        {footline}%
    \usebeamerfont{footline}%
    \ifx\insertcustomfootline\@empty%
      \ifx\insertdate\@empty\today%
      \else\insertdate\fi%
      \hfill\LaTeX
    \else%
      \insertcustomfootline%
    \fi
  \end{beamercolorbox}%
}

%%%%%
% Define some boxed environments
%
% Provide a new length to know the actual available width
%
\newlength{\boxwidth}

%%%
% The different boxes only differ in color, 
% the actual code for the boxes should be recycleable.
% The default is the dark theme defined below
\providecommand{\blockbegin@ibadai@default}[2]{%
  \begin{minipage}{\linewidth}
%  \begin{beamercolorbox}[ht=0.1\normaltextsize]{test}
%  \end{beamercolorbox}
  \nointerlineskip
  \begin{beamercolorbox}[leftskip=0.3\normaltextsize,
                         colsep=0.2\normaltextsize
         ]{#1}%
    {\usebeamerfont*{#1}\insertblocktitle\strut\par}
  \end{beamercolorbox}
%  \nointerlineskip
%  \begin{beamercolorbox}[ht=0.1\normaltextsize]{test}
%  \end{beamercolorbox}
  \nointerlineskip
  \begin{beamercolorbox}[leftskip=0.5\normaltextsize,
                         rightskip=0.5\normaltextsize,
                         colsep=0.2\normaltextsize,
                         sep=0.5\normaltextsize,
                         vmode
         ]{#2}%
    \usebeamerfont{#2}%
  \setlength{\boxwidth}{\linewidth}
  \addtolength{\boxwidth}{-\leftskip}
  \addtolength{\boxwidth}{-\rightskip}
}
\providecommand{\blockend@ibadai@default}[1]{%
  \end{beamercolorbox}%
  \nointerlineskip
  \begin{beamercolorbox}[ht=0.1\normaltextsize]{#1}
  \end{beamercolorbox}
  \end{minipage}\par
}
%
\setbeamercolor{test}{fg=yellow,bg=black}
% The light theme uses:
\providecommand{\blockbegin@ibadai@light}[2]{%
  \begin{minipage}{\linewidth}
  \begin{beamercolorbox}[ht=0.1\normaltextsize]{#1}
  \end{beamercolorbox}
  \nointerlineskip
  \begin{beamercolorbox}[leftskip=0.3\normaltextsize,
                         colsep=0.2\normaltextsize
               ]{#2}%
    {\usebeamercolor[bg]{#1}\usebeamerfont*{#2}\insertblocktitle\strut\par}
  \end{beamercolorbox}
  \nointerlineskip
  \begin{beamercolorbox}[ht=0.1\normaltextsize]{#1}
  \end{beamercolorbox}
  \nointerlineskip
  \begin{beamercolorbox}[leftskip=0.5\normaltextsize,
                         rightskip=0.5\normaltextsize,
                         colsep=0.2\normaltextsize,
                         sep=0.5\normaltextsize,
                         vmode
               ]{#2}%
    \usebeamerfont{#2}%
  \setlength{\boxwidth}{\linewidth}
  \addtolength{\boxwidth}{-\leftskip}
  \addtolength{\boxwidth}{-\rightskip}
}
% The end definitions are the same as the defaults

%%%
% Define a standard block for the dark theme
% 
% Ordinary blocks
\defbeamertemplate{block begin}{ibadai-block-dark}{%
  \blockbegin@ibadai@default{block title}{block body}
}
\defbeamertemplate{block end}{ibadai-block-dark}{%
  \blockend@ibadai@default{block title}
}
%
% Alerted blocks 
\defbeamertemplate{block alerted begin}{ibadai-block-dark}{%
  \blockbegin@ibadai@default{block title alerted}{block body alerted}
}
\defbeamertemplate{block alerted end}{ibadai-block-dark}{%
  \blockend@ibadai@default{block title alerted}
}
%
% Example Blocks
\defbeamertemplate{block example begin}{ibadai-block-dark}{%
  \blockbegin@ibadai@default{block title example}{block body}
}
\defbeamertemplate{block example end}{ibadai-block-dark}{%
  \blockend@ibadai@default{block title example}
}
%

%%%
% Define a block for the poster theme
%
\defbeamertemplate{block begin}{ibadai-block-poster}{%
  \blockbegin@ibadai@default{block title}{block body}
  \begin{minipage}{1\boxwidth}
}
\defbeamertemplate{block end}{ibadai-block-poster}{%
  \end{minipage}
  \blockend@ibadai@default{block title alerted}
  \vskip0.5\normaltextsize plus 1fil
}

%%%
% Define a standard block for the light theme
% 
% Ordinary blocks
\defbeamertemplate{block begin}{ibadai-block-light}{%
  \blockbegin@ibadai@light{block title}{block body}
}
\defbeamertemplate{block end}{ibadai-block-light}{%
  \blockend@ibadai@default{block title}
}
%
% Alerted blocks 
\defbeamertemplate{block alerted begin}{ibadai-block-light}{%
  \blockbegin@ibadai@light{block title alerted}{block body}
}
\defbeamertemplate{block alerted end}{ibadai-block-light}{%
  \blockend@ibadai@default{block title alerted}
}
%
% Example Blocks
\defbeamertemplate{block example begin}{ibadai-block-light}{%
  \blockbegin@ibadai@light{block title example}{block body}
}
\defbeamertemplate{block example end}{ibadai-block-light}{%
  \blockend@ibadai@default{block title example}
}
%



%%%%%
% Set the values according to the requested switch
%
\iftoggle{alternativetitle}{%
  \setbeamertemplate{title page}[ibadai-alt-titlepage]
}{%
  \setbeamertemplate{title page}[ibadai-titlepage]
}
\iftoggle{light}{
  \setbeamertemplate{blocks}[ibadai-block-light]
}{%
  \setbeamertemplate{blocks}[ibadai-block-dark]
}
% As a default, use empty headline for the presentation 
% or the poster-template
\iftoggle{poster}{%
  \setbeamertemplate{headline}[ibadai-poster]
  \setbeamertemplate{footline}[ibadai-poster]
  \setbeamertemplate{frametitle}{}
  \setbeamertemplate{blocks}[ibadai-block-poster]
  \setbeamertemplate{bibliography item}[text]
}{%
  \setbeamertemplate{headline}[default]
  \setbeamertemplate{footline}[ibadai]
  \setbeamertemplate{frametitle}[ibadai-frametitle]
}

\mode
<all>

Сопровождая это colourtheme beamercolorthemeibadai.sty, который определяет, какие цвета использовать, когда:

\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{beamercolorthemeibadai}[2016/12/12]  

%%%%%
% Required packages to be loaded
%
\RequirePackage{xcolor}
\RequirePackage{etoolbox}

%%%%%
% Create toggles for options
%
\providetoggle{light}

%%%%%
% List options
%
\DeclareOption{light}{\toggletrue{light}}
\DeclareOption{dark}{\togglefalse{light}}
\DeclareOption{poster}{\togglefalse{light}}
\DeclareOption*{\PackageWarning{beamerthemeMito}{Unknown ‘\CurrentOption’}}
\ExecuteOptions{dark}
\ProcessOptions\relax



%%%%%
% Define colours
% 
\definecolor{IbadaiGreen}  {RGB}{002, 068, 030}
\definecolor{IbadaiRed}    {RGB}{176, 000, 038}
\definecolor{IbBackgdGrey} {RGB}{144, 144, 136}
\definecolor{IbBackgdWhite}{RGB}{244, 244, 236}
\definecolor{IbLgtGreen}   {RGB}{047, 139, 011}
\definecolor{IbDrkGreen}   {RGB}{024, 083, 011}
%\definecolor{IbTemplate}   {RGB}{000, 000, 000}

\usecolortheme{default} %fallback

%%%%%
% Define colours for palettes if used with different theme
%
\setbeamercolor*{normal text}{fg=IbadaiGreen,bg=IbBackgdWhite!50!white}
\setbeamercolor*{structure}{fg=IbadaiRed}
\setbeamercolor*{alerted text}{use=structure,fg=structure.fg,bg=IbBackgdWhite}
\setbeamercolor*{example text}{fg=IbLgtGreen,bg=IbBackgdWhite}
\setbeamercolor*{palette primary}{fg=IbBackgdWhite,bg=IbadaiGreen!70!IbBackgdWhite}
\setbeamercolor*{palette secondary}{fg=IbBackgdWhite,bg=IbadaiGreen!80!IbBackgdWhite}
\setbeamercolor*{palette tertiary}{fg=IbBackgdWhite,bg=IbadaiGreen!90!IbBackgdWhite}
\setbeamercolor*{palette quaternary}{fg=IbBackgdWhite,bg=IbadaiGreen}

\setbeamercolor{section in toc}{fg=IbadaiGreen,bg=IbBackgdWhite}
\setbeamercolor{item}{use=structure,fg=structure.fg}
\setbeamercolor{author}{use=structure,fg=structure.fg}

\setbeamercolor*{separation line}{use=structure,bg=structure.fg}

% Define colours for titles, they change according to used option
\iftoggle{light}{%
  \setbeamercolor{titlelike}{bg=IbBackgdWhite,fg=IbadaiGreen}
  \setbeamercolor*{separation line head}{bg=IbadaiGreen}
}{%
  \setbeamercolor{titlelike}{parent=palette quaternary}
  \setbeamercolor*{separation line head}{parent=separation line}
}
\setbeamercolor*{separation line foot}{parent=separation line}

\setbeamercolor{block title}{parent=palette quaternary}
\setbeamercolor{block body}{parent=normal text, use=block title, bg=block title.fg}

\setbeamercolor{block title alerted}{use=structure,fg=IbBackgdWhite,bg=structure.fg}
\setbeamercolor{block body alerted}{parent=normal text, use=block title alerted, bg=block title alerted.fg!95!block title alerted.bg}

\setbeamercolor{block title example}{use=example text,fg=example text.bg,bg=example text.fg}
\setbeamercolor{block body example}{parent=normal text, use=block title example, bg=block title example.fg!95!block title example.bg}

\setbeamercolor{footline}{parent=palette quaternary}

Последняя файла необходима шрифты, определенные в beamerfontthemeibadai.sty:

\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{beamerfontthemeibadai}[2016/12/12]  

\RequirePackage{etoolbox}

\providetoggle{poster}

\DeclareOption{beamer}{\togglefalse{poster}}
\DeclareOption{poster}{\toggletrue{poster}}
\DeclareOption*{\PackageWarning{beamerthemeMito}{Unknown ‘\CurrentOption’}}
\ProcessOptions\relax


%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

%\usefonttheme{default} %fallback

\iftoggle{poster}{%
  \def\familydefault{\rmdefault}
  \def\mathfamilydefault{\rmdefault}
  \setbeamerfont*{title}{size=\huge,series=\bfseries,family=\sffamily}
  \setbeamerfont*{subtitle}{parent=title,size=\Large,series=\mdseries}
  \setbeamerfont{author}{parent=title,size=\large}
  \setbeamerfont{institute}{parent=title,size=\large,series=\mdseries}
  \setbeamerfont{date}{parent=title,size=\normalsize,series=\mdseries}

  \setbeamerfont{block title}{parent=title,size=\normalsize}
  \setbeamerfont{block title alerted}{parent=block title}

  \setbeamerfont{caption}{size=\normalsize,series=\mdseries,family=\sffamily}
  \setbeamerfont{caption name}{parent=caption,series=\bfseries}

  \setbeamerfont*{footline}{family=\ttfamily,series=\mdseries,size=\normalsize}

  \linespread{1.05}
}{%
  \setbeamerfont*{title}{size=\Large,series=\bfseries}
  \setbeamerfont*{subtitle}{size=\large}
\setbeamerfont{author}{size=\normalsize,series=\bfseries}
\setbeamerfont{institute}{size=\normalsize}
\setbeamerfont{date}{size=\small}

\setbeamerfont{section title}{size=\Large}

\setbeamerfont{block title}{size=\normalsize}
\setbeamerfont{block title alerted}{size=\normalsize}
\setbeamerfont{block title example}{size=\normalsize}

\setbeamerfont{subtitle}{size=\small}
\setbeamerfont{frametitle}{size=\large}

\setbeamerfont{caption}{size=\small}
\setbeamerfont{caption name}{series=\bfseries}

\setbeamerfont{footline}{series=\tt}
\linespread{1.15}
}

Я ориентировал себя на общие установки и другие темы, которые приходят с классом бимер.

Вышеуказанные предварительного просмотра могут быть произведены со следующими минимальный рабочий пример:

\documentclass[10pt]{beamer}

\usetheme{Mito}

\title{Short and Catchy Title}
\subtitle{Long and boring subtitle with unnecessary explanations.}
\author[F. Bar]{Foo Bar}
\institute[Baz Inst.]{Baz Insititute}
\titlegraphic{\includegraphics[scale=2]{example-image-a}}
% example-image from https://www.ctan.org/pkg/mwe
\date{the Internet, \today}

\begin{document}

\frame[plain]{\titlepage}

\begin{frame}[t]
\frametitle{Catchy Slide Title}
\framesubtitle{Boring subtitle}
\begin{columns}[T]
  \column{0.49\textwidth}
    \begin{block}{Normal Block}
      Sampletext
    \end{block}
  \column{0.49\textwidth}
    \begin{alertblock}{Alerted Block}
      Sampletext
    \end{alertblock}
\end{columns}
\end{frame}

\end{document}


185
6
задан 23 февраля 2018 в 07:02 Источник Поделиться
Комментарии
1 ответ

Несколько мелких замечаний:


  • \RequirePackage{etoolbox} Не надо с недавних бимер версий, как этот пакет будет загружен автоматически

  • Вместо того, чтобы нагружать подтемы с разными вариантами, в зависимости от стоимости вашего переключателя, например

    \iftoggle{light}{
    \usecolortheme[light]{ibadai}
    }{%
    \usecolortheme{ibadai}
    }

    Я бы предпочел, чтобы напрямую передать параметр в подтеме. Например, в главной теме:

    \DeclareOptionBeamer{light}{\PassOptionsToPackage{light}{beamercolourthemeibadai}}
    \ProcessOptionsBeamer

    и в цветовой гамме:

    \DeclareOptionBeamer{light}{... define your toogle or something ...}
    \ExecuteOptionsBeamer{light}
    \ProcessOptionsBeamer

  • \useoutertheme{default} не надо, он будет загружен автоматически

  • Проектор цвет коробки должен получать бимер цвет как обязательный аргумент, не {use=frametitle,fg=frametitle.bg,bg=frametitle.fg}. Я предлагаю, чтобы определить новый цвет

    \setbeamercolor{inverse frametitle}{use=frametitle,fg=frametitle.bg,bg=frametitle.fg}

    и потом использовать

     \begin{beamercolorbox}%
    [wd=1\paperwidth,sep=0.02\paperwidth,
    leftskip=0.01\paperwidth,rightskip=0.01\paperwidth]%
    {inverse frametitle}%

  • \RequirePackage{xcolor} не надо, проектор автоматически загружает его

  • \usecolortheme{default} также ненужно

2
ответ дан 1 марта 2018 в 10:03 Источник Поделиться