我怎样才能防止出现下图所示的新线?
以下是 MWE:
\documentclass[svgnames,9pt]{beamer}
\usepackage[latin1]{inputenc}
\usetheme{Warsaw}
\setbeamertemplate{headline}{}
\setbeamerfont{footline}{size=\fontsize{6}{8}\selectfont}
\makeatletter
\setbeamertemplate{frametitle}
{%
\nointerlineskip%
\vskip-2pt%
\hbox{\leavevmode
\advance\beamer@leftmargin by -12bp%
\advance\beamer@rightmargin by -12bp%
\beamer@tempdim=\textwidth%
\advance\beamer@tempdim by \beamer@leftmargin%
\advance\beamer@tempdim by \beamer@rightmargin%
\hskip-\Gm@lmargin\hbox{%
\setbox\beamer@tempbox=\hbox{\begin{minipage}[b]{\paperwidth}%
\vbox{}\vskip.50ex% NEW: original \vskip-.75ex
\leftskip0.3cm%
\rightskip0.3cm plus1fil\leavevmode
\insertframetitle%
\ifx\insertframesubtitle\@empty%
\strut\par%
\else
\par{\usebeamerfont*{framesubtitle}{\usebeamercolor[fg]{framesubtitle}\insertframesubtitle}\strut\par\vskip2ex}% NEW: added \vskip2ex
\fi%
\nointerlineskip
\vbox{}%
\end{minipage}}%
\beamer@tempdim=\ht\beamer@tempbox%
\advance\beamer@tempdim by 2pt%
\begin{pgfpicture}{0pt}{0pt}{\paperwidth}{\beamer@tempdim}
\usebeamercolor{frametitle right}
\pgfpathrectangle{\pgfpointorigin}{\pgfpoint{\paperwidth}{\beamer@tempdim}}
\pgfusepath{clip}
\pgftext[left,base]{\pgfuseshading{beamer@frametitleshade}}
\end{pgfpicture}
\hskip-\paperwidth%
\box\beamer@tempbox%
}%
\hskip-\Gm@rmargin%
}%
\nointerlineskip
\vskip-0.2pt
\hbox to\textwidth{\hskip-\Gm@lmargin\pgfuseshading{beamer@topshade}\hskip-\Gm@rmargin}
\vskip-2pt
}
\makeatother
\addtobeamertemplate{frametitle}{\vspace*{0.5cm}}{\vspace*{0.5cm}}
\title[short title]{\huge \textbf{Long Title}}
\author[Me]{}
\date{}
\begin{document}
\begin{frame}
\begin{figure}[h!]
\includegraphics[scale=0.2]{../Thesis/images/Logo_Unisi_2012.jpg}
\end{figure}
\begin{center}
\begin{minipage}[b]{0.5\textwidth}
\centering
University of Siena\\Master Thesis in Computer Science Engineering
\end{minipage}%
\end{center}
\titlepage
\begin{minipage}[t]{0.5\textwidth}
\vspace{-2cm}
\begin{flushleft}
{ \textit{Author}:\vspace*{0.1cm} \\ Me }
\end{flushleft}
\end{minipage}%
%
\begin{minipage}[t]{0.5\textwidth}
\vspace{-2cm}
\begin{flushright}
{\textit{Supervisor}:\vspace*{0.1cm} \\ Prof. Him \\}
\end{flushright}
\end{minipage}%
\vspace{-0.7cm}
\begin{center}
\begin{minipage}[b]{0.5\textwidth}
\centering
\small
December 10, 2012\\Academic Year 2011/2012
\end{minipage}%
\end{center}
\end{frame}
\end{document}
答案1
改变
\begin{minipage}[b]{0.5\textwidth}
\centering
University of Siena\\Master Thesis in Computer Science Engineering
\end{minipage}%
到
\begin{minipage}[b]{0.7\textwidth}
\centering
University of Siena\\Master Thesis in Computer Science Engineering
\end{minipage}%
因为您不想强制标题适合页面宽度的一半。