法兰克福航运与马德里船体/船体

法兰克福航运与马德里船体/船体

我想使用madrid的块(不知何故比 的更宽frankfurt?)和frankfurt的修改后的导航。具体来说,我想将块更左对齐并使其更宽。我该如何在下面的 MWE 中做到这一点?\setbeamertemplate{blocks}[madrid]没用...谢谢!

\documentclass[9pt, notes]{beamer}
\usetheme{Frankfurt} % nice bullets at top
\usepackage{amsmath,amssymb,amsthm,
%minted,
%float,
%multicol,
mathtools,dsfont,
%hyperref,
rotating,cleveref,bm,tikz,algorithm,algpseudocode,
%xcolor,
vwcol}

% -------------------------------------------
% modifications
% -------------------------------------------
\setbeamertemplate{footline}[frame number]{} % gets rid of bottom navigation bars
\usecolortheme{rose} % lighten the headers
% \definecolor{UBCblue}{rgb}{0.04706, 0.13725, 0.26667}
% \setbeamercolor{alerted text}{fg=UBCblue}

% -------------------------------------------
% setup
% -------------------------------------------
\title{A Title}
\subtitle{some subtitle}
\author{Some One}%\inst{1}}
\institute{Some Where \\ Department }
\date{May 27, 2018}
\subject{MWE}

% ToC command
\AtBeginSubsection[]
{
  \begin{frame}<beamer>{Outline}
    \tableofcontents[currentsection,currentsubsection]
  \end{frame}
}

% subsections in navigation
\makeatletter
\def\sectionentry#1#2#3#4#5{% section number, section title, page
  \ifnum#5=\c@part%
  \beamer@section@set@min@width
  \box\beamer@sectionbox\hskip1.875ex plus 1fill%
  \beamer@xpos=0\relax%
  \beamer@ypos=1\relax%
  \setbox\beamer@sectionbox=
  \hbox{\def\insertsectionhead{#2}%
    \def\insertsectionheadnumber{#1}%
    \def\insertpartheadnumber{#5}%
    {%
      \usebeamerfont{section in head/foot}\usebeamercolor[fg]{section in head/foot}%
      \ifnum\c@section=#1%
        \hyperlink{Navigation#3}{{\usebeamertemplate{section in head/foot}}}%
        :~\insertsubsectionhead%
      \else%
        \hyperlink{Navigation#3}{{\usebeamertemplate{section in head/foot shaded}}}%
      \fi}%
  }%
  \ht\beamer@sectionbox=1.875ex%
  \dp\beamer@sectionbox=0.75ex%
  \fi\ignorespaces}  
\makeatother

% wider block environment
\newenvironment<>{varblock}[2][\textwidth]{
     \begin{center}
       \begin{minipage}{#1}
         \setlength{\textwidth}{#1}
           \begin{actionenv}#3
             \def\insertblocktitle{#2}
             \par
             \usebeamertemplate{block begin}}
   {\par
       \usebeamertemplate{block end}
     \end{actionenv}
   \end{minipage}
\end{center}}


% ===========================================
% content
% ===========================================
\begin{document}
\begin{frame}[plain]
  \titlepage
\end{frame}

% ===========================================
\section{Introduction}
% ===========================================

% -------------------------------------------
\subsection{Motivation}
% -------------------------------------------
\begin{frame}
  p1
\end{frame}

% -------------------------------------------
\subsection{Something else}
% -------------------------------------------
\begin{frame}
\begin{block}{test}
How can I left align this more and make the box wider? In the `madrid' theme, it's ok
\end{block}
\end{frame}


% -------------------------------------------
\subsubsection{Point 1}
% -------------------------------------------
\begin{frame}
  p2
\end{frame}
\begin{frame}
  p3
\end{frame}

\end{document}

在此处输入图片描述

答案1

\documentclass{beamer}
\usetheme{Frankfurt}
\setbeamersize{text margin left=1em,text margin right=1em}


\begin{document}

\begin{frame}
\begin{block}{title}
content...
\end{block}
\end{frame}

\end{document}

相关内容