タイトルパレットは、タイトルが2行の場合、タイトルの下に小さなスキップを提供します。

タイトルパレットは、タイトルが2行の場合、タイトルの下に小さなスキップを提供します。

ここに画像の説明を入力してください

上のパレットはスキップ率が低く、見た目が醜いです。1 行のタイトルのように少し余白を追加するにはどうすればよいでしょうか。

ここに画像の説明を入力してください

\documentclass[aspectratio=169, xcolor={x11names}]{beamer}

\usecolortheme{seahorse}
\useoutertheme[]{split}
\useinnertheme{inmargin}

\newlength{\widthTextMarginLeft}
\setlength{\widthTextMarginLeft}{1.5mm}
\newlength{\widthTextMarginRight}
\setlength{\widthTextMarginRight}{2mm}

\setbeamersize{text margin left=\widthTextMarginLeft, text margin right=\widthTextMarginRight}

\newlength{\sidebarWidth}
\setlength{\sidebarWidth}{0.3\paperwidth}

\setbeamersize{sidebar width left=\sidebarWidth, sidebar width right=0cm}

\begin{document}

\begin{frame}{Uncovering Contents When They Cannot Fit in One Slide}

\end{frame}

\end{document}

答え1

「問題」は、最初のタイトル「One Slide」の最後の行に降順の文字が含まれていないのに対し、「Uncovering Contents」には降順の文字として「g」が含まれていることです。すべてのタイトルを 2 番目のケースのように動作させたい場合は、テンプレート定義に\strutafter を追加できます。\insertframetitle

\documentclass[aspectratio=169, xcolor={x11names}]{beamer}

\usecolortheme{seahorse}
\useoutertheme[]{split}
\useinnertheme{inmargin}

\newlength{\widthTextMarginLeft}
\setlength{\widthTextMarginLeft}{1.5mm}
\newlength{\widthTextMarginRight}
\setlength{\widthTextMarginRight}{2mm}

\setbeamersize{text margin left=\widthTextMarginLeft, text margin right=\widthTextMarginRight}

\newlength{\sidebarWidth}
\setlength{\sidebarWidth}{0.3\paperwidth}

\setbeamersize{sidebar width left=\sidebarWidth, sidebar width right=0cm}

\makeatletter
\setbeamertemplate{frametitle}{%
  \ifbeamercolorempty[bg]{frametitle}{}{\nointerlineskip}%
  \@tempdima=\textwidth%
  \advance\@tempdima by\beamer@leftmargin%
  \advance\@tempdima by\beamer@rightmargin%
  \begin{beamercolorbox}[sep=0.3cm,left,wd=\the\@tempdima]{frametitle}
    \usebeamerfont{frametitle}%
    \vbox{}\vskip-1ex%
    \if@tempswa\else\csname beamer@fteleft\endcsname\fi%
    \strut\insertframetitle\strut\par%
    {%
      \ifx\insertframesubtitle\@empty%
      \else%
      {\usebeamerfont{framesubtitle}\usebeamercolor[fg]{framesubtitle}\strut\insertframesubtitle\par}%
      \fi
    }%
    \vskip-1ex%
    \if@tempswa\else\vskip-.3cm\fi% set inside beamercolorbox... evil here...
  \end{beamercolorbox}%
}
\makeatother

\begin{document}

\begin{frame}{Uncovering Contents When They Cannot Fit in One Slide}

\end{frame}

\end{document}

ここに画像の説明を入力してください

答え2

コードを実行すると、適切なパディングが得られます。ただし、\vspaceコンテンツの最後に以下を使用できます。

\documentclass[aspectratio=169, xcolor={x11names}]{beamer}

\usecolortheme{seahorse}
\useoutertheme[]{split}
\useinnertheme{inmargin}

\newlength{\widthTextMarginLeft}
\setlength{\widthTextMarginLeft}{1.5mm}
\newlength{\widthTextMarginRight}
\setlength{\widthTextMarginRight}{2mm}

\setbeamersize{text margin left=\widthTextMarginLeft, text margin right=\widthTextMarginRight}

\newlength{\sidebarWidth}
\setlength{\sidebarWidth}{0.3\paperwidth}

\setbeamersize{sidebar width left=\sidebarWidth, sidebar width right=0cm}

\begin{document}

\begin{frame}{Uncovering Contents When They Cannot Fit in One Slide\vspace{0.2cm}}

\end{frame}

\end{document}

関連情報