我试图回答这个问题 ,但我不能让内部部分中的链接Pandoc与合作乳胶默输出。
继Pandoc文档 ,我创造了这个最小的工作示例:
# Part One {#part-one}
## Section One {#section-one}
### Frame one {#frame-one}
- Items...
### Frame two {#frame-two}
- Items...
- Link to [Section One](#section-one)
而且内置它使用:
pandoc \
--table-of-contents \
-s -t beamer test.md \
-o test.pdf
内置LaTex的默PDF看起来不错,但内部链接[Section One](#section-one)
只是不工作。 它应该带我去了“一节”框架,但事实并非如此。 如何使这项工作?
编辑:这里是乳胶输出-o test.latex
:
\documentclass[]{beamer}
\setbeamertemplate{caption}[numbered]
\setbeamertemplate{caption label separator}{:}
\setbeamercolor{caption name}{fg=normal text.fg}
\usepackage{amssymb,amsmath}
\usepackage{ifxetex,ifluatex}
\usepackage{fixltx2e} % provides \textsubscript
\usepackage{lmodern}
\ifxetex
\usepackage{fontspec,xltxtra,xunicode}
\defaultfontfeatures{Mapping=tex-text,Scale=MatchLowercase}
\newcommand{\euro}{€}
\else
\ifluatex
\usepackage{fontspec}
\defaultfontfeatures{Mapping=tex-text,Scale=MatchLowercase}
\newcommand{\euro}{€}
\else
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\fi
\fi
% use upquote if available, for straight quotes in verbatim environments
\IfFileExists{upquote.sty}{\usepackage{upquote}}{}
% use microtype if available
\IfFileExists{microtype.sty}{\usepackage{microtype}}{}
% Comment these out if you don't want a slide with just the
% part/section/subsection/subsubsection title:
\AtBeginPart{
\let\insertpartnumber\relax
\let\partname\relax
\frame{\partpage}
}
\AtBeginSection{
\let\insertsectionnumber\relax
\let\sectionname\relax
\frame{\sectionpage}
}
\AtBeginSubsection{
\let\insertsubsectionnumber\relax
\let\subsectionname\relax
\frame{\subsectionpage}
}
\setlength{\parindent}{0pt}
\setlength{\parskip}{6pt plus 2pt minus 1pt}
\setlength{\emergencystretch}{3em} % prevent overfull lines
\setcounter{secnumdepth}{0}
\date{}
\begin{document}
\begin{frame}
\tableofcontents[hideallsubsections]
\end{frame}
\part{Part One}\label{part-one}
\hyperdef{}{section-one}{\section{Section One}\label{section-one}}
\begin{frame}{Frame one}
\begin{itemize}
\itemsep1pt\parskip0pt\parsep0pt
\item
Items\ldots{}
\end{itemize}
\end{frame}
\begin{frame}{Frame two}
\begin{itemize}
\itemsep1pt\parskip0pt\parsep0pt
\item
Items\ldots{}
\item
Link to \hyperref[section-one]{Section One}
\end{itemize}
\end{frame}
\end{document}