フレーム番号の位置を微調整する

フレーム番号の位置を微調整する

ビーマー プレゼンテーションのフレーム番号の位置を微調整し、フレームの角を基準に分数の水平余白と垂直余白を調整したいと考えています。ご協力いただけませんか? ここに画像の説明を入力してください同じものの MWE は次のとおりです。

\documentclass[9pt]{beamer}

\usepackage{graphicx} % Required for inserting images
\usepackage{lipsum}
\usepackage{amsfonts, amsmath,amssymb,amsthm}
\usepackage{tikz}



\usetheme[numbering=fraction]{metropolis}
\usecolortheme{dove}
\setbeamertemplate{title separator}{}


% Adjust the position of the frametitle
\makeatletter
\setbeamertemplate{frametitle}{
  \nointerlineskip%
  \begin{beamercolorbox}[sep=0.3cm,ht=3em,wd=\paperwidth]{frametitle}
    \vbox{}\vskip-1ex%
    \hspace{1.2em}\strut\underline{\insertframetitle}\strut
    \vskip-1.5ex%
  \end{beamercolorbox}
}
\makeatother





\usepackage{xcolor}
\definecolor{VimalBlue}{RGB}{51, 51, 179}
\definecolor{VimalGreen}{RGB}{0, 102, 0}
\definecolor{VimalPurple}{RGB}{93, 94, 200}
\definecolor{ChadDarkBlue}{rgb}{.1,0,.2}  
\definecolor{ChadBlue}{rgb}{.1,.1,.5}  
\definecolor{ChadRoyal}{rgb}{.2,.2,.8} 
\definecolor{ChadGreen}{rgb}{0,.4,0} 

\setbeamercolor{frametitle}{fg=VimalBlue}
\setbeamercolor{title}{fg=VimalBlue}
\setbeamercolor{author}{fg=VimalGreen}
\setbeamercolor{footline}{fg=black!50}




%\setbeamersize{text margin left=20pt}

\setbeamertemplate{title page}{
  \begin{center}
    \usebeamercolor[fg]{title}\inserttitle\\[1ex]
    \usebeamercolor[fg]{subtitle}\insertsubtitle\\[6ex]
    \usebeamercolor[fg]{author}\insertauthor\\[2ex]
    \usebeamercolor[fg]{institute}\insertinstitute\\[2ex]
    \usebeamercolor[fg]{date}\insertdate
  \end{center}
}



% Set custom color and size for bullets
\setbeamertemplate{itemize item}{$\bullet$}
\setbeamertemplate{itemize subitem}{$\circ$}
\setbeamertemplate{itemize subsubitem}{--}

\setbeamertemplate{enumerate item}[circle]
\setbeamertemplate{enumerate subitem}[circle]

% Customize the enumerate item template
\setbeamertemplate{enumerate item}{
  \tikz[baseline=(item.base)]{
    \node[inner sep=0, outer sep=0, draw=VimalPurple, fill=VimalPurple, text=white,circle, minimum size=0.3em, inner sep=0.1em] (item) {\scriptsize\insertenumlabel};
  }
}

\setbeamertemplate{enumerate subitem}{
  \tikz[baseline=(item.base)]{
    \node[inner sep=0, outer sep=0, draw=VimalPurple, fill=VimalPurple, text=white,square, minimum size=0.3em, inner sep=0.2em] (item) {\scriptsize\insertenumlabel};
  }
}




\setbeamertemplate{itemize/enumerate body begin}{\normalsize}
\setbeamertemplate{itemize/enumerate subbody begin}{\normalsize}


% Customize the enumerate items template
\setbeamercolor{itemize item}{fg=VimalBlue}
\setbeamercolor{itemize subitem}{fg=VimalBlue}


%\setbeamerfont{itemize item}{size=\huge}
%\setbeamerfont{itemize subitem}{size=\small}



% Font packages
\usepackage{mathptmx}
%\usepackage[cochineal]{newtxmath}
\usepackage{bm}   
\usepackage[scaled]{helvet}
\usepackage{microtype}



\title{\huge \textbf{Title}}
\subtitle{\large Authors}
\author{\textbf{\large John Doe}\\Workshop\\Insti\\January 2024}
\date{}

\begin{document}
\maketitle


\begin{frame}{Motivation}
\lipsum[1]
\end{frame}

\end{document}

答え1

時代遅れのテーマを使用する代わりに、そのテーマのより現代的なフォークであるテーマmetropolisを使用することもできます。molochmetropolis

このmolochテーマの利点は、標準page number in head/footテンプレートを使用するため、簡単にスペースを追加できることです。

\documentclass[9pt]{beamer}

\usetheme{moloch}% modern fork of the metropolis theme
\setbeamertemplate{page number in head/foot}[totalframenumber]

\addtobeamertemplate{page number in head/foot}{}{\hspace*{0.5cm}\vspace*{0.5cm}}

\begin{document}


\begin{frame}
\frametitle{Motivation}
\end{frame}

\end{document}

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

オリジナルのメトロポリス テーマでは、フットラインは基本的に次のように定義されます。

\documentclass[9pt]{beamer}

\usetheme[numbering=fraction]{metropolis}

\makeatletter
\setbeamertemplate{footline}{%
  \begin{beamercolorbox}[wd=\textwidth, sep=3ex,rightskip=0pt]{footline}% <- change the 3ex to control the distance of the frame number from the right and bottom margin, change the 0pt to additional move the frame number further left
    \usebeamerfont{page number in head/foot}%
    \usebeamertemplate*{frame footer}
    \hfill%
    \usebeamertemplate*{frame numbering}
  \end{beamercolorbox}%
}
\makeatother

\begin{document}


\begin{frame}
\frametitle{Motivation}
\end{frame}

\end{document}

sepを変更して下端と右端までの距離を変更し、さらに を変更してrightskipフレーム番号を水平方向に移動することができます。

関連情報