问题出在标题上。这是最简代码
\documentclass[11pt,a4paper]{beamer}
\usepackage{ulem}
\title{\sout{text}}
\begin{document}
\frame{\maketitle}
\end{document}
错误如下
Paragraph ended before \let was complete \begin{document}
Undefined control sequence \begin{document}
File ended while scanning use of \KVS@@Process
答案1
标题也可用于 PDF 文件的元数据。\sout
不存在,这会导致问题。使用\texorpdfstring
(包的hyperref
,由加载beamer
)或:
\documentclass[11pt,a4paper]{beamer}
\usepackage{ulem}
\pdfstringdefDisableCommands{\let\sout\relax}
\title{\sout{text}}
\begin{document}
\frame{\maketitle}
\end{document}
的结果pdfinfo
:
Title: text
Subject:
Keywords:
Author:
Creator: LaTeX with Beamer class version 3.27
Producer: pdfTeX-1.40.14
CreationDate: Wed Sep 18 17:14:35 2013
ModDate: Wed Sep 18 17:14:35 2013
...