我正在尝试打印带有来自投影仪演示文稿的注释的讲义。
添加handoutWithNotes.sty
如下内容创建带有注释的 latex-beamer 讲义
无法在我的 Latex 文件中编译:
\documentclass[t,handout]{beamer}
\usepackage{handoutWithNotes} % <----- HANDOUTS NOTES
\pgfpagesuselayout{4 on 1 with notes}[a4paper,border shrink=5mm]
% \pgfpagesuselayout{1 on 1 with notes}[a4paper,border shrink=5mm]
\usepackage{pgfpages}
%\usepackage[none]{hyphenat}
\usepackage{multicol}
\usepackage{pgfplots}
\usepackage{tikz}
\usetikzlibrary{positioning}
\graphicspath{{_figs/}{_figs_tikz/}{_eps/}{_sym/}}
\usepackage{graphicx}
% \usepackage{textpos} % para posicionar los frames en color
\usepackage{xcolor}
\usepackage{pgfplots}
% \pgfplotsset{width=10cm,compat=1.15}
\usetikzlibrary{shapes.arrows}
\usepackage{epstopdf}
\usepackage{pgf-pie}
\usepackage{siunitx}
%%%---------------
%
\definecolor{Gray}{gray}{0.8}
% \crefname{table}{tabla}{tablas}
\usepackage[spanish,es-tabla]{babel}
\usepackage[T1]{fontenc}
\usepackage{tabularx}
\usepackage{color, colortbl}
%
\usetikzlibrary{calc}
\usetikzlibrary{chains}
\usetikzlibrary{decorations.pathreplacing,decorations.text,calligraphy}
\usetikzlibrary{arrows,arrows.meta}
\usetikzlibrary{fit} %---
\pdfsuppresswarningpagegroup=1 %---
\def\shft#1{\raisebox{1ex}}
\def\wc{6} % ancho colector
\def\hc{4} % alto colector
\tikzset{
state/.style={
rectangle split,
rectangle split parts=2,
rectangle split part fill={red!80!blue!20,blue!15},
% rounded corners,
draw=black, thick,
minimum height=2em,
text width=4cm,
inner sep=2pt,
text centered,
inner ysep=5mm, %to control space in the box
inner xsep=3mm,
}
}
\usetikzlibrary{shapes,shapes.multipart}
\usetikzlibrary{positioning}
\usetikzlibrary{shapes.geometric, arrows,positioning}
\usepackage{smartdiagram}
\tikzset{
every overlay node/.style={
anchor=north west,
},
}
\def\tikzoverlay{%
\tikz[baseline,overlay]\node[every overlay node]
}%
\usepackage{adjustbox}
\usepackage{standalone}
\usetheme[progressbar=frametitle,
% outer/progressbar=foot
]{metropolis}
%%%%---------------------
\usetikzlibrary{mindmap}%,trees,shadows}
%----------- width and color of progressbar
\makeatletter
\setlength{\metropolis@titleseparator@linewidth}{2pt}
\setlength{\metropolis@progressonsectionpage@linewidth}{2pt}
\setlength{\metropolis@progressinheadfoot@linewidth}{2pt}
\makeatother
%------------
\setbeamertemplate{frame numbering}[fraction]
\setbeamercolor{background canvas}{bg=white}
\definecolor{upctcol}{RGB}{0,84,160}
\definecolor{amari}{RGB}{230,177,1}
\definecolor{bananamania}{rgb}{0.98, 0.91, 0.71}
\definecolor{mediumseagreen}{rgb}{0.24, 0.7, 0.44}
\setbeamercolor{background canvas}{bg=white}
\usetikzlibrary{overlay-beamer-styles}
\setbeamercovered{transparent=7}
\setbeamertemplate{section in toc}[sections numbered]
\title[GdR (U.1.1.)]{Intro}
\author[/PTU]{pll\\
\texorpdfstring{\\[0.05cm]}{--}
Presentation}
\date{September 2021}
% %%%%%%
% \mode<handout>{
% \usepackage{pgfpages}
% \pgfpagesuselayout{2 on 1}[a4paper,border shrink=5mm]
% \setbeamertemplate{note page}{%
% \fontsize{12pt}{32pt}\selectfont
% Notes
%
% \rule{\textwidth}{1pt} \rule{\textwidth}{1pt} \rule{\textwidth}{1pt} \rule{\textwidth}{1pt} \rule{\textwidth}{1pt} \rule{\textwidth}{1pt} \rule{\textwidth}{1pt} \rule{\textwidth}{1pt}\par
% }
%
% \setbeameroption{show notes}
% }
% \makeatletter
% \def\beamer@framenotesbegin{% at beginning of slide
% \gdef\beamer@noteitems{}%
% \gdef\beamer@notes{{}}% used to be totally empty.
% }
% \makeatother
% %%%%%%
\begin{document}
\metroset{block=fill}
\begin{frame}[t]{}
\titlepage
\end{frame}
%--- Next Frame ---%
\begin{frame}[t]{Tit 1}
frame 1
\end{frame}
%--- Next Frame ---%
\begin{frame}[t]{Tit 2}
frame 2
\end{frame}
%--- Next Frame ---%
\begin{frame}[t]{Tit 3}
frame 3
\end{frame}
%--- Next Frame ---%
\begin{frame}[t]{Tit 4}
frame 4
\end{frame}
%--- Next Frame ---%
\begin{frame}[t]{Tit 5}
frame 5
\end{frame}
%--- Next Frame ---%
\begin{frame}[t]{Tit 6}
frame 6
\end{frame}
%--- Next Frame ---%
\begin{frame}[standout]
% Gracias
% \flushleft
% Homework: p.342 \#7-21
\end{frame}
\end{document}
我也测试了 beamer 的解决方案Beamer - handoutWithNotes 无法正常工作:
\mode<handout>{
\usepackage{pgfpages}
\pgfpagesuselayout{6 on 1}[a4paper,border shrink=5mm]
\setbeamertemplate{note page}{%
\fontsize{12pt}{32pt}\selectfont
Notes
\rule{\textwidth}{1pt} \rule{\textwidth}{1pt} \rule{\textwidth}{1pt} \rule{\textwidth}{1pt} \rule{\textwidth}{1pt} \rule{\textwidth}{1pt} \rule{\textwidth}{1pt} \rule{\textwidth}{1pt}\par
}
\setbeameroption{show notes}
}
\makeatletter
\def\beamer@framenotesbegin{% at beginning of slide
\gdef\beamer@noteitems{}%
\gdef\beamer@notes{{}}% used to be totally empty.
}
\makeatother
在我的 MWE 中,在 之前添加这些行\begin{document}
对于简单的框架来说效果很好,但对于每个框架包含多张幻灯片的框架则不行。当同一帧中有几张幻灯片时,上述投影仪解决方案会将不同的幻灯片混合并叠加在一张打印的幻灯片中,如下所示:
在这种情况下,解决方案Beamer:制作讲义时出错是转到每张幻灯片并添加`<...|handout:0>如果您想删除某些内容,或者将 0 更改为应该出现该内容的任何幻灯片编号。
然而,实际的演示文稿有很多帧,每帧大约有五张幻灯片。演示文稿包含带有逐项<+->
<x-y>
幻灯片的幻灯片,\visible<x->
以添加图像,\onlyslides<x->
因此制作带有行注释的适当讲义是一项复杂的任务。
它看起来像添加样式的解决方案handoutWithNotes.sty
添加创建带有注释的 latex-beamer 讲义避免使用 进行逐张幻灯片区分|handout:x
。因此,我想问一下如何使用这种风格编译 MWE。我的电脑使用的是 MacTex2021 TeX 发行版。