latex - 如何在尾注中指定字体?
问题描述
问题是关于在使用 pagenote 包时格式化“report”和“memoir”文档类中的尾注字体。
在下面的最小示例中,当使用 \footnote 时,\footnotesize{} 命令按预期执行:脚注按照要求为 16pt。当尾注与 \pagenote 一起使用时,尾注在回忆录和报告环境中都按预期显示,但在这两种情况下都使用正文字体。
实际上,问题是如何创建像 \endnotesize{} 这样的东西?
\documentclass[a4paper,12pt,openany]{memoir}
% set the font size in the footnotes
\makeatother
\renewcommand{\footnotesize}{\fontsize{16pt}{16pt}\selectfont}
\usepackage{pagenote}
\makepagenote
\renewcommand*{\notedivision}{\chapter*{\notesname}}
\let\footnote\pagenote % toggle endnotes instead of footnotes
\begin{document}
\chapter{}
Here is the main text of the article\footnote{The first footnote in 16pt}
To clarify the situation a second footnote helps\footnote{The second footnote also 16pts}
%\printnotes % needed for report style
\printpagenotes % needed for memoir style
\end{document}
在这个例子中,如果使用 \printnotes 而不是 '\printpagenotes','memoir' 可以被 'report' 替代。通过注释掉 '\let\footnote\pagenote' 行,出现脚注而不是尾注。在 \footnote 模式下,此示例提供 16pt 脚注。
我的工作环境是 TexWorks 中的 pdfLatex。
解决方案
对于memoir
该类,您可以像这样重新定义\prenotetext
and\postnotetext
宏:
\documentclass[a4paper,12pt,openany]{memoir}
% set the font size in the footnotes
\makeatother
\renewcommand\prenotetext{\begingroup\fontsize{16pt}{16pt}\selectfont}
\renewcommand\postnotetext{\endgroup}
\usepackage{pagenote}
\makepagenote
\renewcommand*{\notedivision}{\chapter*{\notesname}}
\let\footnote\pagenote % toggle endnotes instead of footnotes
\begin{document}
\chapter{}
Here is the main text of the article\footnote{The first footnote in 16pt}
To clarify the situation a second footnote helps\footnote{The second footnote also 16pts}
%\printnotes % needed for report style
\printpagenotes % needed for memoir style
\end{document}
对于report
课堂:
\documentclass[a4paper,12pt,openany]{report}
% set the font size in the footnotes
\makeatother
\usepackage{pagenote}
\makepagenote
\renewcommand*{\notedivision}{\chapter*{\notesname}}
\renewcommand{\prenoteinnotes}{\par\fontsize{16pt}{16pt}\selectfont\noindent}
\renewcommand{\postnoteinnotes}{\par}
\let\footnote\pagenote % toggle endnotes instead of footnotes
\begin{document}
\chapter{}
Here is the main text of the article\footnote{The first footnote in 16pt}
To clarify the situation a second footnote helps\footnote{The second footnote also 16pts}
\printnotes % needed for report style
%\printpagenotes % needed for memoir style
\end{document}
推荐阅读
- php - 没有完整堆栈框架的 Symfony 组件
- r - 找不到函数 fix.dta
- javascript - 函数如何在 JavaScript 中引用自身?
- r - 熔化数据,保持某些列配对
- reactjs - React hooks useState 从 redux 状态获取不同的值
- rust - 为什么 Rust 找不到使用 proc_macro_attribute 生成的枚举的方法?
- python - 2 matplotlib 的交互式多边形编辑器不工作
- r - 在 R 的 for 循环中尝试 Catch
- lua - Pandoc 在 latex+raw_tex 和 lua 过滤器之后对元素重新运行 Latex 过滤器
- python - python套接字返回ConnectionRefusedError:[Errno 111]连接被拒绝