summaryrefslogtreecommitdiff
path: root/macros/latex/contrib
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2021-03-13 03:01:14 +0000
committerNorbert Preining <norbert@preining.info>2021-03-13 03:01:14 +0000
commit2a899339df4bb55e3aa0d5b7a4975b1743341e17 (patch)
tree4d26b328e10b82678abc4bd31726e8b2548eed42 /macros/latex/contrib
parentcf09e33d4f54e872c7090def0ad41b06fb559cdb (diff)
CTAN sync 202103130301
Diffstat (limited to 'macros/latex/contrib')
-rw-r--r--macros/latex/contrib/easybook/doc/chapter3.tex6
-rw-r--r--macros/latex/contrib/easybook/doc/easybook-demo.pdfbin288297 -> 287458 bytes
-rw-r--r--macros/latex/contrib/easybook/doc/easybook-demo.tex2
-rw-r--r--macros/latex/contrib/easybook/doc/easybook.pdfbin234688 -> 235059 bytes
-rw-r--r--macros/latex/contrib/easybook/doc/easybook.tex32
-rw-r--r--macros/latex/contrib/easybook/easybook.cls31
-rw-r--r--macros/latex/contrib/hvfloat/Changes1
-rw-r--r--macros/latex/contrib/hvfloat/doc/hvfloat.pdfbin2967825 -> 22514815 bytes
-rw-r--r--macros/latex/contrib/hvfloat/doc/hvfloat.tex300
-rw-r--r--macros/latex/contrib/hvfloat/latex/hvfloat.sty216
-rw-r--r--macros/latex/contrib/l3packages/CHANGELOG.md8
-rw-r--r--macros/latex/contrib/l3packages/README.md2
-rw-r--r--macros/latex/contrib/l3packages/l3keys2e.dtx4
-rw-r--r--macros/latex/contrib/l3packages/l3keys2e.ins2
-rw-r--r--macros/latex/contrib/l3packages/l3keys2e.pdfbin347033 -> 369105 bytes
-rw-r--r--macros/latex/contrib/l3packages/xfp.dtx5
-rw-r--r--macros/latex/contrib/l3packages/xfp.ins2
-rw-r--r--macros/latex/contrib/l3packages/xfp.pdfbin309353 -> 331452 bytes
-rw-r--r--macros/latex/contrib/l3packages/xfrac.dtx4
-rw-r--r--macros/latex/contrib/l3packages/xfrac.ins2
-rw-r--r--macros/latex/contrib/l3packages/xfrac.pdfbin453787 -> 481703 bytes
-rw-r--r--macros/latex/contrib/l3packages/xparse.dtx16
-rw-r--r--macros/latex/contrib/l3packages/xparse.ins2
-rw-r--r--macros/latex/contrib/l3packages/xparse.pdfbin505356 -> 531458 bytes
-rw-r--r--macros/latex/contrib/l3packages/xtemplate.dtx4
-rw-r--r--macros/latex/contrib/l3packages/xtemplate.ins2
-rw-r--r--macros/latex/contrib/l3packages/xtemplate.pdfbin415897 -> 438506 bytes
-rw-r--r--macros/latex/contrib/mindflow/mindflow.dtx45
-rw-r--r--macros/latex/contrib/mindflow/mindflow.ins10
-rw-r--r--macros/latex/contrib/mindflow/mindflow.pdfbin154231 -> 168685 bytes
-rw-r--r--macros/latex/contrib/srdp-mathematik/README.txt4
-rw-r--r--macros/latex/contrib/srdp-mathematik/srdp-mathematik.pdfbin167139 -> 169051 bytes
-rw-r--r--macros/latex/contrib/srdp-mathematik/srdp-mathematik.sty101
-rw-r--r--macros/latex/contrib/srdp-mathematik/srdp-mathematik.tex28
-rw-r--r--macros/latex/contrib/suppose/README.md24
-rw-r--r--macros/latex/contrib/suppose/suppose.pdfbin172118 -> 168506 bytes
-rw-r--r--macros/latex/contrib/suppose/suppose.sty6
-rw-r--r--macros/latex/contrib/suppose/suppose.tex59
-rw-r--r--macros/latex/contrib/thuthesis/CHANGELOG.md48
-rw-r--r--macros/latex/contrib/thuthesis/README.md6
-rw-r--r--macros/latex/contrib/thuthesis/data/appendix-survey.tex2
-rw-r--r--macros/latex/contrib/thuthesis/data/appendix-translation.tex2
-rw-r--r--macros/latex/contrib/thuthesis/data/appendix.tex4
-rw-r--r--macros/latex/contrib/thuthesis/data/chap01.tex2
-rw-r--r--macros/latex/contrib/thuthesis/data/chap02.tex70
-rw-r--r--macros/latex/contrib/thuthesis/data/chap03.tex29
-rw-r--r--macros/latex/contrib/thuthesis/data/comments.tex9
-rw-r--r--macros/latex/contrib/thuthesis/data/denotation.tex68
-rw-r--r--macros/latex/contrib/thuthesis/data/resolution.tex18
-rw-r--r--macros/latex/contrib/thuthesis/ref/refs.bib1
-rw-r--r--macros/latex/contrib/thuthesis/spine.pdfbin17199 -> 24091 bytes
-rw-r--r--macros/latex/contrib/thuthesis/thusetup.tex36
-rw-r--r--macros/latex/contrib/thuthesis/thuthesis-author-year.bbx2
-rw-r--r--macros/latex/contrib/thuthesis/thuthesis-author-year.bst46
-rw-r--r--macros/latex/contrib/thuthesis/thuthesis-bachelor.bst44
-rw-r--r--macros/latex/contrib/thuthesis/thuthesis-example.pdfbin449650 -> 395835 bytes
-rw-r--r--macros/latex/contrib/thuthesis/thuthesis-example.tex8
-rw-r--r--macros/latex/contrib/thuthesis/thuthesis-numeric.bbx2
-rw-r--r--macros/latex/contrib/thuthesis/thuthesis-numeric.bst46
-rw-r--r--macros/latex/contrib/thuthesis/thuthesis.dtx2124
-rw-r--r--macros/latex/contrib/thuthesis/thuthesis.ins21
-rw-r--r--macros/latex/contrib/thuthesis/thuthesis.pdfbin1027021 -> 1128526 bytes
62 files changed, 2436 insertions, 1070 deletions
diff --git a/macros/latex/contrib/easybook/doc/chapter3.tex b/macros/latex/contrib/easybook/doc/chapter3.tex
index 3d0a88bb1f..3790a3c47f 100644
--- a/macros/latex/contrib/easybook/doc/chapter3.tex
+++ b/macros/latex/contrib/easybook/doc/chapter3.tex
@@ -5,7 +5,7 @@
\section{代码}
\index{d@代码}
-\zhlipsum[42][name = aspirin]
+\zhlipsum[41][name = aspirin]
\begin{lstlisting}[language = Python,caption = {python程序练习题}]
#!/usr/bin/python
# -*- coding: UTF-8 -*-
@@ -26,9 +26,7 @@ if __name__ == '__main__':
\index{h@化学式}
阿司匹林还有三种作用方式。一是使线粒体的氧化磷酸化解偶联。阿司匹林会携带质子从线粒体膜间隙扩散进入线粒体基质,然后再次电离释放质子\ch{(NH4)2S}、\ch{[Cu(NH3)4]^2+}。
\[\ch{$x$ Na(NH4)HPO4 ->[$\Delta$] (NaPO3)_{$x$} + $x$ NH3 ^ + $x$ H2O}\]
-阿司匹林还有三种作用方式。
-\[\zihao{-5}\chemfig[cram width=5pt]{*6((-HO)-=-(-(<[::60]OH)-[::-60]-[::-60,,,2]
-HN-[::+60]CH_3)=-(-HO)=)}\]
+\zhlipsum[41][name = aspirin]
\clearpage
\section{引用}
diff --git a/macros/latex/contrib/easybook/doc/easybook-demo.pdf b/macros/latex/contrib/easybook/doc/easybook-demo.pdf
index 0d6441a9bf..677660d9b8 100644
--- a/macros/latex/contrib/easybook/doc/easybook-demo.pdf
+++ b/macros/latex/contrib/easybook/doc/easybook-demo.pdf
Binary files differ
diff --git a/macros/latex/contrib/easybook/doc/easybook-demo.tex b/macros/latex/contrib/easybook/doc/easybook-demo.tex
index 15e6900f2b..bed92304aa 100644
--- a/macros/latex/contrib/easybook/doc/easybook-demo.tex
+++ b/macros/latex/contrib/easybook/doc/easybook-demo.tex
@@ -97,7 +97,7 @@
\url{https://latexstudio.net} \\
\url{https://gitee.com/texl3/easybook}\thanks{Gitee为项目的主要发布地址。}
}
-\date{2021/03/11\hskip\ccwd\relax v1.23n}
+\date{2021/03/12\hskip\ccwd\relax v1.23o}
\frontmatter[roman]
\maketitle
diff --git a/macros/latex/contrib/easybook/doc/easybook.pdf b/macros/latex/contrib/easybook/doc/easybook.pdf
index ec447ae802..9dd3ad1ad2 100644
--- a/macros/latex/contrib/easybook/doc/easybook.pdf
+++ b/macros/latex/contrib/easybook/doc/easybook.pdf
Binary files differ
diff --git a/macros/latex/contrib/easybook/doc/easybook.tex b/macros/latex/contrib/easybook/doc/easybook.tex
index ba2df4076e..00de40fdd5 100644
--- a/macros/latex/contrib/easybook/doc/easybook.tex
+++ b/macros/latex/contrib/easybook/doc/easybook.tex
@@ -2,7 +2,7 @@
\title{\sffamily easybook书籍文档类}
\author{瞿毅}
-\date{2021/03/11\hskip\ccwd\relax v1.23n\thanks{\url{https://gitee.com/texl3/easybook}}}
+\date{2021/03/12\hskip\ccwd\relax v1.23o\thanks{\url{https://gitee.com/texl3/easybook}}}
\begin{document}
\maketitle
@@ -97,7 +97,7 @@
\tn{frontmatter}\oarg{编号格式|(Roman)}
\tn{printindex}\oarg{索引名}
\end{syntax}
-\changes{v1.23n}{2021/02/20}{重新定义文档结构划分命令。}
+\changes{v1.23o}{2021/02/20}{重新定义文档结构划分命令。}
\tn{frontmatter} 为前言区命令,章标题不编号,页码可设置为例如 \opt{roman}、\opt{Alph} 等格式,带有星号的命令 \tn{frontmatter*} 不使用 \tn{cleardoublepage}。\tn{mainmatter} 为主文区命令,章标题正常编号且页码为从1开始计数的阿拉伯数字,\tn{mainmatter*} 命令不使用 \tn{cleardoublepage}。\tn{backmatter} 为后记区命令,页码格式与编号保持不变,章标题不编号。\tn{listoffigures} 命令输出图片目录,\tn{listoftables} 命令输出表格目录,\tn{listoflistings} 命令输出代码目录。
\end{function}
@@ -131,8 +131,8 @@
uppercase = <(true)|false>
\end{syntax}
\changes{v1.10}{2021/01/08}{更改颜色实现方式与选项名。}
-\changes{v1.23n}{2021/02/02}{noto风格的数学字体独立出来,可自定义设置。}
-\changes{v1.23n}{2021/02/09}{增加控制页面横线粗细的选项。}
+\changes{v1.23o}{2021/02/02}{noto风格的数学字体独立出来,可自定义设置。}
+\changes{v1.23o}{2021/02/09}{增加控制页面横线粗细的选项。}
\opt{style} 选项控制文章的风格。
\end{function}
@@ -189,7 +189,7 @@
footnote = <(1)>
\end{syntax}
\changes{v1.21}{2021/01/12}{增加脚注线间的距离选项。}
-\changes{v1.23n}{2021/02/09}{取消使用 \pkg{zhlineskip} 宏包设置数学间距。}
+\changes{v1.23o}{2021/02/09}{取消使用 \pkg{zhlineskip} 宏包设置数学间距。}
行距因子用于设置各种行距倍数,只能是浮点数,不能带有长度单位。\tn{ctexset} 原有的行距选项\opt{linespread}失效。各行距既可在导言区全局设置也可正文中设置对后面生效,行距的意义为
\end{function}
@@ -211,7 +211,7 @@
marginpart = <\tn{rmfamily}\tn{footnotesize}>
\end{syntax}
\changes{v1.10}{2021/01/08}{加入自定义非正文字体选项。}
-\changes{v1.23n}{2021/02/08}{修复使用 \tn{zihao} 命令设置字体失效的问题。}
+\changes{v1.23o}{2021/02/08}{修复使用 \tn{zihao} 命令设置字体失效的问题。}
\end{function}
\begin{optdesc}
@@ -232,7 +232,7 @@
\tn{printbibliography}\oarg{选项列表}
\end{syntax}
\changes{v1.21}{2021/01/11}{增加 \opt{bibset} 选项,可以使用 \hologo{BibTeX} 或 \hologo{biber} 编译参考文献。}
-\changes{v1.23n}{2021/02/23}{使用 \opt{bibset} 选项时可设置标注风格。}
+\changes{v1.23o}{2021/02/23}{使用 \opt{bibset} 选项时可设置标注风格。}
\end{function}
\begin{optdesc}
@@ -244,7 +244,7 @@
\end{optdesc}
\subsection{定理样式}
-\begin{function}[EXP,added = 2021-01-12,updated = 2021-01-18]{thmset/thmbox,thmset/numberwith,thmset/headpunct,thmset/bodyfont,thmset/notefont,thmset/headfont,thmset/headindent,thmset/spaceabove,thmset/spacebelow,thmset/spacepost}
+\begin{function}[EXP,added = 2021-01-12,updated = 2021-03-12]{thmset/thmbox,thmset/numberwith,thmset/headpunct,thmset/bodyfont,thmset/notefont,thmset/headfont,thmset/headindent,thmset/spaceabove,thmset/spacebelow,thmset/spacepost,\newtheorem}
\begin{syntax}
thmbox = <true|(false)>
numberwith = <(chapter)|section|其它环境|空置>
@@ -256,8 +256,10 @@
spaceabove = <(0.75ex plus .1ex)>
spacebelow = <(0.75ex plus .1ex)>
spacepost = <(\tn{ccwd})>
+ \tn{newtheorem}\oarg{键值列表}\marg{定理环境名}
\end{syntax}
\changes{v1.21}{2021/01/12}{增加配置定理环境样式的选项。}
+\changes{v1.23o}{2021/03/12}{增加定义新定理环境的命令 \tn{newtheorem}。}
\end{function}
\begin{optdesc}
@@ -271,14 +273,18 @@
\item[spaceabove] 定理环境前的间距。
\item[spacebelow] 定理环境后的间距。
\item[spacepost] 定理标题后与内容的间距。
+ \item[\tn{newtheorem}] 定义新的定理类环境,可选参数与 \pkg{thmtools} 宏包定理命令的参数一致。
\end{optdesc}
\subsubsection{新的定理样式}
定理由 \pkg{thmtools} 设置,自带定理的样式为 \opt{mythm},如果使用这个样式而只是增加新的定理名称,可以这样
\begin{ctexexam}
- \AfterPreamble{\declaretheorem[style = mythm,name = 定理名]{定理环境名}}
+ \newtheorem[style = mythm,name = 定理名]{定理环境名}
+\end{ctexexam}
+若要给定理环境增加边框,可以如下进行设置
+\begin{ctexexam}
+ \tcolorboxenvironment{定理环境名}{thmsty}
\end{ctexexam}
-若要重新定义一个全新的定理样式,具体参数可以查看 \pkg{thmtools} 宏包帮助文档。
\subsection{页面边距}
\begin{function}[EXP,added = 2021-01-13]{geoset/left,geoset/top,geoset/hmargin,geoset/textwidth,geoset/includehead,...}
@@ -316,7 +322,7 @@
\end{syntax}
\changes{v1.21}{2021/01/11}{修复单面文档时页眉横线消失的问题。}
\changes{v1.21}{2021/01/13}{增加配置页眉页脚的选项。}
-\changes{v1.23n}{2021/03/08}{优化页眉页脚设置,增加 \opt{chap-mark} 和 \opt{sec-mark} 选项。}
+\changes{v1.23o}{2021/03/08}{优化页眉页脚设置,增加 \opt{chap-mark} 和 \opt{sec-mark} 选项。}
\opt{hdrset} 设置的命令由 \pkg{fancyhdr} 宏包提供支持,命令 \tn{easyhead} 和 \tn{easyfoot} 的含义与 \tn{fancyhead} 和 \tn{fancyfoot} 相同,它们用于 \opt{head-foot} 选项中,设置的是一个名为 \opt{fancy} 的页面风格。\pkg{fancyhdr} 将页眉页脚分成了左中右和奇数页(odd)、偶数页(even)共12个部分,可选参数中E、O代表偶数、奇数,L、C、R代表左、中、右部分。单面打印时,含有偶数的选项无效。
\begin{ctexexam}
\ctexset
@@ -437,7 +443,7 @@
\tn{item} <习题内容>
\tn{end}\marg{exercise}
\end{syntax}
-\changes{v1.23n}{2021/02/08}{增加准确的习题盒子标题目录锚点。}
+\changes{v1.23o}{2021/02/08}{增加准确的习题盒子标题目录锚点。}
习题环境 \opt{exercise} 的标题紧接上一节编号并加入目录与页眉,当使用星号环境时不进行编号。三个可选参数中颜色为自定义或 \pkg{xcolor} 包含的颜色名称,正文编号格式与小节 \ref{sort list} 排序列表相同,标题名默认为摘要,参数只能\textbf{从右往左}省略。
\begin{ctexexam}
\begin{exercise}[LightYellow][1.][习题]
@@ -527,7 +533,7 @@
\tn{ch}\oarg{选项}\marg{输入}
\tn{chemfig}\oarg{键值列表}\marg{分子代码}
\end{syntax}
-除了以普通公式的方式,化学式还可用 \pkg{chemformula} 实现,无机化学式使用 \tn{ch} 命令书写。有机化学式推荐使用 \pkg{chemfig} 的 \tn{chemfig} 命令完成。
+除了以普通公式的方式,化学式还可用 \pkg{chemformula} 实现,无机化学式使用 \tn{ch} 命令书写。有机化学式推荐使用 \pkg{chemfig}(并未载入)的 \tn{chemfig} 命令完成。
\end{function}
\subsection{引用}
diff --git a/macros/latex/contrib/easybook/easybook.cls b/macros/latex/contrib/easybook/easybook.cls
index 4405556f09..f639eeb570 100644
--- a/macros/latex/contrib/easybook/easybook.cls
+++ b/macros/latex/contrib/easybook/easybook.cls
@@ -9,7 +9,7 @@
%% https://creativecommons.org/licenses/by/4.0/legalcode
\NeedsTeXFormat{LaTeX2e}
\RequirePackage{l3keys2e}
-\ProvidesExplClass{easybook}{2021/03/11}{1.23n}{}
+\ProvidesExplClass{easybook}{2021/03/12}{1.23o}{}
\cs_generate_variant:Nn \keys_define:nn {nx}
\cs_generate_variant:Nn \int_to_arabic:n {v}
@@ -81,8 +81,19 @@
{\__put_ctexbook:n {scheme = chinese}}
{\__put_ctexbook:n {scheme = plain}}
+\clist_map_inline:nn
+ {
+ {svgnames}{xcolor},
+ {hang,stable}{footmisc},
+ {normalem}{ulem},
+ {protrusion = false}{microtype},
+ {shortlabels,inline}{enumitem},
+ {most}{tcolorbox},
+ {xindy}{imakeidx},
+ {CJKmath = true}{xeCJK},
+ {no-math}{fontspec}
+ }{\PassOptionsToPackage#1}
\__put_ctexbook:n {\g__options_clist}
-\PassOptionsToPackage{CJKmath = true}{xeCJK}
\LoadClass[UTF8]{ctexbook}
\bool_new:N \l__capdash_bool
@@ -136,23 +147,13 @@
uppercase .initial:n = true
}
-\clist_map_inline:nn
- {
- {svgnames}{xcolor},
- {hang,stable}{footmisc},
- {normalem}{ulem},
- {protrusion = false}{microtype},
- {shortlabels,inline}{enumitem},
- {most}{tcolorbox},
- {xindy}{imakeidx}
- }{\PassOptionsToPackage#1}
\RequirePackage
{
xcolor,
pdfpages,
footmisc,setspace,
amsmath,amsthm,thmtools,cases,
- chemformula,chemfig,siunitx,ulem,
+ chemformula,siunitx,ulem,
geometry,marginnote,nccfoots,
rotfloat,graphicx,
fancyhdr,titletoc,
@@ -395,7 +396,7 @@
}
\cs_gset:Npn \headrule
{
- \color{ctex@frame}\vspace{2.5pt}
+ \color{ctex@frame}\vspace{1.5pt}
\hrule width\textwidth height \l__rule_width_dim
}
\bool_if:NT \l__draft_bool
@@ -792,6 +793,8 @@
\tl_new:N \l__thm_spaceabove_tl
\tl_new:N \l__thm_spacebelow_tl
+\RenewDocumentCommand{\newtheorem}{O{}m}
+ {\AfterPreamble{\declaretheorem[#1]{#2}}}
\__ctex_define:nn {thmset}
{
thmbox .bool_set:N = \l__thmbox_bool,
diff --git a/macros/latex/contrib/hvfloat/Changes b/macros/latex/contrib/hvfloat/Changes
index 083cd05ceb..796f24877b 100644
--- a/macros/latex/contrib/hvfloat/Changes
+++ b/macros/latex/contrib/hvfloat/Changes
@@ -1,4 +1,5 @@
hvfloat.sty:
+2.18 2021-03-12 - add support for doublepage objects
2.17 2020-10-31 - fix for label setting of non floating objects
2.16 2019-08-31 - fix for \hvFloat* and full page images
2.15 2019-05-13 - added optional arguments capFormat and subcapFormat
diff --git a/macros/latex/contrib/hvfloat/doc/hvfloat.pdf b/macros/latex/contrib/hvfloat/doc/hvfloat.pdf
index 0928f3b187..adcbeecc69 100644
--- a/macros/latex/contrib/hvfloat/doc/hvfloat.pdf
+++ b/macros/latex/contrib/hvfloat/doc/hvfloat.pdf
Binary files differ
diff --git a/macros/latex/contrib/hvfloat/doc/hvfloat.tex b/macros/latex/contrib/hvfloat/doc/hvfloat.tex
index 5c330d4209..0896645980 100644
--- a/macros/latex/contrib/hvfloat/doc/hvfloat.tex
+++ b/macros/latex/contrib/hvfloat/doc/hvfloat.tex
@@ -42,6 +42,11 @@
\usepackage{multicol}
\usepackage{blindtext}
+\let\hvBlindtext\Blindtext
+\def\Blindtext{\par\color{black!40}\hvBlindtext\par\normalcolor}
+\makeatletter
+\def\hvblindtext{\textcolor{black!40}{\blindtext@text}}
+\makeatother
\usepackage{marginnote}
%\usepackage{imakeidx}
@@ -550,7 +555,7 @@ Code for figure \ref{fig:1}:
objectPos=c]{figure}{\includegraphics[scale=0.9]{images/rose}}%
[Caption beside object and vertically centered]%
{Caption vertically centered right beside the float with a natural caption width
- (the default). \blindtext}%
+ (the default). \hvblindtext}%
{fig:1}
@@ -589,7 +594,7 @@ placed vertically centered to the object. Important for the height of the object
orthogonal rectangle.
-\blindtext
+\hvblindtext
Code for figure \ref{fig:3}:
\begin{lstlisting}
@@ -642,7 +647,7 @@ Code for figure~\ref{fig:20}:
a caption on the right side for an even page and on the left side for
an odd page.}{fig:20}
-\blindtext
+\hvblindtext
\label{page:1}\checkoddpage
@@ -688,7 +693,7 @@ even \fi page, the reason why figure~\ref{fig:20b} has the caption for \emph{inn
and figure~\ref{fig:21} for \emph{outer} on the right side.
-\blindtext
+\hvblindtext
\label{page:2}
Code for figure \ref{fig:22}:
@@ -806,7 +811,7 @@ in a minipage, the reason why it will be local to the current image..
\hvFloat[%
capPos=right,
capFormat={labelsep=newline,justification=RaggedRight,font={small,it},labelfont=bf}
-]{figure}{\frame{\includegraphics{images/rose}}}{\blindtext}{fig:66}
+]{figure}{\frame{\includegraphics{images/rose}}}{\hvblindtext}{fig:66}
\section{Horizontal Position of the Float}
@@ -842,7 +847,7 @@ The code for figure \ref{fig:7}:
]{figure}{\includegraphics{images/rose}}{%
Caption at top right beside the float and object position left}{fig:7}
-\blindtext
+\hvblindtext
The same with \Lkeyset{capPos=left}:
@@ -858,7 +863,7 @@ The same with \Lkeyset{capPos=left}:
]{figure}{\includegraphics{images/rose}}{%
Caption at top right beside the float and object position left}{fig:700}
-\blindtext
+\hvblindtext
The code for figure \ref{fig:8}:
@@ -884,7 +889,7 @@ The code for figure \ref{fig:8}:
]{figure}{\includegraphics{images/rose}}{%
Caption at top left beside the float and object position right}{fig:8}
-\blindtext
+\hvblindtext
\section{Wide floats}
@@ -913,7 +918,7 @@ the option \texttt{wide}.}{fig:70}
Caption at top right beside the float and object position left and
the option \texttt{wide}.}{fig:70}
-%\blindtext
+%\hvblindtext
The code for figure \ref{fig:80}:
@@ -939,7 +944,7 @@ The code for figure \ref{fig:80}:
For a twosided document it will place the object always in the margin.
-\blindtext
+\hvblindtext
\begin{lstlisting}
\hvFloat[wide,
@@ -962,7 +967,7 @@ the option \texttt{wide}.}{fig:81}
Now we set the same image with the same setting on the next page. The caption will
change its side due to the setting \Lkeyset{capPos=outer}.
-\blindtext
+\hvblindtext
@@ -1074,10 +1079,10 @@ with the \Lkeyset{objectPos=l} parameter
objectPos=center,
]{figure}{\includegraphics[width=0.9\textheight]{images/CTAN}}%
[Object and Caption in landscape mode]{%
- Caption and object in landscape mode. \blindtext}{fig:9}
+ Caption and object in landscape mode. \hvblindtext}{fig:9}
-\blindtext
+\hvblindtext
The code for figure \ref{fig:10}:
@@ -1106,13 +1111,13 @@ The code for figure \ref{fig:10}:
]{figure}{\includegraphics[width=\textheight]{images/CTAN}}%
[Rotated Caption in Landscape]{%
Caption right beside the float and object position left. The caption rotated by $-90$ degrees.
- \blindtext}{fig:10}
+ \hvblindtext}{fig:10}
-\blindtext
+\hvblindtext
-\blindtext
+\hvblindtext
@@ -1186,7 +1191,7 @@ For example see table~\ref{table:1} and \ref{table:2}:
\end{tabular}%
}
-\blindtext
+\hvblindtext
%[xrightmargin=-8em,xleftmargin=-1em]
\begin{lstlisting}
@@ -1211,7 +1216,7 @@ The code for table \ref{table:1} and \ref{table:2} is:
capPos=top,
useOBox=true]{table}{}{Demonstration of the \texttt{useOBox} Parameter}{table:1}
-\blindtext
+\hvblindtext
\hvFloat[%
floatPos=hb,
@@ -1279,9 +1284,9 @@ The code for figure \ref{fig:text}:
a starting \texttt{Figure:} or \texttt{Table:}}{fig:text}
\bigskip
-%\blindtext
+%\hvblindtext
-%\blindtext
+%\hvblindtext
\section{Environment \texttt{hvFloatEnv}}\label{sec:env}
@@ -1332,9 +1337,9 @@ L & C & R \\\hline
\end{hvFloatEnv}
%\bigskip
-%\blindtext
+%\hvblindtext
-%\blindtext
+%\hvblindtext
\section{Full page objects in onecolumn mode}
@@ -2439,6 +2444,246 @@ should be true (see listing).
%\index{capPos@\texttt {capPos} (keyword)|)}
+\section{Doublepage objects -- images and/or tabulars}
+If an image or a tabular or any other object is too big for one page, it can be split over two pages (left -- right).
+It is obvious that this makes only sense for twoside documents.
+There are three optional arguments:
+
+\begin{description}
+\item[\Lkeyword{doublePage}] A splitted object with or without a caption on top of a double page, beginning in the left top text area.
+The user has to scale the image to be sure that the object will not be greater than \verb|2\paperwidth-4\margin|. The caption can be rotated
+on the right side of the right object part or under the right part.
+
+
+\item[\Lkeyword{doublePAGE}] A splitted object with or without a caption on top of a double page, beginning at the left side
+of the paper area and top of the text area.
+The user has to scale the image to be sure that the object will not be greater than \verb|2\paperwidth|. The caption can only be
+under the right part of the object. The will be \emph{no additional text} on the double page.
+
+\item[\Lkeyword{doubleFULLPAGE}] A splitted object with or without a caption on top of a double page, beginning at the
+left top paper edge and filling the complete double page.
+The user has to scale the image to be sure that the object will not be greater than \verb|2\paperwidth|. A caption will be
+rotated and written \emph{over} the object. The user has to take care for a correct text color.
+\end{description}
+
+\subsection{\Lkeyword{doubleFULLPAGE}}
+The scaling of the image is leave to the user. If the proportion of the object doesn't fit 2*paperwidth/paperheight,
+then there can be a white part on the right or bottom of the object. A pagenumber will not be printed. You'll
+find a marginnote where the following full doublepage image is defined. It appears on the the next following
+even page and following text will be placed \emph{before} the object.
+
+
+
+\begin{lstlisting}
+\Blindtext
+
+\hvFloat[doubleFULLPAGE,capPos=r,capAngle=90]%
+ {figure}%
+ {\includegraphics[angle=90,width=2\paperwidth]{images/raphi}}%
+ [Eine doppelseitige Abbildung mit Caption auf der Abbildung]%
+ {Eine Beschriftung einer doppelseitigen Abbildung, die ÜBER den rechten
+ Teil der Abbildung platziert wird. Die Abbildung beginnt am linken
+ Papierrand. Auf den Seiten wird kein weiterer Text
+ platziert. Für das LOF wird dabei eine Kurzform berücksichtigt. Parameter
+ ist \texttt{doubleFULLPAGE}}%
+ {fig:doubleFULLPAGE0}
+
+\Blindtext
+\end{lstlisting}
+
+\Blindtext
+\marginnote{doubleFULLPAGE0}
+ \hvFloat[doubleFULLPAGE,capPos=r,capAngle=90]%
+ {figure}%
+ {\includegraphics[angle=90,width=2\paperwidth]{images/raphi}}%
+ [Eine doppelseitige Abbildung mit Caption auf der Abbildung]%
+ {Eine Beschriftung einer doppelseitigen Abbildung, die ÜBER den rechten
+ Teil der Abbildung platziert wird. Die Abbildung beginnt am linken
+ Papierrand. Auf den Seiten wird kein weiterer Text
+ platziert. Für das LOF wird dabei eine Kurzform berücksichtigt. Parameter
+ ist \texttt{doubleFULLPAGE}}%
+ {fig:doubleFULLPAGE0}
+
+\Blindtext
+
+\Blindtext
+
+\subsection{\Lkeyword{doublePAGE}}
+With this option the object also starts at the left paper margin but on the top of the text area.
+There will be pagenumbers and a caption can be rotated on the right of the object or under it.
+
+\begin{lstlisting}
+\Blindtext
+
+\hvFloat[doublePAGE]%
+ {figure}%
+ {\includegraphics[width=2\paperwidth]{images/felsen-wasser}}%
+ [Eine doppelseitige Abbildung mit Caption unterhalb der rechten Abbildung]%
+ {Eine Beschriftung einer doppelseitigen Abbildung, die unterhalb der rechten
+ Teils der Abbildung platziert wird. Die Abbildung beginnt am linken
+ Papierrand. Auf den Seiten wird kein weiterer Text
+ platziert. Für das LOF wird dabei eine Kurzform berücksichtigt. Parameter
+ ist \texttt{doublePAGE}}%
+ {fig:doublePAGE0}
+
+\Blindtext
+\end{lstlisting}
+
+\Blindtext
+
+\marginnote{doublePAGE0}
+\hvFloat[doublePAGE]%
+ {figure}%
+ {\includegraphics[width=2\paperwidth]{images/felsen-wasser}}%
+ [Eine doppelseitige Abbildung mit Caption unterhalb der rechten Abbildung]%
+ {Eine Beschriftung einer doppelseitigen Abbildung, die unterhalb der rechten
+ Teils der Abbildung platziert wird. Die Abbildung beginnt am linken
+ Papierrand. Auf den Seiten wird kein weiterer Text
+ platziert. Für das LOF wird dabei eine Kurzform berücksichtigt. Parameter
+ ist \texttt{doublePAGE}}%
+ {fig:doublePAGE0}
+
+\Blindtext
+
+
+\subsection{\Lkeyword{doublePage}}
+With this option the object also starts at the left top of the text area.
+There will be pagenumbers and a caption can be rotated on the right of the object or under it
+and the rest of the text area is filled with text.
+
+\begin{lstlisting}
+\Blindtext
+
+\hvFloat[doublePage,capWidth=n,capPos=r]%
+ {figure}%
+ {\includegraphics[width=2\textwidth]{images/felsen-wasser-small}}%
+ [Eine doppelseitige Abbildung mit rechtsseitiger Caption unterhalb]%
+ {Eine Beschriftung einer doppelseitigen Abbildung, die unterhalb des rechten
+ Teils der Abbildung platziert wird. Die Abbildung beginnt am linken
+ Textrand. Auf den Seiten wird ansonsten weiterer Text
+ platziert. Für das LOF wird dabei eine Kurzform berücksichtigt. Parameter
+ ist \texttt{doublePage}}%
+ {fig:doublePage0}
+
+\Blindtext
+\end{lstlisting}
+
+\Blindtext
+
+\marginnote{doublePage0}
+\hvFloat[doublePage,capWidth=n,capPos=r]%
+ {figure}%
+ {\includegraphics[width=2\textwidth]{images/felsen-wasser-small}}%
+ [Eine doppelseitige Abbildung mit rechtsseitiger Caption unterhalb]%
+ {Eine Beschriftung einer doppelseitigen Abbildung, die unterhalb des rechten
+ Teils der Abbildung platziert wird. Die Abbildung beginnt am linken
+ Textrand. Auf den Seiten wird ansonsten weiterer Text
+ platziert. Für das LOF wird dabei eine Kurzform berücksichtigt. Parameter
+ ist \texttt{doublePage}}%
+ {fig:doublePage0}
+
+\Blindtext
+
+
+
+\subsection{Tabulars}
+
+In General there is no difference in an imgage or tabular or simple text. The object will be saved in a box and
+then clipped. If the object is a tabular one might modify the tabular if it will be split in the middle of a
+column. In such a case one can insert some additional horizontal space for this coloumn.
+
+The tabular itself can be saved into the internal box \Lcs{hvOBox} or put directly as parameter into the
+macro.
+
+
+\begin{lstlisting}[basicstyle=\footnotesize\ttfamily]
+\global\savebox\hvOBox{%
+\begin{tabular}{l*{18}r} \toprule
+ & \textbf{1972} & \textbf{1973} & \textbf{1974} & \textbf{1975} & \textbf{1976}
+ & \textbf{1977} & \textbf{1978} & \textbf{1979} & \textbf{1980} & \textbf{1981} & \textbf{1982} & \textbf{1983} & \textbf{1984} & \textbf{1985}
+ & \textbf{1986} & \textbf{1987} & \textbf{1988} & \textbf{1989}
+ \\\midrule
+\addlinespace[3pt]
+Zeile 1 & 1 & 3 & 1 & 1 & 1 & 0 & 1 & 1 & 0 & 0 & 0 & 0 &20 & 0 & 2 & 2 & 2 & 1\\\addlinespace[3pt]
+Zeile 2 & 1 & 1 & 3 & 1 & 0 & 0 & 0 & 0 & 0 & 0 & 2 & 1 & 3 & 4 & 4 & 6 & 4 & 2\\\addlinespace[3pt]
+Zeile 3 & 2 & 1 & 2 & 1 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 1 & 5 & 3 & 1 & 7 & 7 & 3\\\addlinespace[3pt]
+Zeile 4 & 1 & 0 & 5 & 1 & 2 & 0 & 0 & 0 & 0 & 2 & 1 & 0 & 1 & 0 & 3 & 7 & 2 & 1\\\addlinespace[3pt]
+Zeile 6 & 2 & 1 & 1 & 0 & 0 & 0 & 0 & 0 & 0 & 1 & 2 & 0 & 5 & 2 & 2 & 5 & 4 & 2\\\addlinespace[3pt]
+Zeile 5 & 0 & 0 & 4 & 2 & 1 & 2 & 2 & 1 & 0 & 0 & 0 & 1 & 1 & 0 & 2 & 5 & 4 & 3\\\addlinespace[3pt]
+Zeile 8 & 0 & 1 & 1 & 0 & 0 & 0 & 1 & 1 & 0 & 3 & 2 & 1 & 2 & 1 & 3 & 5 & 3 & 4\\\addlinespace[3pt]
+Zeile 9 & 0 & 0 & 0 & 0 & 0 & 1 & 2 & 1 & 0 & 0 & 0 & 0 & 4 & 2 & 1 & 4 & 5 & 2\\\addlinespace[3pt]
+Zeile10 & 0 & 1 & 3 & 0 & 1 & 0 & 1 & 0 & 0 & 1 & 1 & 0 & 1 & 1 & 1 & 4 & 4 & 1\\\addlinespace[3pt]
+Zeile11 & 0 & 2 & 2 & 1 & 1 & 0 & 1 & 0 & 0 & 0 & 0 & 2 & 6 & 1 & 0 & 2 & 1 & 1 \\\addlinespace[3pt]
+Zeile12 & 2 & 0 & 2 & 4 & 1 & 0 & 4 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 1 & 0 & 3\\\addlinespace[3pt]
+Lärm & 2 & 3 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 1 & 0 & 2 & 0 & 0 & 2 & 2 & 2\\\addlinespace[3pt]
+Zeile13 & 0 & 1 & 0 & 0 & 1 & 0 & 3 & 0 & 0 & 0 & 0 & 0 & 2 & 0 & 1 & 3 & 0 & 2\\\addlinespace[3pt]
+Zeile14 & 0 & 1 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 3 & 3 & 2 & 1 & 1 & 0\\\addlinespace[3pt]
+Zeile15 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 1 & 0 & 0 & 4 & 0 & 0 & 3 & 1 & 1\\\addlinespace[3pt]
+Zeile16 & 0 & 0 & 0 & 0 & 0 & 1 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 3 & 5 & 0 & 1\\\addlinespace[3pt]\midrule
+Artikel gesamt & 2 & 6 & 13 & 8 & 4 & 3 & 5 & 4 & 0 & 6 & 3 & 5 &23 &10 & 8 & 15 & 13 &1 \\
+\bottomrule
+\end{tabular}}
+
+\hvFloat[doublePage,capWidth=n,capPos=r]%
+ {table}%
+ {\usebox\hvOBox}%%%%%%%%%%%%%%
+ [Eine doppelseitige Tabelle mit rechtsseitiger Caption unterhalb]%
+ {Eine Beschriftung einer doppelseitigen Tabelle, die unterhalb des rechten
+ Teils der Abbildung platziert wird. Die Tabelle beginnt am linken
+ Textrand. Auf den Seiten wird ansonsten weiterer Text
+ platziert. Für das LOT wird dabei eine Kurzform berücksichtigt. Parameter
+ ist \texttt{doublePage}}%
+ {tab:doublePage3}
+
+\Blindtext
+\end{lstlisting}
+
+\Blindtext
+
+\marginpar{doublePage1}
+\global\savebox\hvOBox{%
+\begin{tabular}{l*{18}r} \toprule
+ & \textbf{1972} & \textbf{1973} & \textbf{1974} & \textbf{1975} & \textbf{1976}
+ & \textbf{1977} & \textbf{1978} & \textbf{1979} & \textbf{1980} & \textbf{1981} & \textbf{1982} & \textbf{1983} & \textbf{1984} & \textbf{1985}
+ & \textbf{1986} & \textbf{1987} & \textbf{1988} & \textbf{1989}
+ \\\midrule
+\addlinespace[3pt]
+Zeile 1 & 1 & 3 & 1 & 1 & 1 & 0 & 1 & 1 & 0 & 0 & 0 & 0 &20 & 0 & 2 & 2 & 2 & 1\\\addlinespace[3pt]
+Zeile 2 & 1 & 1 & 3 & 1 & 0 & 0 & 0 & 0 & 0 & 0 & 2 & 1 & 3 & 4 & 4 & 6 & 4 & 2\\\addlinespace[3pt]
+Zeile 3 & 2 & 1 & 2 & 1 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 1 & 5 & 3 & 1 & 7 & 7 & 3\\\addlinespace[3pt]
+Zeile 4 & 1 & 0 & 5 & 1 & 2 & 0 & 0 & 0 & 0 & 2 & 1 & 0 & 1 & 0 & 3 & 7 & 2 & 1\\\addlinespace[3pt]
+Zeile 6 & 2 & 1 & 1 & 0 & 0 & 0 & 0 & 0 & 0 & 1 & 2 & 0 & 5 & 2 & 2 & 5 & 4 & 2\\\addlinespace[3pt]
+Zeile 5 & 0 & 0 & 4 & 2 & 1 & 2 & 2 & 1 & 0 & 0 & 0 & 1 & 1 & 0 & 2 & 5 & 4 & 3\\\addlinespace[3pt]
+Zeile 8 & 0 & 1 & 1 & 0 & 0 & 0 & 1 & 1 & 0 & 3 & 2 & 1 & 2 & 1 & 3 & 5 & 3 & 4\\\addlinespace[3pt]
+Zeile 9 & 0 & 0 & 0 & 0 & 0 & 1 & 2 & 1 & 0 & 0 & 0 & 0 & 4 & 2 & 1 & 4 & 5 & 2\\\addlinespace[3pt]
+Zeile10 & 0 & 1 & 3 & 0 & 1 & 0 & 1 & 0 & 0 & 1 & 1 & 0 & 1 & 1 & 1 & 4 & 4 & 1\\\addlinespace[3pt]
+Zeile11 & 0 & 2 & 2 & 1 & 1 & 0 & 1 & 0 & 0 & 0 & 0 & 2 & 6 & 1 & 0 & 2 & 1 & 1 \\\addlinespace[3pt]
+Zeile12 & 2 & 0 & 2 & 4 & 1 & 0 & 4 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 1 & 0 & 3\\\addlinespace[3pt]
+Lärm & 2 & 3 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 1 & 0 & 2 & 0 & 0 & 2 & 2 & 2\\\addlinespace[3pt]
+Zeile13 & 0 & 1 & 0 & 0 & 1 & 0 & 3 & 0 & 0 & 0 & 0 & 0 & 2 & 0 & 1 & 3 & 0 & 2\\\addlinespace[3pt]
+Zeile14 & 0 & 1 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 3 & 3 & 2 & 1 & 1 & 0\\\addlinespace[3pt]
+Zeile15 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 1 & 0 & 0 & 4 & 0 & 0 & 3 & 1 & 1\\\addlinespace[3pt]
+Zeile16 & 0 & 0 & 0 & 0 & 0 & 1 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 3 & 5 & 0 & 1\\\addlinespace[3pt]\midrule
+Artikel gesamt & 2 & 6 & 13 & 8 & 4 & 3 & 5 & 4 & 0 & 6 & 3 & 5 &23 &10 & 8 & 15 & 13 &1 \\
+\bottomrule
+\end{tabular}}
+
+\hvFloat[doublePage,capWidth=n,capPos=r]%
+ {table}%
+ {\usebox\hvOBox}%%%%%%%%%%%%%%
+ [Eine doppelseitige Tabelle mit rechtsseitiger Caption unterhalb]%
+ {Eine Beschriftung einer doppelseitigen Tabelle, die unterhalb des rechten
+ Teils der Abbildung platziert wird. Die Tabelle beginnt am linken
+ Textrand. Auf den Seiten wird ansonsten weiterer Text
+ platziert. Für das LOT wird dabei eine Kurzform berücksichtigt. Parameter
+ ist \texttt{doublePage}}%
+ {tab:doublePage3}
+
+\Blindtext
+
+\Blindtext
+
+
\section{References to the page}\label{varioref}
@@ -2513,6 +2758,8 @@ For example:
\texttt{0.5\textbackslash columnwidth}.}{fig:style}
\end{lstlisting}
+
+\setDefaults
\defhvstyle{RightCaption}{floatPos=htb, capWidth=0.5, capPos=after, capVPos=bottom, objectPos=center}
@@ -2521,6 +2768,9 @@ For example:
\texttt{0.5\textbackslash columnwidth}.}{fig:style}
+\hvblindtext
+
+
\section{Global float setting}
Instead of writing the following sequence into the preamble:
@@ -2540,11 +2790,9 @@ optional package options to set the global placement:
\usepackage[figure=tb,table=t]{hvfloat-fps}
\end{verbatim}
-\blindtext
-
-\blindtext
+\Blindtext
-%\setDefaults
+\setDefaults
\hvFloat[FULLPAGE]{figure}%
{\includegraphics[FULLPAGE]{tiger}}%
[A float which needs the complete paper width and height.]%
diff --git a/macros/latex/contrib/hvfloat/latex/hvfloat.sty b/macros/latex/contrib/hvfloat/latex/hvfloat.sty
index 622c1fba50..ff8fb42a4c 100644
--- a/macros/latex/contrib/hvfloat/latex/hvfloat.sty
+++ b/macros/latex/contrib/hvfloat/latex/hvfloat.sty
@@ -1,4 +1,4 @@
-%% $Id: hvfloat.sty 36 2020-10-31 08:22:30Z herbert $
+%% $Id: hvfloat.sty 41 2020-11-21 21:03:28Z herbert $
%%
%%
%% IMPORTANT NOTICE:
@@ -15,8 +15,8 @@
%% `hvfloat' offers rotating of captions and objects for floats
%%
\NeedsTeXFormat{LaTeX2e}
-\def\fileversion{2.17}
-\def\filedate{2020/10/31}
+\def\fileversion{2.18}
+\def\filedate{2021/03/12}
\message{`hvfloat' v\fileversion, \filedate\space (Herbert Voss)}
\ProvidesPackage{hvfloat}[\filedate\ rotating of floating objects]
\let\hvFloatFileVersion\fileversion
@@ -32,7 +32,7 @@
\RequirePackage{caption}
\PassOptionsToPackage{hypcap}{subcaption}
\RequirePackage{subcaption}
-\RequirePackage{atbegshi}
+\RequirePackage{atbegshi,picture,trimclip}
\RequirePackage{expl3,multido}
\RequirePackage{graphicx}
@@ -64,6 +64,8 @@
\newsavebox\hvOBox
\newsavebox\@tempbox
\newsavebox\hv@caption@box
+\newsavebox\hv@leftBox
+\newsavebox\hv@rightBox
\newif\ifhv@capbeside \hv@capbesidefalse
@@ -133,13 +135,15 @@
\newif\ifhv@fullpage
\newif\ifhv@FULLPAGE
-
-%\define@boolkey{hvSet}[hv@]{fullpage}[true]{}% fullpage float with caption on other page
-%\define@boolkey{hvSet}[hv@]{FullPage}[true]{}% fullpage float with caption on other page
-%\define@boolkey{hvSet}[hv@]{FULLPAGE}[true]{}% fullpage float with caption on other page
+\newif\ifhv@doubleFULLPAGE
+\newif\ifhv@doublePAGE
+\newif\ifhv@doublePage
\define@key{hvSet}{fullpage}[true]{\global\@nameuse{hv@fullpage#1}}% wegen \afterpage problem
\define@key{hvSet}{FULLPAGE}[true]{\global\@nameuse{hv@FULLPAGE#1}}
+\define@key{hvSet}{doubleFULLPAGE}[true]{\global\@nameuse{hv@doubleFULLPAGE#1}\hv@doublePagefalse\hv@doublePAGEfalse}
+\define@key{hvSet}{doublePAGE}[true]{\global\@nameuse{hv@doublePAGE#1}\hv@doublePagefalse\hv@doubleFULLPAGEfalse}
+\define@key{hvSet}{doublePage}[true]{\global\@nameuse{hv@doublePage#1}\hv@doublePAGEfalse\hv@doubleFULLPAGEfalse}
\define@boolkey{hvSet}[hv@]{subFloat}[true]{% typeset values as subfloats
\ifhv@subFloat\setkeys{hvSet}{multiFloat=false}\fi%
@@ -168,7 +172,8 @@
floatPos=htbp, rotAngle=0, capWidth=n, capAngle=0,
capPos=bottom, capVPos=center, objectPos=center, objectAngle=0,
floatCapSep=5pt, useOBox=false, nonFloat=false,
- onlyText=false, wide=false, fullpage=false, FULLPAGE=false,
+ onlyText=false, wide=false, fullpage=false, FULLPAGE=false,
+ doubleFULLPAGE=false, doublePage=false, doublePAGE=false,
multiFloat=false,subFloat=false,
separatorLine,objectFrame=false,multiFloatSkip=\normalbaselineskip,
capFormat={}, subcapFormat={},
@@ -232,8 +237,6 @@
\Gin@boolkey{false}{iso}%
}
\newcommand\IncludeGraphics[2][]{%
-% \newpage
-%\iffalse
\vspace*{\the\dimexpr-1in-\voffset+\topskip-\headheight-0.5\baselineskip}%
\leavevmode\checkoddpage
\ifoddpage
@@ -242,9 +245,6 @@
\hspace*{\dimexpr-\evensidemargin-\parindent-1in}%
\fi\noindent
\includegraphics[#1,width=\paperwidth,height=\paperheight,keepaspectratio=false]{#2}%
-%\fi
-% \includepdf[#1]%,width=\paperwidth,height=\paperheight,keepaspectratio=false]
-% {#2}%
}
\newcommand\put@CaptionBox[1][0]{%
@@ -305,12 +305,10 @@
% #6: label
%
\def\hvFloat@i*{\@ifnextchar[{\do@hvFloat}{\do@hvFloat[]}}
-
\def\do@hvFloat[#1]{%
\begingroup
\setlength\hvWideWidth{\dimexpr\linewidth+\marginparwidth}%
\hv@maxImageWidth=\textwidth
-% \hv@capbesidefalse
\reset@special@float
\setcounter{hv@pfigure}{\value{figure}}%
\setcounter{hv@ptable}{\value{table}}%
@@ -382,7 +380,6 @@
\def\hvFloat@ii[#1]#2#3{%
\hv@maxImageWidth=\textwidth
-% \hv@capbesidefalse
\ifx\relax#1\relax\else\setkeys{hvSet}{#1}\fi
\gdef\hv@floatType{#2}%
\ifx\relax#2\relax \setkeys{hvSet}{nonFloat=true}\fi
@@ -393,6 +390,7 @@
\gdef\hv@shortCap{#1}%
\gdef\hv@longCap{#2}%
\gdef\hv@label{#3}%
+ \ifhv@capbeside\def\@@temp{1}\else\def\@@temp{0}\fi
\ifhv@fullpage
\def\hvSet@CapWidth{n}% relative value
\do@@@@hvFloat% fullpage with caption on other page
@@ -401,9 +399,23 @@
\def\hvSet@CapWidth{n}% relative value
\do@@@@hvFloat% fullpage with caption on other page
\else
- \do@@@hvFloat
+ \ifhv@doubleFULLPAGE
+ \setlength\hvCapWidth{\textheight}
+ \do@hvFloat@doubleFULLPAGE% fullpage with caption rotated or under on an odd page
+ \else
+ \ifhv@doublePAGE
+ \expandafter\do@hvFloat@doublePAGE\@@temp% fullpage with caption rotated or under on an odd page
+ \else
+ \ifhv@doublePage
+ \expandafter\do@hvFloat@doublePage\@@temp% fullpage with caption rotated or under on an odd page
+ \else
+ \do@@@hvFloat
+ \fi
+ \fi
+ \fi
\fi
\fi
+% \global\hv@capbesidefalse
}
%
\def\do@@@hvFloat{% no special float page
@@ -473,7 +485,7 @@
\fi
\saveCaptionSkip % we put this space ourselve
\ifx\hvSet@capAngle\hv@Zero % need rotation?
- \sbox\hvCaptionBox{% NO rotation
+ \savebox\hvCaptionBox{% NO rotation
\begin{minipage}[b]{\hvCapWidth}% minipage, to get hyphenation
\ifx\relax\hv@caption@format\relax\else\expandafter\captionsetup\expandafter{\hv@caption@format}\fi
\ifhv@nonFloat
@@ -505,7 +517,7 @@
\end{minipage}%
}%
\else
- \sbox\hvCaptionBox{% Rotation
+ \savebox\hvCaptionBox{% Rotation
\rotatebox{\hvSet@capAngle}{%
\begin{minipage}[b]{\hvCapWidth}% minipage, to get hyphenation
\ifx\relax\hv@caption@format\relax\else\expandafter\captionsetup\expandafter{\hv@caption@format}\fi
@@ -845,8 +857,170 @@
\fi
\fi
\endgroup% startet at main \hvFloat
-}%
+}
+%
+%
+\def\do@hvFloat@doublePage#1{% image on left and right page with caption on the right ----------------------------------
+ \checkoddpage
+ \global\savebox{\hvObjectBox}{\ifhv@useOBox\usebox{\hvOBox}\else\hv@floatObject\fi}%
+ \ifoddpage
+ \afterpage{%
+ \noindent
+ \global\savebox{\hvObjectBox}{\ifhv@useOBox\usebox{\hvOBox}\else\hv@floatObject\fi}%
+ \global\@tempdima=\dimexpr\paperwidth-1in-\evensidemargin\relax
+ \clipbox*{0 -\depth{} \@tempdima{} \height}{\usebox\hvObjectBox}%
+ \par\bigskip
+ \afterpage{%
+ \newpage
+ \global\savebox{\hvObjectBox}{\ifhv@useOBox\usebox{\hvOBox}\else\hv@floatObject\fi}%
+ \hspace*{\dimexpr-1in-\oddsidemargin-\parindent}%
+ \clipbox*{\@tempdima{} -\depth{} \width{} \height{}}{\usebox\hvObjectBox}%
+ \ifnum#1>0
+ \medskip
+ \ifdim\dp\hvObjectBox > \z@
+ \rotatebox[origin=c]{90}{\parbox{\the\dimexpr\ht\hvObjectBox+\dp\hvObjectBox}{%
+ \captionof{\hv@floatType}[\hv@shortCap]{\hv@longCap\expandafter\label\expandafter{\hv@label}}}}%
+ \else
+ \rotatebox{90}{\parbox{\the\dimexpr\ht\hvObjectBox+\dp\hvObjectBox}{%
+ \captionof{\hv@floatType}[\hv@shortCap]{\hv@longCap\expandafter\label\expandafter{\hv@label}}}}%
+ \fi
+ \else
+ \captionof{\hv@floatType}[\hv@shortCap]{\hv@longCap\expandafter\label\expandafter{\hv@label}}%
+ \fi
+ }%
+ }%
+ \else
+ \afterpage{%
+ \afterpage{%
+% \newpage
+ \noindent\null
+ \global\savebox{\hvObjectBox}{\ifhv@useOBox\usebox{\hvOBox}\else\hv@floatObject\fi}%
+ \global\@tempdima=\dimexpr\paperwidth-1in-\evensidemargin\relax{}
+ \hspace*{\@tempdima}%
+ \clipbox*{0 -\depth{} \@tempdima{} \height}{\usebox\hvObjectBox}%
+ \par\bigskip
+ \afterpage{%
+ \global\savebox{\hvObjectBox}{\ifhv@useOBox\usebox{\hvOBox}\else\hv@floatObject\fi}%
+ \noindent
+ \hspace*{\dimexpr-1in-\marginparwidth}%
+ \clipbox*{\@tempdima{} -\depth{} \width{} \height{}}{\usebox\hvObjectBox}%
+ \ifnum#1>0
+ \medskip
+ \ifdim\dp\hvObjectBox > \z@
+ \rotatebox[origin=c]{90}{\parbox{\the\dimexpr\ht\hvObjectBox+\dp\hvObjectBox}{%
+ \captionof{\hv@floatType}[\hv@shortCap]{\hv@longCap\expandafter\label\expandafter{\hv@label}}}}%
+ \else
+ \rotatebox{90}{\parbox{\the\dimexpr\ht\hvObjectBox+\dp\hvObjectBox}{%
+ \captionof{\hv@floatType}[\hv@shortCap]{\hv@longCap\expandafter\label\expandafter{\hv@label}}}}%
+ \fi
+ \else
+ \captionof{\hv@floatType}[\hv@shortCap]{\hv@longCap\expandafter\label\expandafter{\hv@label}}%
+ \fi
+ }}}%
+ \fi
+ \endgroup
+}
+
+\def\do@hvFloat@doublePAGE#1{% image on left and right page with caption on the right ----------------------------------
+ \checkoddpage
+ \ifoddpage
+ \afterpage{%
+ \newpage
+ \global\savebox{\hvObjectBox}{\ifhv@useOBox\usebox{\hvOBox}\else\hv@floatObject\fi}%
+ \hspace*{\the\dimexpr-\evensidemargin-\parindent-1in}%
+ \clipbox*{0 -\depth{} \paperwidth{} \height}{\usebox\hvObjectBox}%
+ \newpage
+ \global\savebox{\hvObjectBox}{\ifhv@useOBox\usebox{\hvOBox}\else\hv@floatObject\fi}%
+ \hspace*{\the\dimexpr-\oddsidemargin-\parindent-1in}%
+ \clipbox*{\paperwidth{} -\depth{} \width{} \height{}}{\usebox\hvObjectBox}%
+ \ifnum#1>0
+ \medskip
+ \ifdim\dp\hvObjectBox > \z@
+ \rotatebox[origin=c]{90}{\parbox{\the\dimexpr\ht\hvObjectBox+\dp\hvObjectBox}{%
+ \captionof{\hv@floatType}[\hv@shortCap]{\hv@longCap\expandafter\label\expandafter{\hv@label}}}}%
+ \else
+ \rotatebox{90}{\parbox{\the\dimexpr\ht\hvObjectBox+\dp\hvObjectBox}{%
+ \captionof{\hv@floatType}[\hv@shortCap]{\hv@longCap\expandafter\label\expandafter{\hv@label}}}}%
+ \fi
+ \else
+ \captionof{\hv@floatType}[\hv@shortCap]{\hv@longCap\expandafter\label\expandafter{\hv@label}}%
+ \fi
+ \newpage
+ }%
+ \else
+ \afterpage{%
+ \AddToHookNext{shipout/before}{%
+% \newpage
+ \global\savebox{\hvObjectBox}{\ifhv@useOBox\usebox{\hvOBox}\else\hv@floatObject\fi}%
+ \hspace*{\dimexpr-\evensidemargin-1in-\parindent}%
+ \clipbox*{0 -\depth{} \paperwidth{} \height}{\usebox\hvObjectBox}%
+ \newpage
+ \global\savebox{\hvObjectBox}{\ifhv@useOBox\usebox{\hvOBox}\else\hv@floatObject\fi}%
+ \hspace*{\the\dimexpr-1in-\oddsidemargin-\parindent\relax}%
+ \clipbox*{\paperwidth{} -\depth{} \width{} \height{}}{\usebox\hvObjectBox}%
+ \ifnum#1>0
+ \medskip
+ \ifdim\dp\hvObjectBox > \z@
+ \rotatebox[origin=c]{90}{\parbox{\the\dimexpr\ht\hvObjectBox+\dp\hvObjectBox}{%
+ \captionof{\hv@floatType}[\hv@shortCap]{\hv@longCap\expandafter\label\expandafter{\hv@label}}}}%
+ \else
+ \rotatebox{90}{\parbox{\the\dimexpr\ht\hvObjectBox+\dp\hvObjectBox}{%
+ \captionof{\hv@floatType}[\hv@shortCap]{\hv@longCap\expandafter\label\expandafter{\hv@label}}}}%
+ \fi
+ \else
+ \captionof{\hv@floatType}[\hv@shortCap]{\hv@longCap\expandafter\label\expandafter{\hv@label}}%
+ \fi
+ \newpage
+ }}%
+ \fi
+ \endgroup
+}
%
+\def\do@hvFloat@doubleFULLPAGE{% image on left and right page with caption on the right ----------------------------------
+ \checkoddpage
+ \global\savebox{\hvObjectBox}{\ifhv@useOBox\usebox{\hvOBox}\else\hv@floatObject\fi}%
+ \ifoddpage
+ \afterpage{%
+ \global\savebox{\hvObjectBox}{\ifhv@useOBox\usebox{\hvOBox}\else\hv@floatObject\fi}%
+ \vspace*{\the\dimexpr-1in-\voffset-\topmargin-\headheight-\headsep+0.5\paperheight-0.5\ht\hvObjectBox-\normalbaselineskip}%
+ \hspace*{\the\dimexpr-\evensidemargin-\parindent-1in}%
+ \thispagestyle{empty}%
+ \clipbox*{0 0 \paperwidth{} \height}{\usebox\hvObjectBox}%
+ \newpage
+ \thispagestyle{empty}%
+ \vspace*{\the\dimexpr-1in-\voffset-\topmargin-\headheight-\headsep-0.5\paperheight+0.5\ht\hvObjectBox-\normalbaselineskip}%
+ \hspace*{\the\dimexpr-\oddsidemargin-\parindent-1in}%
+ \clipbox*{\paperwidth{} 0 \wd\hvObjectBox{} \paperheight{}}{\usebox\hvObjectBox}%
+ \savebox\hvCaptionBox{\parbox{0.9\ht\hvObjectBox}{%
+ \captionof*{\hv@floatType}[\hv@shortCap]{\hv@longCap\expandafter\label\expandafter{\hv@label}}}}%
+ \put(-\ht\hvCaptionBox,0.5\ht\hvObjectBox){\makebox(0,0){\rotatebox{90}{\parbox{0.9\ht\hvObjectBox}{%
+ \captionof{\hv@floatType}[\hv@shortCap]{\hv@longCap\expandafter\label\expandafter{\hv@label}}}}}}
+ \newpage
+ }%
+ \else
+ \afterpage{%
+ \AddToHookNext{shipout/before}{%
+ \global\savebox{\hvObjectBox}{\ifhv@useOBox\usebox{\hvOBox}\else\hv@floatObject\fi}%
+ \vspace*{\the\dimexpr-1in-\voffset-\topmargin-\headheight-\headsep-0.75\paperheight+0.75\ht\hvObjectBox}%
+ \hspace*{\the\dimexpr-\evensidemargin-\parindent-1in}%
+ \thispagestyle{empty}%
+ \clipbox*{0 0 \paperwidth{} \paperheight}{\usebox\hvObjectBox}%
+ \newpage
+ \thispagestyle{empty}%
+ \vspace*{\the\dimexpr-1in-\voffset-\topmargin-\headheight-\headsep-0.5\paperheight+0.5\ht\hvObjectBox-\normalbaselineskip}%
+ \hspace*{\the\dimexpr-\oddsidemargin-\parindent-1in}%
+ \clipbox*{\paperwidth{} 0 \wd\hvObjectBox{} \paperheight{}}{\usebox\hvObjectBox}%
+ \savebox\hvCaptionBox{\parbox{0.9\ht\hvObjectBox}{%
+ \captionof*{\hv@floatType}[\hv@shortCap]{\hv@longCap\expandafter\label\expandafter{\hv@label}}}}%
+ \put(-\ht\hvCaptionBox,0.5\ht\hvObjectBox){\makebox(0,0){\rotatebox{90}{\parbox{0.9\ht\hvObjectBox}{%
+ \captionof{\hv@floatType}[\hv@shortCap]{\hv@longCap\expandafter\label\expandafter{\hv@label}}}}}}
+ \newpage
+ }%
+ }%
+ \fi
+ \endgroup
+}
+
\def\setBottomCaption{%
\begin{\hv@floatType}[!b]
\ifhv@separatorLine\drawSepLine\fi
diff --git a/macros/latex/contrib/l3packages/CHANGELOG.md b/macros/latex/contrib/l3packages/CHANGELOG.md
index 05ef070996..cf52f56e8f 100644
--- a/macros/latex/contrib/l3packages/CHANGELOG.md
+++ b/macros/latex/contrib/l3packages/CHANGELOG.md
@@ -7,6 +7,11 @@ this project uses date-based 'snapshot' version identifiers.
## [Unreleased]
+## [2021-03-12]
+
+### Fixed
+- Pass options to frozen `xparse`
+
## [2021-02-02]
### Changed
@@ -119,7 +124,8 @@ this project uses date-based 'snapshot' version identifiers.
- Switch to ISO date format
- Improve cross-module use of internal functions
-[Unreleased]: https://github.com/latex3/latex3/compare/2021-02-02...HEAD
+[Unreleased]: https://github.com/latex3/latex3/compare/2021-03-12...HEAD
+[2021-03-12]: https://github.com/latex3/latex3/compare/2021-02-02...2021-03-12
[2021-02-02]: https://github.com/latex3/latex3/compare/2020-10-27...2021-02-02
[2020-10-27]: https://github.com/latex3/latex3/compare/2020-10-05...2020-10-27
[2020-10-05]: https://github.com/latex3/latex3/compare/2020-05-15...2020-10-05
diff --git a/macros/latex/contrib/l3packages/README.md b/macros/latex/contrib/l3packages/README.md
index f2629e7937..8319851b85 100644
--- a/macros/latex/contrib/l3packages/README.md
+++ b/macros/latex/contrib/l3packages/README.md
@@ -1,7 +1,7 @@
LaTeX3 High-Level Concepts
==========================
-Release 2021-02-02
+Release 2021-03-12
Overview
--------
diff --git a/macros/latex/contrib/l3packages/l3keys2e.dtx b/macros/latex/contrib/l3packages/l3keys2e.dtx
index cd3f5206a9..501e4c5aaa 100644
--- a/macros/latex/contrib/l3packages/l3keys2e.dtx
+++ b/macros/latex/contrib/l3packages/l3keys2e.dtx
@@ -62,7 +62,7 @@
% }^^A
% }
%
-% \date{Released 2021-02-02}
+% \date{Released 2021-03-12}
%
% \maketitle
%
@@ -139,7 +139,7 @@
% \end{macrocode}
%
% \begin{macrocode}
-\ProvidesExplPackage{l3keys2e}{2021-02-02}{}
+\ProvidesExplPackage{l3keys2e}{2021-03-12}{}
{LaTeX2e option processing using LaTeX3 keys}
% \end{macrocode}
%
diff --git a/macros/latex/contrib/l3packages/l3keys2e.ins b/macros/latex/contrib/l3packages/l3keys2e.ins
index f5b81f896b..3c437d8ee8 100644
--- a/macros/latex/contrib/l3packages/l3keys2e.ins
+++ b/macros/latex/contrib/l3packages/l3keys2e.ins
@@ -18,7 +18,7 @@ The released version of this bundle is available from CTAN.
\fi
-\input l3docstrip.tex
+\input docstrip %
\askforoverwritefalse
\preamble
diff --git a/macros/latex/contrib/l3packages/l3keys2e.pdf b/macros/latex/contrib/l3packages/l3keys2e.pdf
index 4acecdf5e1..e55211ccf9 100644
--- a/macros/latex/contrib/l3packages/l3keys2e.pdf
+++ b/macros/latex/contrib/l3packages/l3keys2e.pdf
Binary files differ
diff --git a/macros/latex/contrib/l3packages/xfp.dtx b/macros/latex/contrib/l3packages/xfp.dtx
index 7a86c63782..0093447c2e 100644
--- a/macros/latex/contrib/l3packages/xfp.dtx
+++ b/macros/latex/contrib/l3packages/xfp.dtx
@@ -38,7 +38,6 @@
%<package> }%
%<package> \endinput
%<package> }
-%<package>\RequirePackage{xparse}
%</driver|package>
%<*driver>
\documentclass[full]{l3doc}
@@ -64,7 +63,7 @@
% }^^A
% }
%
-% \date{Released 2021-02-02}
+% \date{Released 2021-03-12}
%
% \maketitle
%
@@ -167,7 +166,7 @@
% \end{macrocode}
%
% \begin{macrocode}
-\ProvidesExplPackage{xfp}{2021-02-02}{}
+\ProvidesExplPackage{xfp}{2021-03-12}{}
{L3 Floating point unit}
% \end{macrocode}
%
diff --git a/macros/latex/contrib/l3packages/xfp.ins b/macros/latex/contrib/l3packages/xfp.ins
index 736445226b..b5c1d4eea9 100644
--- a/macros/latex/contrib/l3packages/xfp.ins
+++ b/macros/latex/contrib/l3packages/xfp.ins
@@ -18,7 +18,7 @@ The released version of this bundle is available from CTAN.
\fi
-\input l3docstrip.tex
+\input docstrip %
\askforoverwritefalse
\preamble
diff --git a/macros/latex/contrib/l3packages/xfp.pdf b/macros/latex/contrib/l3packages/xfp.pdf
index 63d9c3bd2b..d91a5561bb 100644
--- a/macros/latex/contrib/l3packages/xfp.pdf
+++ b/macros/latex/contrib/l3packages/xfp.pdf
Binary files differ
diff --git a/macros/latex/contrib/l3packages/xfrac.dtx b/macros/latex/contrib/l3packages/xfrac.dtx
index dfdbf25f6a..dbbdeaf65a 100644
--- a/macros/latex/contrib/l3packages/xfrac.dtx
+++ b/macros/latex/contrib/l3packages/xfrac.dtx
@@ -65,7 +65,7 @@
% }^^A
% }
%
-% \date{Released 2021-02-02}
+% \date{Released 2021-03-12}
%
% \maketitle
%
@@ -535,7 +535,7 @@
% \end{macrocode}
%
% \begin{macrocode}
-\ProvidesExplPackage{xfrac}{2021-02-02}{}
+\ProvidesExplPackage{xfrac}{2021-03-12}{}
{L3 Experimental split-level fractions}
% \end{macrocode}
%
diff --git a/macros/latex/contrib/l3packages/xfrac.ins b/macros/latex/contrib/l3packages/xfrac.ins
index d08a89b6d3..20d01acd7b 100644
--- a/macros/latex/contrib/l3packages/xfrac.ins
+++ b/macros/latex/contrib/l3packages/xfrac.ins
@@ -19,7 +19,7 @@ The released version of this bundle is available from CTAN.
\fi
-\input l3docstrip.tex
+\input docstrip %
\askforoverwritefalse
\preamble
diff --git a/macros/latex/contrib/l3packages/xfrac.pdf b/macros/latex/contrib/l3packages/xfrac.pdf
index 04b7f9106f..ec7de16964 100644
--- a/macros/latex/contrib/l3packages/xfrac.pdf
+++ b/macros/latex/contrib/l3packages/xfrac.pdf
Binary files differ
diff --git a/macros/latex/contrib/l3packages/xparse.dtx b/macros/latex/contrib/l3packages/xparse.dtx
index 3ea422301a..b612ed6d23 100644
--- a/macros/latex/contrib/l3packages/xparse.dtx
+++ b/macros/latex/contrib/l3packages/xparse.dtx
@@ -67,7 +67,7 @@
% }^^A
% }
%
-% \date{Released 2021-02-02}
+% \date{Released 2021-03-12}
%
% \maketitle
%
@@ -1009,16 +1009,22 @@
\if\relax#2\relax\else#1\fi#2#3#4 }
%</2ekernel>
\ExplSyntaxOn
+\cs_set_protected:Npn \@@_tmp:w #1
+ {
+ \DeclareOption* { \PassOptionsToPackage { \CurrentOption } {#1} }
+ \ProcessOptions \relax
+ \RequirePackage {#1}
+ }
\cs_if_free:NTF \NewDocumentCommand
{
\ExplSyntaxOff
\ifnum\expandafter
\@parse@version\fmtversion//00\@nil <
\@parse@version 2020-10-01//00\@nil
- \RequirePackage{xparse-2018-04-12}
+ \@@_tmp:w { xparse-2018-04-12 }
\else
%<2ekernel> \@@@@input xparse-generic.tex ~
-%<package> \RequirePackage{xparse-2020-10-01}
+%<package> \@@_tmp:w { xparse-2020-10-01 }
\fi
\file_input_stop:
}
@@ -1036,7 +1042,7 @@
\ExplSyntaxOff
\cs_if_exist:NF \@@_start:nNNnnn
{
- \RequirePackage{xparse-2020-10-01}
+ \@@_tmp:w { xparse-2020-10-01 }
\file_input_stop:
}
}
@@ -1058,7 +1064,7 @@
% \end{macrocode}
%
% \begin{macrocode}
-\ProvidesExplPackage{xparse}{2021-02-02}{}
+\ProvidesExplPackage{xparse}{2021-03-12}{}
{L3 Experimental document command parser}
% \end{macrocode}
%
diff --git a/macros/latex/contrib/l3packages/xparse.ins b/macros/latex/contrib/l3packages/xparse.ins
index da55996744..98a6dd8a39 100644
--- a/macros/latex/contrib/l3packages/xparse.ins
+++ b/macros/latex/contrib/l3packages/xparse.ins
@@ -18,7 +18,7 @@ The released version of this bundle is available from CTAN.
\fi
-\input l3docstrip.tex
+\input docstrip %
\askforoverwritefalse
\preamble
diff --git a/macros/latex/contrib/l3packages/xparse.pdf b/macros/latex/contrib/l3packages/xparse.pdf
index bdd5f8bfb9..0722a7b93c 100644
--- a/macros/latex/contrib/l3packages/xparse.pdf
+++ b/macros/latex/contrib/l3packages/xparse.pdf
Binary files differ
diff --git a/macros/latex/contrib/l3packages/xtemplate.dtx b/macros/latex/contrib/l3packages/xtemplate.dtx
index a20b55892e..d80d348070 100644
--- a/macros/latex/contrib/l3packages/xtemplate.dtx
+++ b/macros/latex/contrib/l3packages/xtemplate.dtx
@@ -63,7 +63,7 @@
% }^^A
% }
%
-% \date{Released 2021-02-02}
+% \date{Released 2021-03-12}
%
% \maketitle
%
@@ -682,7 +682,7 @@
% \end{macrocode}
%
% \begin{macrocode}
-\ProvidesExplPackage{xtemplate}{2021-02-02}{}
+\ProvidesExplPackage{xtemplate}{2021-03-12}{}
{L3 Experimental prototype document functions}
% \end{macrocode}
%
diff --git a/macros/latex/contrib/l3packages/xtemplate.ins b/macros/latex/contrib/l3packages/xtemplate.ins
index 3e88b5e52c..2e459227f7 100644
--- a/macros/latex/contrib/l3packages/xtemplate.ins
+++ b/macros/latex/contrib/l3packages/xtemplate.ins
@@ -29,7 +29,7 @@ license information is placed in the derived files.
\fi
-\input l3docstrip.tex
+\input docstrip %
\askforoverwritefalse
\preamble
diff --git a/macros/latex/contrib/l3packages/xtemplate.pdf b/macros/latex/contrib/l3packages/xtemplate.pdf
index d0d755b853..c4b96d62d2 100644
--- a/macros/latex/contrib/l3packages/xtemplate.pdf
+++ b/macros/latex/contrib/l3packages/xtemplate.pdf
Binary files differ
diff --git a/macros/latex/contrib/mindflow/mindflow.dtx b/macros/latex/contrib/mindflow/mindflow.dtx
index 9f7e2adc98..43fadef53e 100644
--- a/macros/latex/contrib/mindflow/mindflow.dtx
+++ b/macros/latex/contrib/mindflow/mindflow.dtx
@@ -4,14 +4,11 @@
% -------------------------------
%
% This file may be distributed and/or modified under the conditions of the LaTeX
-% Project Public License, either version 1.3 of this license or (at your option)
+% Project Public License, either version 1.3c of this license or (at your option)
% any later version. The latest version of this license is in:
%
% http://www.latex-project.org/lppl.txt
%
-% and version 1.3 or later is part of all distributions of LaTeX version
-% 2005/12/01 or later.
-%
% \fi
%
% \iffalse
@@ -21,7 +18,7 @@
%<package>\NeedsTeXFormat{LaTeX2e}
%<package>\ProvidesPackage{mindflow}
%<*package>
- [2021/03/11 Mindflow environment]
+ [2021/03/12 Mindflow environment]
%</package>
%
%<*driver>
@@ -45,7 +42,7 @@
%</driver>
% \fi
%
-% \CheckSum{119}
+% \CheckSum{125}
%
% \GetFileInfo{mindflow.dtx}
%
@@ -114,6 +111,10 @@
% \verb|\mindflowLeft| and \verb|\mindflowRight|. Both have the default
% value as ``\verb|*|''.
%
+% \DescribeMacro{\mindflowLineHeight}
+% The height of the separation line is a length macro named \verb|\mindflowLineHeight|,
+% with default value \verb|0.4pt|. You can change this with \verb|\setlength|.
+%
% And finally, the color for texts and line numbers within the \verb|mindflow|
% environments are called \verb|mindflowText| and \verb|mindflowNum|,
% respectively. By default, they have the same color as the context, with
@@ -122,23 +123,25 @@
% \section{An example}
% With option \verb|linenumber, leftmarker, rightmarker| and the following settings:
% \begin{verbatim}
-% \colorlet{mindflowText}{blue!50!cyan}
-% \colorlet{mindflowNum}{blue!50!cyan}
-% \renewcommand{\mindflowTextFont}{\footnotesize\sffamily}
-% \renewcommand{\mindflowNumFont}{\footnotesize\sffamily}
+% \colorlet{mindflowText}{blue!50!cyan!80}
+% \colorlet{mindflowNum}{blue!50!cyan!80}
+% \renewcommand{\mindflowTextFont}{\normalfont\footnotesize\sffamily\itshape}
+% \renewcommand{\mindflowNumFont}{\normalfont\footnotesize\sffamily}
% \renewcommand{\mindflowLeft}{\hspace{1em}\(\succ\)}
% \renewcommand{\mindflowRight}{\(\prec\)}
+% \setlength{\mindflowLineHeight}{1pt}
% \end{verbatim}
% One gets:
% \makeatletter
% \@mindflow@leftmarkertrue
% \makeatother
-% \colorlet{mindflowText}{blue!50!cyan}
-% \colorlet{mindflowNum}{blue!50!cyan}
-% \renewcommand{\mindflowTextFont}{\footnotesize\sffamily}
-% \renewcommand{\mindflowNumFont}{\footnotesize\sffamily}
+% \colorlet{mindflowText}{blue!50!cyan!80}
+% \colorlet{mindflowNum}{blue!50!cyan!80}
+% \renewcommand{\mindflowTextFont}{\normalfont\footnotesize\sffamily\itshape}
+% \renewcommand{\mindflowNumFont}{\normalfont\footnotesize\sffamily}
% \renewcommand{\mindflowLeft}{\hspace{1em}\(\succ\)}
% \renewcommand{\mindflowRight}{\(\prec\)}
+% \setlength{\mindflowLineHeight}{1pt}
% \begin{mindflow}
% \blindtext
% \end{mindflow}
@@ -181,6 +184,8 @@
\newcommand{\mindflowNumFont}{\normalfont\scriptsize\ttfamily}
\newcommand{\mindflowLeft}{*}
\newcommand{\mindflowRight}{*}
+\newlength{\mindflowLineHeight}
+\setlength{\mindflowLineHeight}{0.4pt}
%%================================
%% The mindflow environment
@@ -193,9 +198,9 @@
\ifLineNumbers\LNturnsONtrue\fi\nolinenumbers%
\par\noindent\nopagebreak%
\if@mindflow@incolumn%
- \makebox[\linewidth]{\rule{\linewidth}{0.4pt}}%
+ \makebox[\linewidth]{\rule{\linewidth}{\mindflowLineHeight}}%
\else%
- \hspace*{-\paperwidth}\makebox[\linewidth]{\rule{4\paperwidth}{0.4pt}}%
+ \hspace*{-\paperwidth}\makebox[\linewidth]{\rule{4\paperwidth}{\mindflowLineHeight}}%
\fi%
\nopagebreak\par%
\ifLNturnsON\linenumbers\fi%
@@ -212,8 +217,8 @@
\else
\newenvironment{mindflow}
{%
- \setcounter{recordLN}{\value{linenumber}}
- \setcounter{linenumber}{\value{mfLN}}
+ \setcounter{recordLN}{\value{linenumber}}%
+ \setcounter{linenumber}{\value{mfLN}}%
\LNturnsONfalse%
\ifLineNumbers\LNturnsONtrue\fi\nolinenumbers%
\mindflowTextFont\color{mindflowText}%
@@ -236,8 +241,8 @@
\par%
\vspace{-.5\baselineskip}\mfSepLine%
\ifLNturnsON\linenumbers\fi%
- \setcounter{mfLN}{\value{linenumber}}
- \setcounter{linenumber}{\value{recordLN}}
+ \setcounter{mfLN}{\value{linenumber}}%
+ \setcounter{linenumber}{\value{recordLN}}%
}
\fi
% \end{macrocode}
diff --git a/macros/latex/contrib/mindflow/mindflow.ins b/macros/latex/contrib/mindflow/mindflow.ins
index fdc7beb6d7..ca666a6c65 100644
--- a/macros/latex/contrib/mindflow/mindflow.ins
+++ b/macros/latex/contrib/mindflow/mindflow.ins
@@ -2,14 +2,11 @@
%% Copyright (C) 2021 by Jinwen XU
%%
%% This file may be distributed and/or modified under the conditions of
-%% the LaTeX Project Public License, either version 1.3 of this license
+%% the LaTeX Project Public License, either version 1.3c of this license
%% or (at your option) any later version. The latest version of this
%% license is in:
%%
%% http://www.latex-project.org/lppl.txt
-%%
-%% and version 1.3 or later is part of all distributions of LaTeX version
-%% 2005/12/01 or later.
%%
\input docstrip.tex
@@ -23,15 +20,12 @@
Copyright (C) 2021 by Jinwen XU
This file may be distributed and/or modified under the conditions of
-the LaTeX Project Public License, either version 1.3 of this license
+the LaTeX Project Public License, either version 1.3c of this license
or (at your option) any later version. The latest version of this
license is in:
http://www.latex-project.org/lppl.txt
-and version 1.3 or later is part of all distributions of LaTeX version
-2005/12/01 or later.
-
\endpreamble
\generate{\file{mindflow.sty}{\from{mindflow.dtx}{package}}}
diff --git a/macros/latex/contrib/mindflow/mindflow.pdf b/macros/latex/contrib/mindflow/mindflow.pdf
index ba0e113416..b9448dbd48 100644
--- a/macros/latex/contrib/mindflow/mindflow.pdf
+++ b/macros/latex/contrib/mindflow/mindflow.pdf
Binary files differ
diff --git a/macros/latex/contrib/srdp-mathematik/README.txt b/macros/latex/contrib/srdp-mathematik/README.txt
index d8a0223c99..f1435cb61f 100644
--- a/macros/latex/contrib/srdp-mathematik/README.txt
+++ b/macros/latex/contrib/srdp-mathematik/README.txt
@@ -2,9 +2,9 @@ __________________________________
The
srdp-mathematik package
- v1.6
+ v1.7
- 2020/04/03
+ 2021/03/12
___________________________________
Maintainer: Christoph Weberndorfer
diff --git a/macros/latex/contrib/srdp-mathematik/srdp-mathematik.pdf b/macros/latex/contrib/srdp-mathematik/srdp-mathematik.pdf
index f42b398cc0..f4c3f26c31 100644
--- a/macros/latex/contrib/srdp-mathematik/srdp-mathematik.pdf
+++ b/macros/latex/contrib/srdp-mathematik/srdp-mathematik.pdf
Binary files differ
diff --git a/macros/latex/contrib/srdp-mathematik/srdp-mathematik.sty b/macros/latex/contrib/srdp-mathematik/srdp-mathematik.sty
index 8e03953a0a..aa63751436 100644
--- a/macros/latex/contrib/srdp-mathematik/srdp-mathematik.sty
+++ b/macros/latex/contrib/srdp-mathematik/srdp-mathematik.sty
@@ -10,7 +10,7 @@
%
\NeedsTeXFormat{LaTeX2e}[1996/12/26]
-\ProvidesPackage{srdp-mathematik}[2020/04/03 v1.6 Standard-Schularbeitsformate]
+\ProvidesPackage{srdp-mathematik}[2021/03/12 v1.7 Standard-Schularbeitsformate]
\usepackage{color}
@@ -53,7 +53,6 @@
\renewcommand{\vec}[1]{\vv{#1}}
\usepackage{graphicx}
\usepackage{setspace}
-%\usepackage{enumerate}
\usepackage[inline, shortlabels]{enumitem}
\usepackage{xparse}
\usepackage{eurosym, xspace}
@@ -124,11 +123,6 @@
}{#1}}
-%\NewEnviron{antwort}[1][hallo]{\textcolor{red}{\BODY}}
-%\NewEnviron{antwort}[2][]{\ifthenelse{\theAntworten=1}{\color[rgb]{1,0,0}#1\color[rgb]{0,0,0}}{#2}}
-%\newenvironment{antwort}[2][]{\color[rgb]{1,0,0}{#1}}{\color[rgb]{0,0,0}}
-
-
\newcounter{A1}
\newcounter{A2}
@@ -297,7 +291,6 @@
%
%%%%%%%%%%%%%%%%%%%% INTEGRAL BEFEHL
-%\newcommand{\dx}{\,\text{d}x}
\newcommand{\dx}[1][x]{\,\text{d}#1}
\newcommand{\dint}{\displaystyle\int}
@@ -317,15 +310,15 @@
%%%%%%%%%%%% NOTENSCHLUESSEL %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
%
-\newcommand{\notenschluessel}[4]{
+\newcommand{\notenschluessel}[5][]{
\vfill
\STautoround{3}\renewcommand{\arraystretch}{0}\tiny
\begin{spreadtab}[\STsavecell\gutgenau{b2} \STsavecell\befriedigendgenau{c2} \STsavecell\genuegendgenau{d2} \STsavecell\nichtgenuegendgenau{e2}
\STsavecell\gut{b3} \STsavecell\befriedigend{c3} \STsavecell\genuegend{d3} \STsavecell\nichtgenuegend{e3}
\STsavecell\gutpluseins{b4} \STsavecell\befriedigendpluseins{c4} \STsavecell\genuegendpluseins{d4} \STsavecell\nichtgenuegendpluseins{e4} \STsavecell\gutminuseins{b5} \STsavecell\befriedigendminuseins{c5} \STsavecell\genuegendminuseins{d5} \STsavecell\nichtgenuegendminuseins{e5}]{{tabular}{ccccc}}
\SThidecol\thepunkte &\SThidecol 1 &\SThidecol2 &\SThidecol 3 &\SThidecol 4 \\
- & a1*#1 &a1*#2 & a1*#3 & a1*#4 \\
- &trunc(a1*#1,0) & trunc(a1*#2,0) &trunc(a1*#3,0) &trunc(a1*#4,0) \\
+ & a1*#2 &a1*#3 & a1*#4 & a1*#5 \\
+ &trunc(a1*#2,0) & trunc(a1*#3,0) &trunc(a1*#4,0) &trunc(a1*#5,0) \\
&b3+1 &c3+1 &d3+1 & e3+1\\
&b3-1 &c3-1 &d3-1 & e3-1\\
\end{spreadtab}
@@ -336,21 +329,21 @@ Erreichte Punkte & Prozent & Gesamt & \multicolumn{2}{c|}{Note} \\
&& \multirow{2}{*}{\thepunkte} && \\
&&&& \\ \hline \hline
\scriptsize{Sehr gut} & \scriptsize{Gut} & \scriptsize{Befriedigend} & \scriptsize{Gen\"ugend} & \scriptsize{Nicht gen\"ugend} \\
-\scriptsize{\thepunkte ~ - \ifdim\gut pt=\gutgenau pt \gut\else\gutpluseins\fi}& \scriptsize{\ifdim\gut pt=\gutgenau pt \gutminuseins\else\gut\fi ~ - \ifdim\befriedigend pt=\befriedigendgenau pt \befriedigend\else\befriedigendpluseins\fi} & \scriptsize{\ifdim\befriedigend pt=\befriedigendgenau pt \befriedigendminuseins\else\befriedigend\fi ~ - \ifdim\genuegend pt=\genuegendgenau pt \genuegend\else\genuegendpluseins\fi} & \scriptsize{\ifdim\genuegend pt=\genuegendgenau pt \genuegendminuseins\else\genuegend\fi ~ - \ifdim\nichtgenuegend pt=\nichtgenuegendgenau pt \nichtgenuegend\else\nichtgenuegendpluseins\fi} & \scriptsize{unter \ifdim\nichtgenuegend pt=\nichtgenuegendgenau pt \nichtgenuegend\else\nichtgenuegendpluseins\fi} \\ \hline
+\scriptsize{\thepunkte ~ - \ifdim\gut pt=\gutgenau pt \gut\else\gutpluseins\fi}& \scriptsize{\ifdim\gut pt=\gutgenau pt \gutminuseins\else\gut\fi \ifthenelse{\equal{#1}{1/2}}{,5}{} ~ - \ifdim\befriedigend pt=\befriedigendgenau pt \befriedigend\else\befriedigendpluseins\fi} & \scriptsize{\ifdim\befriedigend pt=\befriedigendgenau pt \befriedigendminuseins\else\befriedigend\fi \ifthenelse{\equal{#1}{1/2}}{,5}{} ~ - \ifdim\genuegend pt=\genuegendgenau pt \genuegend\else\genuegendpluseins\fi} & \scriptsize{\ifdim\genuegend pt=\genuegendgenau pt \genuegendminuseins\else\genuegend\fi \ifthenelse{\equal{#1}{1/2}}{,5}{} ~ - \ifdim\nichtgenuegend pt=\nichtgenuegendgenau pt \nichtgenuegend\else\nichtgenuegendpluseins\fi} & \scriptsize{unter \ifdim\nichtgenuegend pt=\nichtgenuegendgenau pt \nichtgenuegend\else\nichtgenuegendpluseins\fi} \\ \hline
\end{tabular}
\end{center}\STautoround{}\normalsize}
-\newcommand{\notenschluesselop}[4]{
+\newcommand{\notenschluesselop}[5][]{
\vfill
\STautoround{3}\renewcommand{\arraystretch}{0}\tiny
\begin{spreadtab}[\STsavecell\gutgenau{b2} \STsavecell\befriedigendgenau{c2} \STsavecell\genuegendgenau{d2}
\STsavecell\gut{b3} \STsavecell\befriedigend{c3} \STsavecell\genuegend{d3} \STsavecell\nichtgenuegend{e3}
\STsavecell\gutpluseins{b4} \STsavecell\befriedigendpluseins{c4} \STsavecell\genuegendpluseins{d4} \STsavecell\gutminuseins{b5} \STsavecell\befriedigendminuseins{c5} \STsavecell\genuegendminuseins{d5}]{{tabular}{ccccc}}
\SThidecol \thepunkte &\SThidecol 1 &\SThidecol 2 &\SThidecol 3 &\SThidecol 4 \\
- & a1*#1 &a1*#2 & a1*#3 & a1*#4 \\
- &trunc(a1*#1,0) & trunc(a1*#2,0) &trunc(a1*#3,0) &trunc(a1*#4,0) \\
- &b3+1 &c3+1 &d3+1 &\\
- &b3-1 &c3-1 &d3-1 &\\
+ & a1*#2 &a1*#3 & a1*#4 & a1*#5 \\
+ &trunc(a1*#2,0) & trunc(a1*#3,0) &trunc(a1*#4,0) &trunc(a1*#5,0) \\
+ &b3+1 &c3+1 &d3+1 & e3+1\\
+ &b3-1 &c3-1 &d3-1 & e3-1\\
\end{spreadtab}
\footnotesize\renewcommand{\arraystretch}{1}
\begin{center}
@@ -359,7 +352,7 @@ Erreichte Punkte &Gesamt&\multicolumn{2}{c}{Note}& \\
&\multirow{2}{*}{\thepunkte} &&& \\
&&&& \\ \hline \hline
\scriptsize{Sehr gut} & \scriptsize{Gut} & \scriptsize{Befriedigend} & \scriptsize{Gen\"ugend} & \scriptsize{Nicht gen\"ugend} \\
-\scriptsize{\thepunkte ~ - \ifdim\gut pt=\gutgenau pt \gut\else\gutpluseins\fi}& \scriptsize{\ifdim\gut pt=\gutgenau pt \gutminuseins\else\gut\fi ~ - \ifdim\befriedigend pt=\befriedigendgenau pt \befriedigend\else\befriedigendpluseins\fi} & \scriptsize{\ifdim\befriedigend pt=\befriedigendgenau pt \befriedigendminuseins\else\befriedigend\fi ~ - \ifdim\genuegend pt=\genuegendgenau pt \genuegend\else\genuegendpluseins\fi} & \scriptsize{\ifdim\genuegend pt=\genuegendgenau pt \genuegendminuseins\else\genuegend\fi ~ - \nichtgenuegend} & \scriptsize{unter \nichtgenuegend} \\ \hline
+\scriptsize{\thepunkte ~ - \ifdim\gut pt=\gutgenau pt \gut\else\gutpluseins\fi}& \scriptsize{\ifdim\gut pt=\gutgenau pt \gutminuseins\else\gut\fi \ifthenelse{\equal{#1}{1/2}}{,5}{} ~ - \ifdim\befriedigend pt=\befriedigendgenau pt \befriedigend\else\befriedigendpluseins\fi} & \scriptsize{\ifdim\befriedigend pt=\befriedigendgenau pt \befriedigendminuseins\else\befriedigend\fi \ifthenelse{\equal{#1}{1/2}}{,5}{} ~ - \ifdim\genuegend pt=\genuegendgenau pt \genuegend\else\genuegendpluseins\fi} & \scriptsize{\ifdim\genuegend pt=\genuegendgenau pt \genuegendminuseins\else\genuegend\fi \ifthenelse{\equal{#1}{1/2}}{,5}{} ~ - \ifdim\nichtgenuegend pt=\nichtgenuegendgenau pt \nichtgenuegend\else\nichtgenuegendpluseins\fi} & \scriptsize{unter \ifdim\nichtgenuegend pt=\nichtgenuegendgenau pt \nichtgenuegend\else\nichtgenuegendpluseins\fi} \\ \hline
\end{tabular}
\end{center}\STautoround{}\normalsize}
@@ -721,20 +714,21 @@ Complete the following sentence by putting a cross next to one of the given poss
\newcommand\multiplechoice[2][5]{ %Anzahl der Antwortmoeglichkeiten, Standard: 5
\bgroup
\jeroen@set@keys{#2}%%
-
+
\centering
\tabulinesep=3mm
\pgfmathsetseed{\theZufall}
\declarenumlist{group}{1}{#1}
\pgfmathrandomitem\z{group}\setcounter{antworta}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antwortb}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antwortc}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antwortd}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antworte}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antwortf}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antwortg}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antworth}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antworti}{\z}\prunelist{group}
+\ifthenelse{\numexpr#1 > 1}{\pgfmathrandomitem\z{group}\setcounter{antwortb}{\z}\prunelist{group}}{}
+\ifthenelse{\numexpr#1 > 2}{\pgfmathrandomitem\z{group}\setcounter{antwortc}{\z}\prunelist{group}}{}
+\ifthenelse{\numexpr#1 > 3}{\pgfmathrandomitem\z{group}\setcounter{antwortd}{\z}\prunelist{group}}{}
+\ifthenelse{\numexpr#1 > 4}{\pgfmathrandomitem\z{group}\setcounter{antworte}{\z}\prunelist{group}}{}
+\ifthenelse{\numexpr#1 > 5}{\pgfmathrandomitem\z{group}\setcounter{antwortf}{\z}\prunelist{group}}{}
+\ifthenelse{\numexpr#1 > 6}{\pgfmathrandomitem\z{group}\setcounter{antwortg}{\z}\prunelist{group}}{}
+\ifthenelse{\numexpr#1 > 7}{\pgfmathrandomitem\z{group}\setcounter{antworth}{\z}\prunelist{group}}{}
+\ifthenelse{\numexpr#1 > 8}{\pgfmathrandomitem\z{group}\setcounter{antworti}{\z}\prunelist{group}}{}
+
\begin{tabu}{|T|c|}
\hline
@@ -772,15 +766,14 @@ Complete the following sentence by putting a cross next to one of the given poss
\jeroen@set@keys{#2}%%
\pgfmathsetseed{\theZufall}
\declarenumlist{group}{1}{#1}
-\pgfmathrandomitem\z{group}\setcounter{antworta}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antwortb}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antwortc}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antwortd}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antworte}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antwortf}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antwortg}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antworth}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antworti}{\z}\prunelist{group}
+\ifthenelse{\numexpr#1 > 1}{\pgfmathrandomitem\z{group}\setcounter{antwortb}{\z}\prunelist{group}}{}
+\ifthenelse{\numexpr#1 > 2}{\pgfmathrandomitem\z{group}\setcounter{antwortc}{\z}\prunelist{group}}{}
+\ifthenelse{\numexpr#1 > 3}{\pgfmathrandomitem\z{group}\setcounter{antwortd}{\z}\prunelist{group}}{}
+\ifthenelse{\numexpr#1 > 4}{\pgfmathrandomitem\z{group}\setcounter{antworte}{\z}\prunelist{group}}{}
+\ifthenelse{\numexpr#1 > 5}{\pgfmathrandomitem\z{group}\setcounter{antwortf}{\z}\prunelist{group}}{}
+\ifthenelse{\numexpr#1 > 6}{\pgfmathrandomitem\z{group}\setcounter{antwortg}{\z}\prunelist{group}}{}
+\ifthenelse{\numexpr#1 > 7}{\pgfmathrandomitem\z{group}\setcounter{antworth}{\z}\prunelist{group}}{}
+\ifthenelse{\numexpr#1 > 8}{\pgfmathrandomitem\z{group}\setcounter{antworti}{\z}\prunelist{group}}{}
\centering
\tabulinesep=3mm
@@ -838,20 +831,19 @@ Complete the following sentence by putting a cross next to one of the given poss
\newcommand\rfmultiplechoice[3][5]{ %Anzahl der Antwortmoeglichkeiten, Standard: 5
\bgroup
\jeroen@set@keys{#3}%%
-\setcounter{counter}{0}
+\setcounter{counter}{0}\setcounter{acheck}{0}\setcounter{bcheck}{0}\setcounter{ccheck}{0}\setcounter{dcheck}{0}\setcounter{echeck}{0}\setcounter{fcheck}{0}\setcounter{gcheck}{0}\setcounter{hcheck}{0}\setcounter{icheck}{0}
\centering
\tabulinesep=3mm
\pgfmathsetseed{\theZufall}
\declarenumlist{group}{1}{#1}
-\pgfmathrandomitem\z{group}\setcounter{antworta}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antwortb}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antwortc}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antwortd}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antworte}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antwortf}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antwortg}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antworth}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antworti}{\z}\prunelist{group}
+\ifthenelse{\numexpr#1 > 1}{\pgfmathrandomitem\z{group}\setcounter{antwortb}{\z}\prunelist{group}}{}
+\ifthenelse{\numexpr#1 > 2}{\pgfmathrandomitem\z{group}\setcounter{antwortc}{\z}\prunelist{group}}{}
+\ifthenelse{\numexpr#1 > 3}{\pgfmathrandomitem\z{group}\setcounter{antwortd}{\z}\prunelist{group}}{}
+\ifthenelse{\numexpr#1 > 4}{\pgfmathrandomitem\z{group}\setcounter{antworte}{\z}\prunelist{group}}{}
+\ifthenelse{\numexpr#1 > 5}{\pgfmathrandomitem\z{group}\setcounter{antwortf}{\z}\prunelist{group}}{}
+\ifthenelse{\numexpr#1 > 6}{\pgfmathrandomitem\z{group}\setcounter{antwortg}{\z}\prunelist{group}}{}
+\ifthenelse{\numexpr#1 > 7}{\pgfmathrandomitem\z{group}\setcounter{antworth}{\z}\prunelist{group}}{}
+\ifthenelse{\numexpr#1 > 8}{\pgfmathrandomitem\z{group}\setcounter{antworti}{\z}\prunelist{group}}{}
%\begin{minipage}{0.85\linewidth}
\begin{tabu}{|A|c|c|}%
@@ -919,15 +911,14 @@ Complete the following sentence by putting a cross next to one of the given poss
\tabulinesep=3mm
\pgfmathsetseed{\theZufall}
\declarenumlist{group}{1}{#1}
-\pgfmathrandomitem\z{group}\setcounter{antworta}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antwortb}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antwortc}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antwortd}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antworte}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antwortf}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antwortg}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antworth}{\z}\prunelist{group}
-\pgfmathrandomitem\z{group}\setcounter{antworti}{\z}\prunelist{group}
+\ifthenelse{\numexpr#1 > 1}{\pgfmathrandomitem\z{group}\setcounter{antwortb}{\z}\prunelist{group}}{}
+\ifthenelse{\numexpr#1 > 2}{\pgfmathrandomitem\z{group}\setcounter{antwortc}{\z}\prunelist{group}}{}
+\ifthenelse{\numexpr#1 > 3}{\pgfmathrandomitem\z{group}\setcounter{antwortd}{\z}\prunelist{group}}{}
+\ifthenelse{\numexpr#1 > 4}{\pgfmathrandomitem\z{group}\setcounter{antworte}{\z}\prunelist{group}}{}
+\ifthenelse{\numexpr#1 > 5}{\pgfmathrandomitem\z{group}\setcounter{antwortf}{\z}\prunelist{group}}{}
+\ifthenelse{\numexpr#1 > 6}{\pgfmathrandomitem\z{group}\setcounter{antwortg}{\z}\prunelist{group}}{}
+\ifthenelse{\numexpr#1 > 7}{\pgfmathrandomitem\z{group}\setcounter{antworth}{\z}\prunelist{group}}{}
+\ifthenelse{\numexpr#1 > 8}{\pgfmathrandomitem\z{group}\setcounter{antworti}{\z}\prunelist{group}}{}
%\begin{minipage}{0.85\linewidth}
\begin{tabu}{|A|c|c|}%
diff --git a/macros/latex/contrib/srdp-mathematik/srdp-mathematik.tex b/macros/latex/contrib/srdp-mathematik/srdp-mathematik.tex
index 1e51f36218..370fa9b3f9 100644
--- a/macros/latex/contrib/srdp-mathematik/srdp-mathematik.tex
+++ b/macros/latex/contrib/srdp-mathematik/srdp-mathematik.tex
@@ -1,7 +1,7 @@
\documentclass[a4paper,12pt]{article}
\usepackage{geometry}
-\geometry{a4paper,left=18mm,right=18mm, top=3cm, bottom=2cm}
+\geometry{a4paper,left=18mm,right=18mm, top=2.5cm, bottom=2cm}
\usepackage{lmodern}
@@ -51,9 +51,11 @@ hidelinks
\begin{titlepage}
\thispagestyle{empty}
\begin{center}
+~
+
\vfill
-\Huge The \textit{srdp-mathematik} package v1.6\\[1cm]
+\Huge The \textit{srdp-mathematik} package v1.7\\[1cm]
Documentation \\ [1cm]
@@ -175,6 +177,28 @@ Werden für alle Beispiele die \texttt{beispiel}- oder die \texttt{langesbeispie
\normalsize
+\paragraph{Notenschlüssel - Ohne Prozentangabe}
+Analog zum \texttt{notenschluessel} funktioniert auch der Befehl \texttt{notenschluesselop}. Es wird dabei jedoch die Prozentspalte nicht angezeigt.
+
+\textsc{Eingabe:}
+\begin{verbatim}
+\notenschluesselop{0.91}{0.8}{0.64}{0.5}
+\end{verbatim}
+
+\textsc{Ausgabe:}
+\notenschluessel{0.91}{0.8}{0.64}{0.5}
+
+\paragraph{Notenschlüssel - Option: [1/2]}
+
+Die Option 1/2 ermöglicht die Anzeige des Notenschlüssel (mit oder ohne Prozentspalte) mit halben Punkten.
+
+\textsc{Eingabe:}
+\begin{verbatim}
+\notenschluessel[1/2]{0.91}{0.8}{0.64}{0.5}
+\end{verbatim}
+
+\textsc{Ausgabe:}
+\notenschluessel[1/2]{0.91}{0.8}{0.64}{0.5}
\subsubsection{Beurteilungsraster}
diff --git a/macros/latex/contrib/suppose/README.md b/macros/latex/contrib/suppose/README.md
index f06bb0621e..072fb2231d 100644
--- a/macros/latex/contrib/suppose/README.md
+++ b/macros/latex/contrib/suppose/README.md
@@ -1,16 +1,16 @@
-# ``suppose``, v1
+# ``suppose``
## Andrew Lounsbury
-### 3/9/2021
+### Licensed with lppl 1.3c
+### 1.0 — 2021/03/11
-This package is licensed with LPPL 1.3c, and provides the following commands. \
-I recommend only using these commands when the immediately succeeding strings are mathematical in nature. I do not recommend using these in formal work.
-| Command | Font | Bold | Slanted | Slanted Line \& Bold |
-|- |- |- |- |- |
-| `\supp` | normal |`\bsup` | `\ssup` | `\sbsup` |
-| `\csup` | mathcal |`\bcsup` | `\scsup` | `\sbcsup` |
-| `\dsup` | dutchcal |`\bdsup` | `\sdsup` | `\sbdsup` |
-| `\esup` | eulerscript |`\besup` | `\sesup` | `\sbesup` |
-| `\tsup` | typewriter |`\btsup` | `\stsup` | `\sbtsup` |
-| `\vsup` | sans serif (v for variation)|`\bvsup` | `\svsup` | `\bsvsup` |
+This package provides the following commands. I recommend only using these commands when the immediately succeeding strings are mathematical in nature. I do not recommend using these in formal work.
+| Font | Command | Bold | Slanted | Slanted Line \& Bold |
+|- |- |- |- |- |
+| normal | `\supp` |`\bsup` | `\ssup` | `\sbsup` |
+| mathcal | `\csup` |`\bcsup` | `\scsup` | `\sbcsup` |
+| dutchcal | `\dsup` |`\bdsup` | `\sdsup` | `\sbdsup` |
+| eulerscript | `\esup` |`\besup` | `\sesup` | `\sbesup` |
+| typewriter | `\tsup` |`\btsup` | `\stsup` | `\sbtsup` |
+| sans serif (`v` for variation)| `\vsup` |`\bvsup` | `\svsup` | `\bsvsup` |
See `suppose.pdf` for demonstration. \ No newline at end of file
diff --git a/macros/latex/contrib/suppose/suppose.pdf b/macros/latex/contrib/suppose/suppose.pdf
index cdab45d278..e70f03b8af 100644
--- a/macros/latex/contrib/suppose/suppose.pdf
+++ b/macros/latex/contrib/suppose/suppose.pdf
Binary files differ
diff --git a/macros/latex/contrib/suppose/suppose.sty b/macros/latex/contrib/suppose/suppose.sty
index a9e4903e16..81a0ba4f6e 100644
--- a/macros/latex/contrib/suppose/suppose.sty
+++ b/macros/latex/contrib/suppose/suppose.sty
@@ -1,6 +1,6 @@
-% TITLE: suppose.sty version 1 2021/03/09
+% TITLE: suppose.sty 1.0 2021/03/11
% AUTHOR: Andrew Lounsbury
-% DESCRIPTION: This file contains symbols that abbreviate the word ``Suppose''.
+% DESCRIPTION: This file contains commands that abbreviate the word ``Suppose''.
% Commands:
%------------------------------------------------------------------------------
@@ -44,7 +44,7 @@
%************************************************************************
\NeedsTeXFormat{LaTeX2e}
-\ProvidesPackage{suppose}[2021/03/07 supposition symbols]
+\ProvidesPackage{suppose}[2021/03/11 supposition symbols]
\RequirePackage{amsmath, euscript, graphicx}
diff --git a/macros/latex/contrib/suppose/suppose.tex b/macros/latex/contrib/suppose/suppose.tex
index 97f5230fd3..bae6524007 100644
--- a/macros/latex/contrib/suppose/suppose.tex
+++ b/macros/latex/contrib/suppose/suppose.tex
@@ -1,40 +1,41 @@
\documentclass[12pt]{article}
-\usepackage{suppose}
+\usepackage{hyperref, suppose}
\begin{document}
-\title{\texttt{suppose}, \texttt{v1}}
-\author{Andrew Lounsbury}
-\date{\today}
+\title{\texttt{suppose}}
+\author{1.0 --- 2021/03/11}
+\date{Andrew Lounsbury, \href{mailto:alounsbury8@gmail.com}{alounsbury8@gmail.com}}
\maketitle
+
This package is licensed with LPPL 1.3c, and provides the following commands. I recommend only using these commands when the immediately succeeding strings are mathematical in nature. I do not recommend using these in formal work.
\begin{center}
\begin{tabular}{|c|c|c|c|c|}
\hline
- \textbf{Command} & \textbf{Font} & \textbf{Bold} & \textbf{Slanted Line} & \textbf{Slanted Line \& Bold} \\ \hline\hline
- \texttt{\textbackslash supp} & normal & \texttt{\textbackslash bsup} & \texttt{\textbackslash ssup} & \texttt{\textbackslash sbsup} \\ \hline
- \texttt{\textbackslash csup} & mathcal & \texttt{\textbackslash bcsup} & \texttt{\textbackslash scsup} & \texttt{\textbackslash sbcsup} \\ \hline
- \texttt{\textbackslash dsup} & dutchcal & \texttt{\textbackslash bdsup} & \texttt{\textbackslash sdsup} & \texttt{\textbackslash sbdsup} \\ \hline
- \texttt{\textbackslash esup} & eulerscript & \texttt{\textbackslash besup} & \texttt{\textbackslash sesup} & \texttt{\textbackslash sbesup} \\ \hline
- \texttt{\textbackslash tsup} & typewriter & \texttt{\textbackslash btsup} & \texttt{\textbackslash stsup} & \texttt{\textbackslash sbtsup} \\ \hline
- \texttt{\textbackslash vsup} & sans serif & \texttt{\textbackslash bvsup} & \texttt{\textbackslash svsup} & \texttt{\textbackslash sbvsup} \\
- & (v for variation) & & & \\ \hline
- \end{tabular}
-\end{center}
-\begin{center}
- \begin{tabular}{r|c|c|l}
- & Regular & \textbf{Bold} & Font \\ \hline
- & \supp \supp & \bsup \bsup & NORMAL \\
- & \csup \csup & \bcsup \bcsup & $\mathcal{MATHCAL}$ \\
- Upright & \dsup \dsup & \bdsup \bdsup & $\mathdutchcal{DUTCHCAL}$ \\
- & \esup \esup & \besup \besup & $\EuScript{EULERSCRIPT}$ \\
- & \vsup \vsup & \bvsup \bvsup & $\mathsf{SANS\ SERIF}$ \\
- & \tsup \tsup & \btsup \btsup & $\mathtt{TYPEWRITER}$ \\ \hline
- & \ssup \ssup & \sbsup \sbsup & NORMAL \\
- & \scsup \scsup & \sbcsup \sbcsup & $\mathcal{MATHCAL}$ \\
- \textsl{Slanted} & \sdsup \sdsup & \sbdsup \sbdsup & $\mathdutchcal{DUTCHCAL}$ \\
- & \sesup \sesup & \sbesup \sbesup & $\EuScript{EULERSCRIPT}$ \\
- & \svsup \svsup & \sbvsup \sbvsup & $\mathsf{SANS\ SERIF}$ \\
- & \stsup \stsup & \sbtsup \sbtsup & $\mathtt{TYPERWRITER}$
+ \textbf{Font} & \textbf{Command} & \textbf{Bold} & \textbf{Slanted Line} & \textbf{Slanted Line \& Bold} \\ \hline\hline
+ normal & \texttt{\textbackslash supp} & \texttt{\textbackslash bsup} & \texttt{\textbackslash ssup} & \texttt{\textbackslash sbsup} \\ \hline
+ mathcal & \texttt{\textbackslash csup} & \texttt{\textbackslash bcsup} & \texttt{\textbackslash scsup} & \texttt{\textbackslash sbcsup} \\ \hline
+ dutchcal & \texttt{\textbackslash dsup} & \texttt{\textbackslash bdsup} & \texttt{\textbackslash sdsup} & \texttt{\textbackslash sbdsup} \\ \hline
+ eulerscript & \texttt{\textbackslash esup} & \texttt{\textbackslash besup} & \texttt{\textbackslash sesup} & \texttt{\textbackslash sbesup} \\ \hline
+ typewriter & \texttt{\textbackslash tsup} & \texttt{\textbackslash btsup} & \texttt{\textbackslash stsup} & \texttt{\textbackslash sbtsup} \\ \hline
+ sans serif & \texttt{\textbackslash vsup} & \texttt{\textbackslash bvsup} & \texttt{\textbackslash svsup} & \texttt{\textbackslash sbvsup} \\
+ (\texttt{v} for variation) & & & & \\ \hline
\end{tabular}
\end{center}
+\[
+ \begin{array}{c|c|c|l}
+ & \text{Regular} & \textbf{Bold} & \text{Font} \\ \hline
+ & \supp x < y & \bsup x < y & NORMAL \\
+ & \csup x < y & \bcsup x < y & \mathcal{MATHCAL} \\
+ \text{Straight} & \dsup x < y & \bdsup x < y & \mathdutchcal{DUTCHCAL} \\
+ \text{Line} & \esup x < y & \besup x < y & \EuScript{EULERSCRIPT} \\
+ & \vsup x < y & \bvsup x < y & \mathsf{SANS\ SERIF} \\
+ & \tsup x < y & \btsup x < y & \mathtt{TYPEWRITER} \\ \hline
+ & \ssup x < y & \sbsup x < y & NORMAL \\
+ & \scsup x < y & \sbcsup x < y & \mathcal{MATHCAL} \\
+ \textsl{Slanted} & \sdsup x < y & \sbdsup x < y & \mathdutchcal{DUTCHCAL} \\
+ \textsl{Line} & \sesup x < y & \sbesup x < y & \EuScript{EULERSCRIPT} \\
+ & \svsup x < y & \sbvsup x < y & \mathsf{SANS\ SERIF} \\
+ & \stsup x < y & \sbtsup x < y & \mathtt{TYPERWRITER}
+ \end{array}
+\]
\end{document} \ No newline at end of file
diff --git a/macros/latex/contrib/thuthesis/CHANGELOG.md b/macros/latex/contrib/thuthesis/CHANGELOG.md
index 05e7be0d81..c4c4be0399 100644
--- a/macros/latex/contrib/thuthesis/CHANGELOG.md
+++ b/macros/latex/contrib/thuthesis/CHANGELOG.md
@@ -6,6 +6,27 @@
## [Unreleased]
+## [v7.2.0] - 2021-03-12
+### Added
+- 新增英文版写作指南要求的格式。
+- 新增选题报告的格式(#579)。
+- 新增 `figure-number-sepatator` 等选项设置图表编号的连接符。
+- 新增数学符号字体风格选项 `math-style`。
+- 新增选项控制数学字体风格的细节:`uppercase-greek`、`less-than-or-equal`、`integral`、`integral-limits`、`partial` 和 `math-ellipsis`。
+- 新增数学字体试验性选项 `math-font = newtx`。
+
+### Changed
+- 研究生的声明页默认加上页眉和页码,不受 `page-style` 的控制(#574)。
+- 取消图表标题的悬挂缩进(#589)。
+- 英文封面的联合导师改为“Co-supervisor”。
+- 联合导师的 key 改为 `co-supervisor`,同英文版模板一致。
+
+### Fixed
+- 修正 `longtable` 宏包的配置(#584)。
+- 修正本科生的“目录”、“声明”和“致谢”等标题中的空白(#591)。
+- 修正参考文献的格式,取消页码与前面冒号之间的空格。
+- 修正中文封面的字距。
+
## [v7.1.0] - 2020-10-14
### Changed
- 更新摘要的标题格式(研究生 2020-09-18 版)。
@@ -118,7 +139,7 @@
## [v6.0.2] - 2020-02-23
### Fixed
-- 修复图表公式目录内容缺失 (#467)。
+- 修复图表公式目录内容缺失(#467)。
- 修复 Github Actions 执行 l3build check 问题。
- 文本模式使用 `\checkmark`。
@@ -135,8 +156,8 @@
- 更新 bib 测试用例。
### Fixed
-- 修复 PDF 目录层级问题 (#457)。
-- 修复 PDF 中章节连接问题 (#453)。
+- 修复 PDF 目录层级问题(#457)。
+- 修复 PDF 中章节连接问题(#453)。
## [v6.0.0] - 2020-01-06
### Added
@@ -271,17 +292,17 @@
- 不再将页面尺寸写入 dvi,因为已不支持 dvips, 而该方案会使得在使用 tikzexternalize 时外部 PDF 图片 BBox 不对。
- 用 `geometry` 简化设置。
- `\ps@thu@headings`: 利用 `fancyhdr` 设置页眉页脚。
-- 修正定理字样为黑体 (#104)。
+- 修正定理字样为黑体(#104)。
- 本科附录图表编号用-不用.(如图A-1,表A-2)。
- 用 `\ctexset` 来设置,替换复杂的 `\@startsection`。
-- 修正章节间距问题(#57)
+- 修正章节间距问题(#57)。
- 硕士博士论文目录只出现到第 3 级标题即可。其他未明确要求。
-- `\tableofcontents`: 修正学位论文中目录里节前缩进(#103)
-- `\makecover`: 使用 `pdfpages` 宏包支持本硕博论文授权说明扫描版(#36)。
-- `acknowledgement`: 使用 pdfpages 宏包支持本硕博论文声明扫描版(#36)。
+- `\tableofcontents`: 修正学位论文中目录里节前缩进(#103)。
+- `\makecover`: 使用 `pdfpages` 宏包支持本硕博论文授权说明扫描版(#36)。
+- `acknowledgement`: 使用 pdfpages 宏包支持本硕博论文声明扫描版(#36)。
- `\inlinecite`: 用 `\inlinecite` 替换 `\onlinecite`。为保证兼 容性,`\onlinecite` 会保留。
-- `achievements`: 博士后就不提在学期间了,不合适(#100)
-- `achievements`: 让简历部分更符合格式指南和示例文件(#122)
+- `achievements`: 博士后就不提在学期间了,不合适(#100)。
+- `achievements`: 让简历部分更符合格式指南和示例文件(#122)。
- `\shuji`: 扩展 `\shuji[<标题>][<作者>]`。
## [v4.8.1] - 2014-12-09
@@ -374,7 +395,7 @@
- 调整段前距为 -12bp 而不是原来的 -16bp。
- `\tableofcontents`: 本科生目录字号改回`\xiaosi[<1.8>]`。
- `\tableofcontents`: 本科生目录缩进要求不同。
-- `\tableofcontents`: 本科章目录项一直用黑体 (Arial)。
+- `\tableofcontents`: 本科章目录项一直用黑体(Arial)。
## [v4.3] - 2008-03-11
### Changed
@@ -542,7 +563,7 @@
### Changed
- Fill more pdf info. with `\hypersetup`.
- 自动隐藏密级为内部时后面的五角星。
-- 增加“注释 (Remark)”环境。
+- 增加“注释(Remark)”环境。
- 压缩 item 之间的距离。
- `thubib.bst` 文献标题取消自动小写。
- 中文参考文献取消 In: Proceedings。
@@ -642,7 +663,8 @@
-[Unreleased]: https://github.com/tuna/thuthesis/compare/v7.1.0...HEAD
+[Unreleased]: https://github.com/tuna/thuthesis/compare/v7.2.0...HEAD
+[v7.2.0]: https://github.com/tuna/thuthesis/compare/v7.1.0...v7.2.0
[v7.1.0]: https://github.com/tuna/thuthesis/compare/v7.0.0...v7.1.0
[v7.0.0]: https://github.com/tuna/thuthesis/compare/v6.1.3...v7.0.0
[v6.1.3]: https://github.com/tuna/thuthesis/compare/v6.1.2...v6.1.3
diff --git a/macros/latex/contrib/thuthesis/README.md b/macros/latex/contrib/thuthesis/README.md
index ed0788a5ad..d922e5cc82 100644
--- a/macros/latex/contrib/thuthesis/README.md
+++ b/macros/latex/contrib/thuthesis/README.md
@@ -23,8 +23,8 @@ Scroll down for the English version of README.
推荐下载**发布版**模板,里面包括具体使用说明以及示例文档:
-* 模板使用说明 (thuthesis.pdf)
-* 示例文档 (thuthesis-example.pdf)
+* 模板使用说明(thuthesis.pdf)
+* 示例文档(thuthesis-example.pdf)
开发版中不提供预生成的 `cls` 文件和文档,仅包含源码。其仅供开发者与需要尚未发布的功能的有经验的 TeX 用户使用,不提供任何保证。
@@ -51,7 +51,7 @@ Scroll down for the English version of README.
下载发布版的的 zip 包,使用其中的 `thuthesis.cls` 等文件覆盖原有的即可,无须额外操作。
-#### 开发板
+#### 开发版
从 GitHub clone 项目源码或者下载源码 zip 包,执行命令(Windows 用户在文件夹空白处按 `Shift + 鼠标右键`,点击“在此处打开命令行窗口”):
diff --git a/macros/latex/contrib/thuthesis/data/appendix-survey.tex b/macros/latex/contrib/thuthesis/data/appendix-survey.tex
index 5dd97a7a08..76fe5b12f5 100644
--- a/macros/latex/contrib/thuthesis/data/appendix-survey.tex
+++ b/macros/latex/contrib/thuthesis/data/appendix-survey.tex
@@ -53,7 +53,7 @@ An example table in appendix (Table~\ref{tab:appendix-survey-table}).
An example equation in appendix (Equation~\eqref{eq:appendix-survey-equation}).
\begin{equation}
- \frac{1}{2 \symup{\pi} \symup{i}} \int_\gamma f = \sum_{k=1}^m n(\gamma; a_k) \mathscr{R}(f; a_k)
+ \frac{1}{2 \uppi \symup{i}} \int_\gamma f = \sum_{k=1}^m n(\gamma; a_k) \mathscr{R}(f; a_k)
\label{eq:appendix-survey-equation}
\end{equation}
diff --git a/macros/latex/contrib/thuthesis/data/appendix-translation.tex b/macros/latex/contrib/thuthesis/data/appendix-translation.tex
index 891e416b06..d272480bf4 100644
--- a/macros/latex/contrib/thuthesis/data/appendix-translation.tex
+++ b/macros/latex/contrib/thuthesis/data/appendix-translation.tex
@@ -52,7 +52,7 @@
附录中的数学公式示例(公式~\eqref{eq:appendix-translation-equation})。
\begin{equation}
- \frac{1}{2 \symup{\pi} \symup{i}} \int_\gamma f = \sum_{k=1}^m n(\gamma; a_k) \mathscr{R}(f; a_k)
+ \frac{1}{2 \uppi \symup{i}} \int_\gamma f = \sum_{k=1}^m n(\gamma; a_k) \mathscr{R}(f; a_k)
\label{eq:appendix-translation-equation}
\end{equation}
diff --git a/macros/latex/contrib/thuthesis/data/appendix.tex b/macros/latex/contrib/thuthesis/data/appendix.tex
index 94b1743931..39ac664248 100644
--- a/macros/latex/contrib/thuthesis/data/appendix.tex
+++ b/macros/latex/contrib/thuthesis/data/appendix.tex
@@ -1,3 +1,5 @@
+% !TeX root = ../thuthesis-example.tex
+
\chapter{补充内容}
附录是与论文内容密切相关、但编入正文又影响整篇论文编排的条理和逻辑性的资料,例如某些重要的数据表格、计算程序、统计表等,是论文主体的补充内容,可根据需要设置。
@@ -43,6 +45,6 @@
附录中的数学公式示例(公式~\eqref{eq:appendix-equation})。
\begin{equation}
- \frac{1}{2 \symup{\pi} \symup{i}} \int_\gamma f = \sum_{k=1}^m n(\gamma; a_k) \mathscr{R}(f; a_k)
+ \frac{1}{2 \uppi \symup{i}} \int_\gamma f = \sum_{k=1}^m n(\gamma; a_k) \mathscr{R}(f; a_k)
\label{eq:appendix-equation}
\end{equation}
diff --git a/macros/latex/contrib/thuthesis/data/chap01.tex b/macros/latex/contrib/thuthesis/data/chap01.tex
index a1ce9626fc..b4f6641733 100644
--- a/macros/latex/contrib/thuthesis/data/chap01.tex
+++ b/macros/latex/contrib/thuthesis/data/chap01.tex
@@ -4,7 +4,7 @@
研究生学位论文撰写,除表达形式上需要符合一定的格式要求外,内容方面上也要遵循一些共性原则。
-通常研究生学位论文只能有一个主题(不能是几块工作拼凑在一起),该主题应针对某学科领域中的一个具体问题展开深入、系统的研究,并得出有价值的研究结论。
+通常研究生学位论文只能有一个主题(不能是几块工作拼凑在一起),该主题应针对某学科领域中的一个具体问题展开深入、系统的研究,并得出有价值的研究结论。
学位论文的研究主题切忌过大,例如,“中国国有企业改制问题研究”这样的研究主题过大,因为“国企改制”涉及的问题范围太广,很难在一本研究生学位论文中完全研究透彻。
diff --git a/macros/latex/contrib/thuthesis/data/chap02.tex b/macros/latex/contrib/thuthesis/data/chap02.tex
index 31f7032e1a..8d6c2b070e 100644
--- a/macros/latex/contrib/thuthesis/data/chap02.tex
+++ b/macros/latex/contrib/thuthesis/data/chap02.tex
@@ -20,7 +20,7 @@
若图或表中有附注,采用英文小写字母顺序编号,附注写在图或表的下方。
% LaTeX 传统上一般将附注的内容同图表的标题写在一起,形成很长的一段文字。
-如果一个图由两个或两个以上分图组成时,各分图分别以(a)、(b)、(c)...... 作为图序,并须有分图题。
+如果一个图由两个或两个以上分图组成时,各分图分别以 (a)、(b)、(c)...... 作为图序,并须有分图题。
推荐使用 \pkg{subcaption} 宏包来处理, 比如图~\ref{fig:subfig-a} 和图~\ref{fig:subfig-b}。
\begin{figure}
@@ -83,3 +83,71 @@
\end{tablenotes}
\end{threeparttable}
\end{table}
+
+如某个表需要转页接排,可以使用 \pkg{longtable} 宏包,需要在随后的各页上重复表的编号。
+编号后跟表题(可省略)和“(续)”,置于表上方。续表均应重复表头。
+
+\begin{longtable}{cccc}
+ \caption{跨页长表格的表题} \\
+ \toprule
+ 表头 1 & 表头 2 & 表头 3 & 表头 4 \\
+ \midrule
+ \endfirsthead
+ \caption[]{跨页长表格的表题(续)} \\
+ \toprule
+ 表头 1 & 表头 2 & 表头 3 & 表头 4 \\
+ \midrule
+ \endhead
+ \bottomrule
+ \endfoot
+ Row 1 & & & \\
+ Row 2 & & & \\
+ Row 3 & & & \\
+ Row 4 & & & \\
+ Row 5 & & & \\
+ Row 6 & & & \\
+ Row 7 & & & \\
+ Row 8 & & & \\
+ Row 9 & & & \\
+ Row 10 & & & \\
+ Row 11 & & & \\
+ Row 12 & & & \\
+ Row 13 & & & \\
+ Row 14 & & & \\
+ Row 15 & & & \\
+ Row 16 & & & \\
+ Row 17 & & & \\
+ Row 18 & & & \\
+ Row 19 & & & \\
+ Row 20 & & & \\
+ Row 21 & & & \\
+ Row 22 & & & \\
+ Row 23 & & & \\
+ Row 24 & & & \\
+ Row 25 & & & \\
+ Row 26 & & & \\
+ Row 27 & & & \\
+ Row 28 & & & \\
+ Row 29 & & & \\
+ Row 30 & & & \\
+ Row 31 & & & \\
+ Row 32 & & & \\
+ Row 33 & & & \\
+ Row 34 & & & \\
+ Row 35 & & & \\
+ Row 36 & & & \\
+ Row 37 & & & \\
+ Row 38 & & & \\
+ Row 39 & & & \\
+ Row 40 & & & \\
+ Row 41 & & & \\
+ Row 42 & & & \\
+ Row 43 & & & \\
+ Row 44 & & & \\
+ Row 45 & & & \\
+ Row 46 & & & \\
+ Row 47 & & & \\
+ Row 48 & & & \\
+ Row 49 & & & \\
+ Row 50 & & & \\
+\end{longtable}
diff --git a/macros/latex/contrib/thuthesis/data/chap03.tex b/macros/latex/contrib/thuthesis/data/chap03.tex
index 2cb452b0be..3725e1f0fc 100644
--- a/macros/latex/contrib/thuthesis/data/chap03.tex
+++ b/macros/latex/contrib/thuthesis/data/chap03.tex
@@ -4,25 +4,20 @@
\section{数学符号}
-研究生《写作指南》要求量及其单位所使用的符号应符合国家标准《国际单位制及其应用》(GB 3100—1993)、《有关量、单位和符号的一般原则》(GB/T 3101—1993) 的规定。
-模板中使用 \pkg{unicode-math} 宏包来配置数学符号,
-与 \LaTeX{} 默认的英美国家的符号习惯有所差异:
+中文论文的数学符号默认采用 GB/T 3102.11—1993《物理科学和技术中使用的数学符号》。
+该标准参照采纳 ISO 31-11:1992(目前最新版为 ISO 80000-2:2019),
+但是与 \TeX{} 默认的英美国家的符号习惯有许多差异,主要有:
\begin{enumerate}
- \item 大写希腊字母默认为斜体,如 \cs{Delta}:$\Delta$。
- \item 有限增量符号 $\increment$(U+2206)应使用 \pkg{unicode-math} 宏包提供的
- \cs{increment} 命令。
- \item 向量、矩阵和张量要求粗斜体,应该使用 \pkg{unicode-math} 的 \cs{symbf} 命令,
- 如 \verb|\symbf{A}|、\verb|\symbf{\alpha}|。
- \item 数学常数和特殊函数要求用正体,应使用 \cs{symup} 命令,
- 如 $\symup{\pi} = 3.14\dots$; $\symup{e} = 2.718\dots$,
- \item 微分号和积分号使用使用正体,比如 $\int f(x) \dif x$。
+ \item 大写希腊字母默认为斜体,如 $\Delta$、$\Sigma$,
+ 有限增量符号 $\increment$(\cs{increment})固定使用正体。
+ \item 数学常数和特殊函数名用正体,如 $\uppi = 3.14\dots$;$\symup{e} = 2.718\dots$。
+ \item 微分号使用正体,比如 $\dif y / \dif x$。
+ \item 向量、矩阵和张量用粗斜体(\cs{symbf}),如 $\symbf{x}$、$\symbf{\Sigma}$。
+ \item 省略号按照中文的习惯固定居中,如 $1, 2, \dots, n$。
\end{enumerate}
-关于数学符号更多的用法,参考
-\href{http://mirrors.ctan.org/macros/latex/contrib/unicode-math/unicode-math.pdf}{\pkg{unicode-math}}
-宏包的使用说明,
-全部数学符号命的令参考
-\href{http://mirrors.ctan.org/macros/latex/contrib/unicode-math/unimath-symbols.pdf}{\pkg{unimath-symbols}}。
+英文论文的数学符号使用 \TeX{} 默认的样式。
+如果有必要,也可以通过设置 \verb|math-style| 选择数学符号样式。
关于量和单位推荐使用
\href{http://mirrors.ctan.org/macros/latex/contrib/siunitx/siunitx.pdf}{\pkg{siunitx}}
@@ -41,7 +36,7 @@
数学公式可以使用 \env{equation} 和 \env{equation*} 环境。
注意数学公式的引用应前后带括号,建议使用 \cs{eqref} 命令,比如式 \eqref{eq:example}。
\begin{equation}
- \frac{1}{2 \symup{\pi} \symup{i}} \int_\gamma f = \sum_{k=1}^m n(\gamma; a_k) \mathscr{R}(f; a_k)
+ \frac{1}{2 \uppi \symup{i}} \int_\gamma f = \sum_{k=1}^m n(\gamma; a_k) \mathscr{R}(f; a_k)
\label{eq:example}
\end{equation}
注意公式编号的引用应含有圆括号,可以使用 \cs{eqref} 命令。
diff --git a/macros/latex/contrib/thuthesis/data/comments.tex b/macros/latex/contrib/thuthesis/data/comments.tex
index a5e172a91b..832d18dd0e 100644
--- a/macros/latex/contrib/thuthesis/data/comments.tex
+++ b/macros/latex/contrib/thuthesis/data/comments.tex
@@ -1,5 +1,10 @@
% !TeX root = ../thuthesis-example.tex
-\chapter{指导小组学术评语}
+\begin{comments}
+% \begin{comments}[name = {指导小组学术评语}]
+% \begin{comments}[name = {Comments from Thesis Supervisor}]
+% \begin{comments}[name = {Comments from Thesis Supervision Committee}]
-论文提出了……
+ 论文提出了……
+
+\end{comments}
diff --git a/macros/latex/contrib/thuthesis/data/denotation.tex b/macros/latex/contrib/thuthesis/data/denotation.tex
index 914288e3eb..868d7603ba 100644
--- a/macros/latex/contrib/thuthesis/data/denotation.tex
+++ b/macros/latex/contrib/thuthesis/data/denotation.tex
@@ -22,24 +22,24 @@
\item[HMSPPT] 聚苯基对称三嗪模型化合物的质子化产物
\item[HMPPQ] 聚苯基喹噁啉模型化合物的质子化产物
\item[PDT] 热分解温度
- \item[HPLC] 高效液相色谱 (High Performance Liquid Chromatography)
- \item[HPCE] 高效毛细管电泳色谱 (High Performance Capillary lectrophoresis)
- \item[LC-MS] 液相色谱-质谱联用 (Liquid chromatography-Mass Spectrum)
- \item[TIC] 总离子浓度 (Total Ion Content)
+ \item[HPLC] 高效液相色谱(High Performance Liquid Chromatography)
+ \item[HPCE] 高效毛细管电泳色谱(High Performance Capillary lectrophoresis)
+ \item[LC-MS] 液相色谱-质谱联用(Liquid chromatography-Mass Spectrum)
+ \item[TIC] 总离子浓度(Total Ion Content)
\item[\textit{ab initio}] 基于第一原理的量子化学计算方法,常称从头算法
- \item[DFT] 密度泛函理论 (Density Functional Theory)
- \item[$E_a$] 化学反应的活化能 (Activation Energy)
- \item[ZPE] 零点振动能 (Zero Vibration Energy)
- \item[PES] 势能面 (Potential Energy Surface)
- \item[TS] 过渡态 (Transition State)
- \item[TST] 过渡态理论 (Transition State Theory)
- \item[$\increment G^\neq$] 活化自由能(Activation Free Energy)
- \item[$\kappa$] 传输系数 (Transmission Coefficient)
- \item[IRC] 内禀反应坐标 (Intrinsic Reaction Coordinates)
- \item[$\nu_i$] 虚频 (Imaginary Frequency)
- \item[ONIOM] 分层算法 (Our own N-layered Integrated molecular Orbital and molecular Mechanics)
- \item[SCF] 自洽场 (Self-Consistent Field)
- \item[SCRF] 自洽反应场 (Self-Consistent Reaction Field)
+ \item[DFT] 密度泛函理论(Density Functional Theory)
+ \item[$E_a$] 化学反应的活化能(Activation Energy)
+ \item[ZPE] 零点振动能(Zero Vibration Energy)
+ \item[PES] 势能面(Potential Energy Surface)
+ \item[TS] 过渡态(Transition State)
+ \item[TST] 过渡态理论(Transition State Theory)
+ \item[$\increment G^\neq$] 活化自由能(Activation Free Energy)
+ \item[$\kappa$] 传输系数(Transmission Coefficient)
+ \item[IRC] 内禀反应坐标(Intrinsic Reaction Coordinates)
+ \item[$\nu_i$] 虚频(Imaginary Frequency)
+ \item[ONIOM] 分层算法(Our own N-layered Integrated molecular Orbital and molecular Mechanics)
+ \item[SCF] 自洽场(Self-Consistent Field)
+ \item[SCRF] 自洽反应场(Self-Consistent Reaction Field)
\end{denotation}
@@ -73,21 +73,21 @@
% \nomenclature{HMSPPT}{聚苯基对称三嗪模型化合物的质子化产物}
% \nomenclature{HMPPQ}{聚苯基喹噁啉模型化合物的质子化产物}
% \nomenclature{PDT}{热分解温度}
-% \nomenclature{HPLC}{高效液相色谱 (High Performance Liquid Chromatography)}
-% \nomenclature{HPCE}{高效毛细管电泳色谱 (High Performance Capillary lectrophoresis)}
-% \nomenclature{LC-MS}{液相色谱-质谱联用 (Liquid chromatography-Mass Spectrum)}
-% \nomenclature{TIC}{总离子浓度 (Total Ion Content)}
+% \nomenclature{HPLC}{高效液相色谱(High Performance Liquid Chromatography)}
+% \nomenclature{HPCE}{高效毛细管电泳色谱(High Performance Capillary lectrophoresis)}
+% \nomenclature{LC-MS}{液相色谱-质谱联用(Liquid chromatography-Mass Spectrum)}
+% \nomenclature{TIC}{总离子浓度(Total Ion Content)}
% \nomenclature{\textit{ab initio}}{基于第一原理的量子化学计算方法,常称从头算法}
-% \nomenclature{DFT}{密度泛函理论 (Density Functional Theory)}
-% \nomenclature{$E_a$}{化学反应的活化能 (Activation Energy)}
-% \nomenclature{ZPE}{零点振动能 (Zero Vibration Energy)}
-% \nomenclature{PES}{势能面 (Potential Energy Surface)}
-% \nomenclature{TS}{过渡态 (Transition State)}
-% \nomenclature{TST}{过渡态理论 (Transition State Theory)}
-% \nomenclature{$\increment G^\neq$}{活化自由能(Activation Free Energy)}
-% \nomenclature{$\kappa$}{传输系数 (Transmission Coefficient)}
-% \nomenclature{IRC}{内禀反应坐标 (Intrinsic Reaction Coordinates)}
-% \nomenclature{$\nu_i$}{虚频 (Imaginary Frequency)}
-% \nomenclature{ONIOM}{分层算法 (Our own N-layered Integrated molecular Orbital and molecular Mechanics)}
-% \nomenclature{SCF}{自洽场 (Self-Consistent Field)}
-% \nomenclature{SCRF}{自洽反应场 (Self-Consistent Reaction Field)}
+% \nomenclature{DFT}{密度泛函理论(Density Functional Theory)}
+% \nomenclature{$E_a$}{化学反应的活化能(Activation Energy)}
+% \nomenclature{ZPE}{零点振动能(Zero Vibration Energy)}
+% \nomenclature{PES}{势能面(Potential Energy Surface)}
+% \nomenclature{TS}{过渡态(Transition State)}
+% \nomenclature{TST}{过渡态理论(Transition State Theory)}
+% \nomenclature{$\increment G^\neq$}{活化自由能(Activation Free Energy)}
+% \nomenclature{$\kappa$}{传输系数(Transmission Coefficient)}
+% \nomenclature{IRC}{内禀反应坐标(Intrinsic Reaction Coordinates)}
+% \nomenclature{$\nu_i$}{虚频(Imaginary Frequency)}
+% \nomenclature{ONIOM}{分层算法(Our own N-layered Integrated molecular Orbital and molecular Mechanics)}
+% \nomenclature{SCF}{自洽场(Self-Consistent Field)}
+% \nomenclature{SCRF}{自洽反应场(Self-Consistent Reaction Field)}
diff --git a/macros/latex/contrib/thuthesis/data/resolution.tex b/macros/latex/contrib/thuthesis/data/resolution.tex
index 81091ea9a3..49667e9abe 100644
--- a/macros/latex/contrib/thuthesis/data/resolution.tex
+++ b/macros/latex/contrib/thuthesis/data/resolution.tex
@@ -1,17 +1,19 @@
% !TeX root = ../thuthesis-example.tex
-\chapter{答辩委员会决议书}
+\begin{resolution}
-论文提出了……
+ 论文提出了……
-论文取得的主要创新性成果包括:
+ 论文取得的主要创新性成果包括:
-1. ……
+ 1. ……
-2. ……
+ 2. ……
-3. ……
+ 3. ……
-论文工作表明作者在×××××具有×××××知识,具有××××能力,论文××××,答辩××××。
+ 论文工作表明作者在×××××具有×××××知识,具有××××能力,论文××××,答辩××××。
-答辩委员会表决,(×票/一致)同意通过论文答辩,并建议授予×××(姓名)×××(门类)学博士/硕士学位。
+ 答辩委员会表决,(×票/一致)同意通过论文答辩,并建议授予×××(姓名)×××(门类)学博士/硕士学位。
+
+\end{resolution}
diff --git a/macros/latex/contrib/thuthesis/ref/refs.bib b/macros/latex/contrib/thuthesis/ref/refs.bib
index ff2b667a71..4ca6bccded 100644
--- a/macros/latex/contrib/thuthesis/ref/refs.bib
+++ b/macros/latex/contrib/thuthesis/ref/refs.bib
@@ -194,6 +194,7 @@
address = {北京},
publisher = {中国标准出版社},
year = {2002},
+ pages = {1},
key = {quan2 guo2 xin4 xi1},
}
diff --git a/macros/latex/contrib/thuthesis/spine.pdf b/macros/latex/contrib/thuthesis/spine.pdf
index 8f0f80226e..0786194e73 100644
--- a/macros/latex/contrib/thuthesis/spine.pdf
+++ b/macros/latex/contrib/thuthesis/spine.pdf
Binary files differ
diff --git a/macros/latex/contrib/thuthesis/thusetup.tex b/macros/latex/contrib/thuthesis/thusetup.tex
index 26254e2325..894762e178 100644
--- a/macros/latex/contrib/thuthesis/thusetup.tex
+++ b/macros/latex/contrib/thuthesis/thusetup.tex
@@ -77,8 +77,8 @@
%
% 联合指导教师
%
- % joint-supervisor = {某某某, 教授},
- % joint-supervisor* = {Professor Mou Moumou},
+ % co-supervisor = {某某某, 教授},
+ % co-supervisor* = {Professor Mou Moumou},
%
% 日期
% 使用 ISO 格式;默认为当前时间
@@ -107,6 +107,18 @@
% 载入所需的宏包
+% 定理类环境宏包
+\usepackage{amsthm}
+% 也可以使用 ntheorem
+% \usepackage[amsmath,thmmarks,hyperref]{ntheorem}
+
+\thusetup{
+ %
+ % 数学字体
+ % math-style = GB,
+ math-font = xits,
+}
+
% 可以使用 nomencl 生成符号和缩略语说明
% \usepackage{nomencl}
% \makenomenclature
@@ -117,20 +129,15 @@
% 表格中支持跨行
\usepackage{multirow}
-% 固定宽度的表格。放在 hyperref 之前的话,tabularx 里的 footnote 显示不出来。
+% 固定宽度的表格。
% \usepackage{tabularx}
% 跨页表格
-% \usepackage{longtable}
+\usepackage{longtable}
% 量和单位
\usepackage{siunitx}
-% 定理类环境宏包
-\usepackage{amsthm}
-% 也可以使用 ntheorem
-% \usepackage[amsmath,thmmarks,hyperref]{ntheorem}
-
% 参考文献使用 BibTeX + natbib 宏包
% 顺序编码制
\usepackage[sort]{natbib}
@@ -156,7 +163,16 @@
\graphicspath{{figures/}}
% 数学命令
-\newcommand\dif{\mathop{}\!\mathrm{d}} % 微分符号
+\makeatletter
+\newcommand\dif{% % 微分符号
+ \mathop{}\!%
+ \ifthu@math@style@TeX
+ d%
+ \else
+ \mathrm{d}%
+ \fi
+}
+\makeatother
% hyperref 宏包在最后调用
\usepackage{hyperref}
diff --git a/macros/latex/contrib/thuthesis/thuthesis-author-year.bbx b/macros/latex/contrib/thuthesis/thuthesis-author-year.bbx
index 47ec9ea815..ebaa95d168 100644
--- a/macros/latex/contrib/thuthesis/thuthesis-author-year.bbx
+++ b/macros/latex/contrib/thuthesis/thuthesis-author-year.bbx
@@ -18,3 +18,5 @@
\setlength{\parsep}{\bibparsep}}}
{\endlist}
{\item}
+
+\renewcommand*{\bibpagespunct}{\addcolon\addthinspace}
diff --git a/macros/latex/contrib/thuthesis/thuthesis-author-year.bst b/macros/latex/contrib/thuthesis/thuthesis-author-year.bst
index 2a361a97c2..22126985c5 100644
--- a/macros/latex/contrib/thuthesis/thuthesis-author-year.bst
+++ b/macros/latex/contrib/thuthesis/thuthesis-author-year.bst
@@ -4,13 +4,13 @@
%%
%% The original source files were:
%%
-%% gbt7714.dtx (with options: `thu,2015,authoryear')
+%% gbt7714.dtx (with options: `2015,thu,authoryear')
%% -------------------------------------------------------------------
-%% GB/T 7714-2015 BibTeX Style
+%% GB/T 7714—2015 BibTeX Style
%% https://github.com/CTeX-org/gbt7714-bibtex-style
-%% Version: 2020/06/08 v2.0.2
+%% Version: 2020/12/17 v2.1
%% -------------------------------------------------------------------
-%% Copyright (C) 2016-2020 by Zeping Lee <zepinglee AT gmail.com>
+%% Copyright (C) 2016—2021 by Zeping Lee <zepinglee AT gmail.com>
%% -------------------------------------------------------------------
%% This file may be distributed and/or modified under the
%% conditions of the LaTeX Project Public License, either version 1.3c
@@ -18,7 +18,7 @@
%% The latest version of this license is in
%% https://www.latex-project.org/lppl.txt
%% and version 1.3c or later is part of all distributions of LaTeX
-%% version 2005/12/01 or later.
+%% version 2008 or later.
%% -------------------------------------------------------------------
INTEGERS {
citation.et.al.min
@@ -41,6 +41,7 @@ INTEGERS {
italic.journal
bold.journal.volume
show.missing.address.publisher
+ space.before.pages
only.start.page
show.urldate
show.url
@@ -77,6 +78,7 @@ FUNCTION {load.config}
#0 'italic.journal :=
#0 'bold.journal.volume :=
#0 'show.missing.address.publisher :=
+ #0 'space.before.pages :=
#0 'only.start.page :=
#1 'show.urldate :=
#1 'show.url :=
@@ -198,9 +200,16 @@ FUNCTION {citation.et.al}
FUNCTION {bbl.colon} { ": " }
+FUNCTION {bbl.pages.colon}
+{ space.before.pages
+ { ": " }
+ { ":\allowbreak " }
+ if$
+}
+
FUNCTION {bbl.wide.space} { "\quad " }
-FUNCTION {bbl.slash} { "// " }
+FUNCTION {bbl.slash} { "//\allowbreak " }
FUNCTION {bbl.sine.loco}
{ entry.lang lang.zh =
@@ -1032,9 +1041,10 @@ FUNCTION {format.mark}
if$
'entry.mark :=
space.before.mark
- { " [" entry.mark * "]" * }
- { "[" entry.mark * "]" * }
+ { " " }
+ { "\allowbreak" }
if$
+ "[" * entry.mark * "]" *
}
{ "" }
if$
@@ -1367,7 +1377,7 @@ FUNCTION {format.journal.volume}
FUNCTION {format.journal.number}
{ number empty$ not
- { "\penalty0 (" number * ")" * }
+ { "\allowbreak (" number * ")" * }
{ "" }
if$
}
@@ -1375,9 +1385,7 @@ FUNCTION {format.journal.number}
FUNCTION {format.journal.pages}
{ pages empty$
{ "" }
- { ": "
- format.extracted.pages *
- }
+ { format.extracted.pages }
if$
}
@@ -1391,7 +1399,7 @@ FUNCTION {format.periodical.year.volume.number}
'skip$
if$
number empty$ not
- { "\penalty0 (" * number extract.before.dash * ")" * }
+ { "\allowbreak (" * number extract.before.dash * ")" * }
'skip$
if$
"--" *
@@ -1407,7 +1415,7 @@ FUNCTION {format.periodical.year.volume.number}
'skip$
if$
number empty$ not
- { "\penalty0 (" * number extract.after.dash * ")" * }
+ { "\allowbreak (" * number extract.after.dash * ")" * }
'skip$
if$
}
@@ -1659,7 +1667,7 @@ FUNCTION {monograph}
{ format.year "year" output.check }
'skip$
if$
- format.pages bbl.colon output.after
+ format.pages bbl.pages.colon output.after
format.urldate "" output.after
output.url
output.doi
@@ -1700,7 +1708,7 @@ FUNCTION {incollection}
{ format.year "year" output.check }
'skip$
if$
- format.extracted.pages bbl.colon output.after
+ format.extracted.pages bbl.pages.colon output.after
format.urldate "" output.after
output.url
output.doi
@@ -1773,7 +1781,7 @@ FUNCTION {article}
if$
format.journal.volume output
format.journal.number "" output.after
- format.journal.pages "" output.after
+ format.journal.pages bbl.pages.colon output.after
format.urldate "" output.after
output.url
output.doi
@@ -1841,7 +1849,7 @@ FUNCTION {electronic}
}
'skip$
if$
- format.pages bbl.colon output.after
+ format.pages bbl.pages.colon output.after
format.editdate "" output.after
format.urldate "" output.after
output.url
@@ -1892,7 +1900,7 @@ FUNCTION {preprint}
{ format.year "year" output.check }
'skip$
if$
- format.pages bbl.colon output.after
+ format.pages bbl.pages.colon output.after
format.urldate "" output.after
output.url
new.block
diff --git a/macros/latex/contrib/thuthesis/thuthesis-bachelor.bst b/macros/latex/contrib/thuthesis/thuthesis-bachelor.bst
index 9094bc339b..1dd06bb887 100644
--- a/macros/latex/contrib/thuthesis/thuthesis-bachelor.bst
+++ b/macros/latex/contrib/thuthesis/thuthesis-bachelor.bst
@@ -6,11 +6,11 @@
%%
%% gbt7714.dtx (with options: `2015,numerical,noslsn')
%% -------------------------------------------------------------------
-%% GB/T 7714-2015 BibTeX Style
+%% GB/T 7714—2015 BibTeX Style
%% https://github.com/CTeX-org/gbt7714-bibtex-style
-%% Version: 2020/06/08 v2.0.2
+%% Version: 2020/12/17 v2.1
%% -------------------------------------------------------------------
-%% Copyright (C) 2016-2020 by Zeping Lee <zepinglee AT gmail.com>
+%% Copyright (C) 2016—2021 by Zeping Lee <zepinglee AT gmail.com>
%% -------------------------------------------------------------------
%% This file may be distributed and/or modified under the
%% conditions of the LaTeX Project Public License, either version 1.3c
@@ -18,7 +18,7 @@
%% The latest version of this license is in
%% https://www.latex-project.org/lppl.txt
%% and version 1.3c or later is part of all distributions of LaTeX
-%% version 2005/12/01 or later.
+%% version 2008 or later.
%% -------------------------------------------------------------------
INTEGERS {
citation.et.al.min
@@ -41,6 +41,7 @@ INTEGERS {
italic.journal
bold.journal.volume
show.missing.address.publisher
+ space.before.pages
only.start.page
show.urldate
show.url
@@ -64,7 +65,7 @@ FUNCTION {load.config}
#0 'link.title :=
#1 'title.in.journal :=
#1 'show.mark :=
- #1 'space.before.mark :=
+ #0 'space.before.mark :=
#1 'show.medium.type :=
#1 'slash.for.extraction :=
#0 'in.booktitle :=
@@ -72,6 +73,7 @@ FUNCTION {load.config}
#0 'italic.journal :=
#0 'bold.journal.volume :=
#0 'show.missing.address.publisher :=
+ #1 'space.before.pages :=
#0 'only.start.page :=
#1 'show.urldate :=
#1 'show.url :=
@@ -188,6 +190,13 @@ FUNCTION {citation.et.al}
FUNCTION {bbl.colon} { ": " }
+FUNCTION {bbl.pages.colon}
+{ space.before.pages
+ { ": " }
+ { ":\allowbreak " }
+ if$
+}
+
FUNCTION {bbl.wide.space} { "\quad " }
FUNCTION {bbl.slash} { "//\allowbreak " }
@@ -1022,9 +1031,10 @@ FUNCTION {format.mark}
if$
'entry.mark :=
space.before.mark
- { " [" entry.mark * "]" * }
- { "[" entry.mark * "]" * }
+ { " " }
+ { "\allowbreak" }
if$
+ "[" * entry.mark * "]" *
}
{ "" }
if$
@@ -1357,7 +1367,7 @@ FUNCTION {format.journal.volume}
FUNCTION {format.journal.number}
{ number empty$ not
- { "\penalty0 (" number * ")" * }
+ { "\allowbreak (" number * ")" * }
{ "" }
if$
}
@@ -1365,9 +1375,7 @@ FUNCTION {format.journal.number}
FUNCTION {format.journal.pages}
{ pages empty$
{ "" }
- { ": "
- format.extracted.pages *
- }
+ { format.extracted.pages }
if$
}
@@ -1381,7 +1389,7 @@ FUNCTION {format.periodical.year.volume.number}
'skip$
if$
number empty$ not
- { "\penalty0 (" * number extract.before.dash * ")" * }
+ { "\allowbreak (" * number extract.before.dash * ")" * }
'skip$
if$
"--" *
@@ -1397,7 +1405,7 @@ FUNCTION {format.periodical.year.volume.number}
'skip$
if$
number empty$ not
- { "\penalty0 (" * number extract.after.dash * ")" * }
+ { "\allowbreak (" * number extract.after.dash * ")" * }
'skip$
if$
}
@@ -1649,7 +1657,7 @@ FUNCTION {monograph}
{ format.year "year" output.check }
'skip$
if$
- format.pages bbl.colon output.after
+ format.pages bbl.pages.colon output.after
format.urldate "" output.after
output.url
output.doi
@@ -1690,7 +1698,7 @@ FUNCTION {incollection}
{ format.year "year" output.check }
'skip$
if$
- format.extracted.pages bbl.colon output.after
+ format.extracted.pages bbl.pages.colon output.after
format.urldate "" output.after
output.url
output.doi
@@ -1763,7 +1771,7 @@ FUNCTION {article}
if$
format.journal.volume output
format.journal.number "" output.after
- format.journal.pages "" output.after
+ format.journal.pages bbl.pages.colon output.after
format.urldate "" output.after
output.url
output.doi
@@ -1831,7 +1839,7 @@ FUNCTION {electronic}
}
'skip$
if$
- format.pages bbl.colon output.after
+ format.pages bbl.pages.colon output.after
format.editdate "" output.after
format.urldate "" output.after
output.url
@@ -1882,7 +1890,7 @@ FUNCTION {preprint}
{ format.year "year" output.check }
'skip$
if$
- format.pages bbl.colon output.after
+ format.pages bbl.pages.colon output.after
format.urldate "" output.after
output.url
new.block
diff --git a/macros/latex/contrib/thuthesis/thuthesis-example.pdf b/macros/latex/contrib/thuthesis/thuthesis-example.pdf
index 92704a73fc..46923bf2c1 100644
--- a/macros/latex/contrib/thuthesis/thuthesis-example.pdf
+++ b/macros/latex/contrib/thuthesis/thuthesis-example.pdf
Binary files differ
diff --git a/macros/latex/contrib/thuthesis/thuthesis-example.tex b/macros/latex/contrib/thuthesis/thuthesis-example.tex
index 4f71d6db49..1520898b4c 100644
--- a/macros/latex/contrib/thuthesis/thuthesis-example.tex
+++ b/macros/latex/contrib/thuthesis/thuthesis-example.tex
@@ -7,6 +7,11 @@
% doctor | master | bachelor | postdoc
% 学位类型 degree-type:
% academic(默认)| professional
+ % 语言 language
+ % chinese(默认)| english
+ % 字体库 fontset
+ % windows | mac | fandol | ubuntu
+ % 研究生院建议终版使用 Windows 平台的字体编译
% 论文基本配置,加载宏包等全局配置
@@ -33,6 +38,7 @@
\tableofcontents
% 插图和附表清单
+% 本科生的插图索引和表格索引需要移至正文之后、参考文献前
\listoffiguresandtables % 插图和附表清单
% \listoffigures % 插图清单
% \listoftables % 附表清单
@@ -58,9 +64,9 @@
% 附录
\appendix
-\input{data/appendix}
% \input{data/appendix-survey} % 本科生:外文资料的调研阅读报告
% \input{data/appendix-translation} % 本科生:外文资料的书面翻译
+\input{data/appendix}
% 致谢
\input{data/acknowledgements}
diff --git a/macros/latex/contrib/thuthesis/thuthesis-numeric.bbx b/macros/latex/contrib/thuthesis/thuthesis-numeric.bbx
index f0d6234eff..c732471bfe 100644
--- a/macros/latex/contrib/thuthesis/thuthesis-numeric.bbx
+++ b/macros/latex/contrib/thuthesis/thuthesis-numeric.bbx
@@ -25,3 +25,5 @@
\renewcommand*{\makelabel}[1]{\hss##1}}
{\endlist}
{\item}
+
+\renewcommand*{\bibpagespunct}{\addcolon}
diff --git a/macros/latex/contrib/thuthesis/thuthesis-numeric.bst b/macros/latex/contrib/thuthesis/thuthesis-numeric.bst
index 9bb0702e39..6c1eaa63d7 100644
--- a/macros/latex/contrib/thuthesis/thuthesis-numeric.bst
+++ b/macros/latex/contrib/thuthesis/thuthesis-numeric.bst
@@ -4,13 +4,13 @@
%%
%% The original source files were:
%%
-%% gbt7714.dtx (with options: `thu,2015,numerical')
+%% gbt7714.dtx (with options: `2015,thu,numerical')
%% -------------------------------------------------------------------
-%% GB/T 7714-2015 BibTeX Style
+%% GB/T 7714—2015 BibTeX Style
%% https://github.com/CTeX-org/gbt7714-bibtex-style
-%% Version: 2020/06/08 v2.0.2
+%% Version: 2020/12/17 v2.1
%% -------------------------------------------------------------------
-%% Copyright (C) 2016-2020 by Zeping Lee <zepinglee AT gmail.com>
+%% Copyright (C) 2016—2021 by Zeping Lee <zepinglee AT gmail.com>
%% -------------------------------------------------------------------
%% This file may be distributed and/or modified under the
%% conditions of the LaTeX Project Public License, either version 1.3c
@@ -18,7 +18,7 @@
%% The latest version of this license is in
%% https://www.latex-project.org/lppl.txt
%% and version 1.3c or later is part of all distributions of LaTeX
-%% version 2005/12/01 or later.
+%% version 2008 or later.
%% -------------------------------------------------------------------
INTEGERS {
citation.et.al.min
@@ -41,6 +41,7 @@ INTEGERS {
italic.journal
bold.journal.volume
show.missing.address.publisher
+ space.before.pages
only.start.page
show.urldate
show.url
@@ -72,6 +73,7 @@ FUNCTION {load.config}
#0 'italic.journal :=
#0 'bold.journal.volume :=
#0 'show.missing.address.publisher :=
+ #0 'space.before.pages :=
#0 'only.start.page :=
#1 'show.urldate :=
#1 'show.url :=
@@ -188,9 +190,16 @@ FUNCTION {citation.et.al}
FUNCTION {bbl.colon} { ": " }
+FUNCTION {bbl.pages.colon}
+{ space.before.pages
+ { ": " }
+ { ":\allowbreak " }
+ if$
+}
+
FUNCTION {bbl.wide.space} { "\quad " }
-FUNCTION {bbl.slash} { "// " }
+FUNCTION {bbl.slash} { "//\allowbreak " }
FUNCTION {bbl.sine.loco}
{ entry.lang lang.zh =
@@ -1022,9 +1031,10 @@ FUNCTION {format.mark}
if$
'entry.mark :=
space.before.mark
- { " [" entry.mark * "]" * }
- { "[" entry.mark * "]" * }
+ { " " }
+ { "\allowbreak" }
if$
+ "[" * entry.mark * "]" *
}
{ "" }
if$
@@ -1357,7 +1367,7 @@ FUNCTION {format.journal.volume}
FUNCTION {format.journal.number}
{ number empty$ not
- { "\penalty0 (" number * ")" * }
+ { "\allowbreak (" number * ")" * }
{ "" }
if$
}
@@ -1365,9 +1375,7 @@ FUNCTION {format.journal.number}
FUNCTION {format.journal.pages}
{ pages empty$
{ "" }
- { ": "
- format.extracted.pages *
- }
+ { format.extracted.pages }
if$
}
@@ -1381,7 +1389,7 @@ FUNCTION {format.periodical.year.volume.number}
'skip$
if$
number empty$ not
- { "\penalty0 (" * number extract.before.dash * ")" * }
+ { "\allowbreak (" * number extract.before.dash * ")" * }
'skip$
if$
"--" *
@@ -1397,7 +1405,7 @@ FUNCTION {format.periodical.year.volume.number}
'skip$
if$
number empty$ not
- { "\penalty0 (" * number extract.after.dash * ")" * }
+ { "\allowbreak (" * number extract.after.dash * ")" * }
'skip$
if$
}
@@ -1649,7 +1657,7 @@ FUNCTION {monograph}
{ format.year "year" output.check }
'skip$
if$
- format.pages bbl.colon output.after
+ format.pages bbl.pages.colon output.after
format.urldate "" output.after
output.url
output.doi
@@ -1690,7 +1698,7 @@ FUNCTION {incollection}
{ format.year "year" output.check }
'skip$
if$
- format.extracted.pages bbl.colon output.after
+ format.extracted.pages bbl.pages.colon output.after
format.urldate "" output.after
output.url
output.doi
@@ -1763,7 +1771,7 @@ FUNCTION {article}
if$
format.journal.volume output
format.journal.number "" output.after
- format.journal.pages "" output.after
+ format.journal.pages bbl.pages.colon output.after
format.urldate "" output.after
output.url
output.doi
@@ -1831,7 +1839,7 @@ FUNCTION {electronic}
}
'skip$
if$
- format.pages bbl.colon output.after
+ format.pages bbl.pages.colon output.after
format.editdate "" output.after
format.urldate "" output.after
output.url
@@ -1882,7 +1890,7 @@ FUNCTION {preprint}
{ format.year "year" output.check }
'skip$
if$
- format.pages bbl.colon output.after
+ format.pages bbl.pages.colon output.after
format.urldate "" output.after
output.url
new.block
diff --git a/macros/latex/contrib/thuthesis/thuthesis.dtx b/macros/latex/contrib/thuthesis/thuthesis.dtx
index 84c320323c..b98322fd50 100644
--- a/macros/latex/contrib/thuthesis/thuthesis.dtx
+++ b/macros/latex/contrib/thuthesis/thuthesis.dtx
@@ -1,23 +1,20 @@
% \iffalse meta-comment
%
-% Copyright (C) 2005-2020 by Tsinghua University TUNA Association <tuna@tsinghua.edu.cn>
-%
+% Copyright (C) 2005-2021 by Tsinghua University TUNA Association <tuna@tsinghua.edu.cn>
%
% This work may be distributed and/or modified under the
-% conditions of the LaTeX Project Public License, either version 1.3
+% conditions of the LaTeX Project Public License, either version 1.3c
% of this license or (at your option) any later version.
% The latest version of this license is in
-% http://www.latex-project.org/lppl.txt
-% and version 1.3 or later is part of all distributions of LaTeX
-% version 2005/12/01 or later.
-%
-% This work has the LPPL maintenance status `maintained'.
+% https://www.latex-project.org/lppl.txt
+% and version 1.3c or later is part of all distributions of LaTeX
+% version 2008 or later.
%
% \fi
%
% \iffalse
%<*driver>
-\ProvidesFile{thuthesis.dtx}[2020/10/14 7.1.0 Tsinghua University Thesis Template]
+\ProvidesFile{thuthesis.dtx}[2021/03/12 7.2.0 Tsinghua University Thesis Template]
\documentclass{ltxdoc}
\usepackage{dtx-style}
@@ -75,13 +72,17 @@
% \item 本模板的发布遵守 \href{https://www.latex-project.org/lppl/lppl-1-3c.txt}{\LaTeX{} Project Public License (1.3.c)},使用前请认真阅读协议内
% 容。
% \item 本模板为作者根据
-% 清华大学研究生院颁发的
-% \href{http://yjsy.cic.tsinghua.edu.cn/docinfo/board/boarddetail.jsp?columnId=001050603&parentColumnId=0010506&itemSeq=5365}{%
-% 《研究生学位论文写作指南》}(仅限校内网络访问)、
-% 清华大学教务处颁发的《综合论文训练写作指南》和
-% 清华大学
+% 清华大学研究生院颁发的《
+% \href{http://yjsy.cic.tsinghua.edu.cn/docinfo/board/boarddetail.jsp?columnId=001050603&parentColumnId=0010506&itemSeq=5365}{%
+% 研究生学位论文写作指南}》(限校内网络访问)、
+% 英文版《Guide to Thesis Writing for Graduate Students》、
+% 清华大学教务处颁发的《
+% \href{https://lib.tsinghua.edu.cn/dra/news/annoucement/7963}{%
+% 综合论文训练写作指南}》、
+% 外文系的《英语专业本科生综合论文训练》和
+% 清华大学《
% \href{http://postdoctor.tsinghua.edu.cn/info/czxz/1283}{%
-% 《编写“清华大学博士后研究报告”参考意见》}
+% 编写“清华大学博士后研究报告”参考意见}》
% 编写而成,旨在供清华大学毕业生撰写学位论文使用。
% \item 任何个人或组织以本模板为基础进行修改、扩展而生成的新的专用模板,请严格遵
% 守 \LaTeX{} Project Public License 协议。由于违犯协议而引起的任何纠纷争端均与
@@ -100,8 +101,8 @@
% \clearpage
%
% \section{模板介绍}
-% \thuthesis{} (\textbf{T}sing\textbf{h}ua \textbf{U}niversity \LaTeX{}
-% \textbf{Thesis} Template) 是为了帮助清华大学毕业生撰写毕业论文而编写
+% \thuthesis{}(\textbf{T}sing\textbf{h}ua \textbf{U}niversity \LaTeX{}
+% \textbf{Thesis} Template)是为了帮助清华大学毕业生撰写毕业论文而编写
% 的 \LaTeX{} 论文模板。
%
% 本文档将尽量完整的介绍模板的使用方法,如有不清楚之处,或者想提出改进建议,
@@ -318,47 +319,41 @@
% \documentclass[degree=master, degree-type=professional]{thuthesis}
% \end{latex}
%
-% \subsection{字体配置}
+% \subsubsection{字体配置}
% \label{sec:font-config}
-% 模板默认可以自动检测操作系统,并配置改平台上合适的字体,
-% 具体的配置策略如表~\ref{tab:font}。
+% \DescribeOption{fontset}
+% 模板默认会自动根据操作系统配置合适的字体,
+% 用户也可以通过 \option{fontset} 时指定使用预设的字库,如:
+% \begin{latex}
+% \documentclass[fontset=windows]{thuthesis}
+% \end{latex}
+% 允许的选项有 \option{windows}、\option{mac}、\option{ubuntu} 和 \option{fandol},
+% 具体使用的字体见表~\ref{tab:fontset}。
+% 用户也可以设置为 \option{none} 并自行配置字体。
+%
% \begin{table}[htb]
% \centering
-% \caption{\thuthesis{} 自动配置字体策略}
-% \label{tab:font}
-% \begin{tabular}{ccc}
+% \caption{\thuthesis{} 预设的字体}
+% \label{tab:fontset}
+% \begin{tabular}{cccc}
% \toprule
-% Windows & macOS & 其他 \\
+% \option{windows} & \option{mac} & \option{ubuntu} & \option{fandol} \\
% \midrule
-% Times New Roman & Times New Roman & TeX Gyre Termes \\
-% Arial & Arial & TeX Gyre Heros \\
-% Courier & Menlo & TeX Gyre Cursor \\
-% 中易宋体 & 华文宋体 & Fandol 宋体 \\
-% 中易黑体 & 华文黑体 & Fandol 黑体 \\
+% Times New Roman & Times New Roman & TeX Gyre Termes & TeX Gyre Termes \\
+% Arial & Arial & TeX Gyre Heros & TeX Gyre Heros \\
+% Courier & Menlo & TeX Gyre Cursor & TeX Gyre Cursor \\
+% 中易宋体 & 华文宋体 & 思源宋体 & Fandol 宋体 \\
+% 中易黑体 & 华文黑体 & 思源黑体 & Fandol 黑体 \\
% \bottomrule
% \end{tabular}
% \end{table}
%
-% 然而自动配置的字体只能保证编译通过,但是还存在一些问题:
-% \begin{enumerate}
-% \item 在其他平台上配置的 TeX Gyre 系列字体,虽然在风格上比较接近 Times 和 Arial,
-% 但是毕竟跟《写作指南》要求的字体不完全一致;
-% \item Fandol 字库的字形较少,常常出现缺字的情况;
-% \item 华文字库和 Fandol 字库虽然不违反《写作指南》的要求,
-% 但是其字形跟中易字库有所差别,这导致封面、标题的视觉效果与学校的 Word 示例不一致,
-% 可能被审查老师认为格式不符合要求。
-% \end{enumerate}
+% 需要注意,研究生院建议中文字体同 Word 模板一致。
+% 也就是说,用户在提交终版前应使用 Windows 平台的字体进行编译。
%
-% 所以建议在提交最终版前使用 Windows 平台的字体进行编译。
+% 关于字体的配置,
+% 详见 \pkg{fontspec}、\pkg{xeCJK}、\pkg{ctex} 等宏包的使用说明和代码。
%
-% 用户也可以在调用 \thuthesis{} 时手动指定使用的字库,如:
-%
-% \begin{latex}
-% \documentclass[fontset=windows]{thuthesis}
-% \end{latex}
-%
-% 允许的选项有 \option{windows}、\option{mac}、\option{fandol},详
-% 见 \pkg{ctex}、\pkg{xeCJK}、\pkg{fontspec} 等宏包的使用说明。
%
% \subsection{论文设置}
% 论文的设置可以通过统一命令 \cs{thusetup} 设置 \emph{key=value} 形式完成。
@@ -412,11 +407,27 @@
% 论文的一些部分(如英文摘要、本科生的外文调研报告)要求使用特定的语言,
% 模板已经进行配置,并在这些部分结束后自动恢复为主要语言。
%
-% 注意,本科生《写作指南》要求“本科生(含国外来华留学本科生)非外语专业论文统一要求
+% 注意,本科生《写作指南》要求“本科生(含国外来华留学本科生)非外语专业论文统一要求
% 用中文书写。”研究生《写作指南》要求“外国人来华留学生可以用英文撰写学位论文,但
% 须采用中文封面”,“除留学生外,学位论文一律须用汉语书写”,用户须提前与导师和院系
% 的审查教师协商使用何种语言书写论文。
%
+% \subsubsection{开题报告}
+% \DescribeOption{thesis-type}
+% 模板还支持博士生论文开题报告的格式,可以通过设置 \option{thesis-type=proposal} 得到。
+%
+% 开题报告与学位论文有两点不同:
+% \begin{enumerate}
+% \item 封面的信息和格式有区别,尤其是增加了一行“学号”信息,需要通过 \option{student-id} 填写;
+% \item 开题报告不含英文标题页。
+% \end{enumerate}
+% \begin{latex}
+% \thusetup{
+% thesis-type = proposal,
+% student-id = {2000310000},
+% }
+% \end{latex}
+%
% \subsection{封面信息}
% \label{sec:titlepage}
% 封面信息可以通过统一设置命令 \cs{thusetup} 设置 \emph{key=value} 形式完成;
@@ -433,27 +444,31 @@
%
% \subsubsection{申请学位名称}
% \label{sec:degree-name}
-% 学位的设置要复杂一些:
-%
-% \begin{longtable}{p{2cm}p{6cm}p{6cm}}
-% \toprule
-% 学位类型 & degree-name & degree-name* \\
-% \midrule
-% 学术型博士 & 需注明所属的学科门类,例如:
-% 哲学、经济学、法学、教育学、文学、历史学、理学、工学、农学、医学、
-% 军事学、管理学、艺术学
-% & Doctor of Philosophy \\
-% \midrule
-% 学术型硕士 & 同上
-% & 哲学、文学、历史学、法学、教育学、艺术学门类,公共管理学科
-% 填写“Master of Arts“,其它填写“Master of Science” \\
-% \midrule
-% 专业型研究生学位 & 专业学位的名称,例如:教育博士、工程硕士
-% & 专业学位的名称,例如:Doctor of Education, Master of Engineering \\
-% \midrule
-% 本科生 & - & - \\
-% \bottomrule
-% \end{longtable}
+% 学位名称的设置比较复杂,见表~\ref{tab:degree-name}。
+%
+% \begin{table}[h]
+% \caption{学位名称的要求}
+% \label{tab:degree-name}
+% \begin{tabular}{p{2cm}p{6cm}p{6cm}}
+% \toprule
+% 学位类型 & degree-name & degree-name* \\
+% \midrule
+% 学术型博士 & 需注明所属的学科门类,例如:
+% 哲学、经济学、法学、教育学、文学、历史学、理学、工学、农学、医学、
+% 军事学、管理学、艺术学
+% & Doctor of Philosophy \\
+% \midrule
+% 学术型硕士 & 同上
+% & 哲学、文学、历史学、法学、教育学、艺术学门类,公共管理学科
+% 填写“Master of Arts“,其它填写“Master of Science” \\
+% \midrule
+% 专业型研究生学位 & 专业学位的名称,例如:教育博士、工程硕士
+% & 专业学位的名称,例如:Doctor of Education, Master of Engineering \\
+% \midrule
+% 本科生 & - & - \\
+% \bottomrule
+% \end{tabular}
+% \end{table}
%
% \begin{latex}
% \thusetup{
@@ -495,13 +510,21 @@
% }
% \end{latex}
%
+% \subsubsection{学号}
+% 学号,仅用于博士生论文开题报告。
+% \begin{latex}
+% \thusetup{
+% student-id = {20000310000},
+% }
+% \end{latex}
+%
% \subsubsection{导师}
% \myentry{导师}
% 导师的姓名与职称之间以“,”(西文逗号,U+002C)隔开,下同。
% \begin{latex}
% \thusetup{
% supervisor = {导师姓名, 教授},
-% supervisor* = {Supervisor Name, Professor},
+% supervisor* = {Professor Supervisor Name},
% }
% \end{latex}
%
@@ -510,7 +533,7 @@
% \begin{latex}
% \thusetup{
% associate-supervisor = {副导师姓名, 副教授},
-% associate-supervisor* = {Assoc-Supervisor Name, Professor},
+% associate-supervisor* = {Professor Assoc-Supervisor Name},
% }
% \end{latex}
%
@@ -518,8 +541,8 @@
% 硕士生、本科生联合指导教师,博士生联合导师。
% \begin{latex}
% \thusetup{
-% joint-supervisor = {联合导师姓名, 教授},
-% joint-supervisor* = {Join-Supervisor Name, Professor},
+% co-supervisor = {联合导师姓名, 教授},
+% co-supervisor* = {Professor Join-Supervisor Name},
% }
% \end{latex}
%
@@ -727,35 +750,118 @@
% 见 \pkg{nomencl} 宏包的文档。
%
% \subsection{正文部分}
+% \subsubsection{图表编号}
+% \DescribeOption{figure-number-separator}
+% \DescribeOption{table-number-separator}
+% \DescribeOption{equation-number-separator}
+% 研究生要求图表和公式的编号使用“.”或“-”连接,模板默认使用句点“.”。
+% 用户也可以通过 \option{figure-number-separator}、\option{table-number-separator}
+% 等选项分别设置:
+% \begin{latex}
+% \thusetup{
+% figure-number-separator = {-},
+% table-number-separator = {-},
+% equation-number-separator = {-},
+% }
+% \end{latex}
+% \DescribeOption{number-separator}
+% 也可以使用 \option{number-separator} 同时设置图、表、公式三项的编号连接符,
+% 比如 |\thusetup{number-separator = -}|。
+%
+% 本科生要求“附录中图、表、公式的编号,应与正文中的编号区分开”,
+% 应理解为将章号改变为附录对应的大写字母编号,连接符不宜改变。
%
% \subsubsection{数学符号}
% \label{sec:math}
-% 数学符号应遵循 GB/T 3102.11—1993《物理科学和技术中使用的数学符号》
-% 模板中使用 \pkg{unicode-math} 宏包来配置数学符号,
-% 与 \LaTeX{} 默认的英美国家的符号习惯有所差异:
+% 中文论文的数学符号默认遵循 GB/T 3102.11—1993《物理科学和技术中使用的数学符号》。
+% 该标准参照采纳 ISO 31-11:1992,
+% 但是与 \TeX{} 默认的美国数学学会(AMS)的习惯有许多差异。
+% 这将在下文详细论述。
+%
+% \DescribeOption{math-style}
+% 用户可以通过设置 \option{math-style} 选择数学符号样式(可选:
+% \option{GB}(中文默认),\option{TeX}(英文默认)和 \option{ISO}),比如:
+% \begin{latex}
+% \thusetup{
+% math-style = ISO,
+% }
+% \end{latex}
+%
+% 用户也可以逐项修改数学样式。
% \newcommand\dif{\mathop{}\!\mathrm{d}}
% \begin{enumerate}
-% \item 大写希腊字母默认为斜体,如 \cs{Delta}:$\Delta$。
-% \item 有限增量符号 $\increment$(U+2206)应使用 \pkg{unicode-math} 宏包提供的
-% \cs{increment} 命令。
-% \item 向量、矩阵和张量要求粗斜体,应使用 \cs{symbf} 命令,
-% 如 \verb|\symbf{A}|、\verb|\symbf{\alpha}|。
-% \item 数学常数和特殊函数要求用正体,应使用 \cs{symup} 命令,
-% 如 $\symup{\pi} = 3.14\dots$; $\symup{e} = 2.718\dots$,
-% \item 微分号和积分号使用使用正体,比如 $\int f(x) \dif x$。
+% \item \DescribeOption{uppercase-greek}
+% 大写希腊字母的正/斜体,可选:\option{italic}、\option{upright}。
+% 有限增量符号 $\increment x$ 固定使用正体,推荐使用 \cs{increment} 表示。
+% \item \DescribeOption{less-than-or-equal}
+% 小于等于号和大于等于号的字形,可选:\option{slanted}、\option{horizontal}。
+% 这将控制 \cs{le}、\cs{ge}、\cs{leq} 和 \cs{geq} 的符号
+% 是“$\leqslant$、$\geqslant$”还是“$\leq$、$\geq$”。
+% \item \DescribeOption{integral}
+% 积分号的正/斜体,可选:\option{upright}、\option{slanted}。
+% 该选项需要字体的支持,目前仅限 \option{xits}、\option{stix}、
+% \option{libertinus} 和 \option{newcm}。参考下文关于数学字体的选择。
+% \item \DescribeOption{integral-limits}
+% 积分号上下限的位置,可选:\option{true}(在上下)、\option{false}(在右侧)。
+% 这个设置只影响行间公式,行内公式统一居右侧,不受影响。
+% \item \DescribeOption{partial}
+% 偏微分符号的正/斜体,可选:\option{upright}、\option{slanted}。
+% \item \DescribeOption{math-ellipsis}
+% 省略号 \cs{dots} 的样式,可选:\option{centered}(按照中文的习惯固定居中)、
+% \option{lower} 和 \option{AMS}(取决于前后符号的位置)。
+% 其他的省略号命令如 \cs{lots}、\cs{cdots} 则不受影响。
+% \end{enumerate}
+%
+% 如果数学符号选择国标样式 |math-style = GB|,相当于设置了
+% \begin{latex}
+% \thusetup{
+% uppercase-greek = italic,
+% less-than-or-equal = slanted,
+% integral = upright,
+% integral-limits = true,
+% partial = upright,
+% math-ellipsis = centered,
+% }
+% \end{latex}
+%
+% 另外,国标的数学样式与 AMS 还有一些差异无法统一设置,需要用户在写作时进行处理。
+% \begin{enumerate}
+% \item 数学常数和特殊函数名用正体,如 $\uppi = 3.14\dots$;$\symup{i}^2 = -1$;
+% $\symup{e} = \lim_{n \to \infty} \left( 1 + \frac{1}{n} \right)^n$。
+% \item 微分号使用正体,比如 $\dif y / \dif x$。
+% \item 向量、矩阵和张量用粗斜体(\cs{symbf}),如 $\symbf{x}$、$\symbf{\Sigma}$、$\symbfsf{T}$。
% \end{enumerate}
%
-% 关于数学符号更多的用法,参考
+% 需要注意,上述关于数学符号风格的设置在设置数学字体(\option{math-font})时才会生效。
+%
+% \DescribeOption{math-font}
+% 模板使用默认使用 XITS Math 作为数学字体。
+% 用户也可以使用 \option{math-font} 选项切换其他数学字体,可选:
+% \option{stix}(STIX Two Math)、
+% \option{libertinus}(Libertinus Math)、
+% \option{newcm}(New Computer Modern Math)、
+% \option{lm}(Latin Modern Math)。
+%
+% 其中 \option{lm} 和 \option{newcm} 的字形比较搭配 TeX 原生的 Computer Modern 字体,
+% 但与《指南》要求的西文字体 Times New Roman 并不搭配。
+% 可能会造成正文和公式中的数字字体不一致,需要谨慎使用。
+%
+% 以上字体都是 OpenType 格式的字体,需要配合
% \href{http://mirrors.ctan.org/macros/latex/contrib/unicode-math/unicode-math.pdf}{\pkg{unicode-math}}
-% 宏包的使用说明,
-% 全部数学符号命的令参考
+% 宏包使用。
+% 全部数学符号的命令参考
% \href{http://mirrors.ctan.org/macros/latex/contrib/unicode-math/unimath-symbols.pdf}{\pkg{unimath-symbols}}。
-%
% 注意,\pkg{unicode-math} 宏包与 \pkg{amsfonts}、\pkg{amssymb}、\pkg{bm}、
% \pkg{mathrsfs}、\pkg{upgreek} 等宏包\emph{不}兼容。
% 模板作了处理,用户可以直接使用这些宏包的命令,如 \cs{bm}、\cs{mathscr}、
% \cs{uppi}。
%
+% 另外,模板还为 `math-font` 提供了传统的 Type 1 字体 \option{newtx}。
+% 该选项会调用 \pkg{newtxmath} 宏包。
+% 但是,如果西文字体已经使用了 OpenType 的 Times New Roman,
+% 混用 Type 1 字体可能会导致问题,尤其是使用 \pkg{siunitx} 宏包时。
+% 该选项还处于测试阶段,需要谨慎使用。
+%
% \subsubsection{定理环境}
% \label{sec:theorem}
% \thuthesis{} 定义了常用的数学环境:
@@ -958,22 +1064,26 @@
%
% \subsubsection{声明}
% \DescribeMacro{\statement}
-% 如果使用声明扫描页,将可选参数指定为扫描后的 PDF 文件名,例如:
+% 直接使用 \cs{statement} 命令可以编译生成声明页。
+% 如果要插入扫描后的声明页,将可选参数指定为扫描后的 PDF 文件名,例如:
%
% \begin{latex}
% \statement[file=scan-statement.pdf]
% \end{latex}
%
-% 由于打印版和电子版有空白页的差别,声明的页码可能不同。
-% 所以编译声明页时默认不加页眉和页脚(\texttt{page-style=empty}),
-% 在签字后插入扫描页时再补上页眉和页脚,防止页码冲突。
+% 由于本科生打印版和电子版有空白页的差别,声明的页码可能不同。
+% 所以编译声明页时默认不加页脚(\texttt{page-style=empty}),
+% 在签字后插入扫描页时再补上页脚,防止页码冲突。
%
% 如果需要编译时也加页码(如直接对电子版进行签名而不是插入扫描页),
% 可以使用在 \cs{statement} 命令设置
% \begin{latex}
% \statement[page-style=plain]
% \end{latex}
-% 注意,插入扫描页总是会加页码,不受该选项控制。
+% 注意,本科生插入扫描页时总是会加页码,不受该选项控制。
+%
+% 研究生不存在空白页的问题,所以在编译声明页时总是会加上页眉和页脚,
+% 而在插入扫描页时则不再添加,不受 \option{page-style} 的控制。
%
% \subsubsection{附录}
%
@@ -1133,7 +1243,7 @@
% \begin{macrocode}
%<cls>\NeedsTeXFormat{LaTeX2e}[2017/04/15]
%<cls>\ProvidesClass{thuthesis}
-%<cls>[2020/10/14 7.1.0 Tsinghua University Thesis Template]
+%<cls>[2021/03/12 7.2.0 Tsinghua University Thesis Template]
% \end{macrocode}
%
% 报错
@@ -1189,7 +1299,7 @@
%<*cls>
\hyphenation{Thu-Thesis}
\def\thuthesis{ThuThesis}
-\def\version{7.1.0}
+\def\version{7.2.0}
\RequirePackage{kvdefinekeys}
\RequirePackage{kvsetkeys}
\RequirePackage{kvoptions}
@@ -1202,8 +1312,12 @@
% \begin{macro}{\thusetup}
% 提供一个 \cs{thusetup} 命令支持 \emph{key-value} 的方式来设置。
% \begin{macrocode}
+\let\thu@setup@hook\@empty
\newcommand\thusetup[1]{%
+ \let\thu@setup@hook\@empty
\kvsetkeys{thu}{#1}%
+ \thu@setup@hook
+ \thu@setup@hook
}
% \end{macrocode}
% \end{macro}
@@ -1331,6 +1445,14 @@
%
% \begin{macrocode}
\thu@define@key{
+ thesis-type = {
+ name = thesis@type,
+ choices = {
+ thesis,
+ proposal,
+ },
+ default = thesis,
+ },
degree = {
choices = {
bachelor,
@@ -1372,33 +1494,37 @@
%
% 字体
% \begin{macrocode}
+ system = {
+ choices = {
+ auto,
+ mac,
+ unix,
+ windows,
+ },
+ default = auto,
+ },
fontset = {
choices = {
+ auto,
windows,
mac,
ubuntu,
fandol,
none,
},
- default = none,
- },
- system = {
- choices = {
- mac,
- unix,
- windows,
- auto,
- },
default = auto,
},
font = {
choices = {
+ auto,
times,
termes,
+ stix,
xits,
libertinus,
+ newcm,
lm,
- auto,
+ newtx,
none,
},
default = auto,
@@ -1406,11 +1532,11 @@
cjk-font = {
name = cjk@font,
choices = {
+ auto,
windows,
mac,
noto,
fandol,
- auto,
none,
},
default = auto,
@@ -1418,13 +1544,65 @@
math-font = {
name = math@font,
choices = {
+ auto,
xits,
stix,
libertinus,
+ newcm,
lm,
+ newtx,
none,
},
- default = xits,
+ default = auto,
+ },
+ math-style = {
+ name = math@style,
+ choices = {
+ GB,
+ ISO,
+ TeX,
+ },
+ },
+ uppercase-greek = {
+ name = uppercase@greek,
+ choices = {
+ italic,
+ upright,
+ },
+ },
+ less-than-or-equal = {
+ name = leq,
+ choices = {
+ slanted,
+ horizontal,
+ },
+ },
+ integral = {
+ choices = {
+ upright,
+ slanted,
+ },
+ },
+ integral-limits = {
+ name = integral@limits,
+ choices = {
+ true,
+ false,
+ },
+ },
+ partial = {
+ choices = {
+ upright,
+ italic,
+ },
+ },
+ math-ellipsis = {
+ name = math@ellipsis,
+ choices = {
+ centered,
+ lower,
+ AMS,
+ },
},
% \end{macrocode}
%
@@ -1484,9 +1662,13 @@
\fi
% \end{macrocode}
%
+% \pkg{unicode-math} 和 \pkg{newtx} 都不需要 \pkg{fontspec} 设置数学字体。
+% \begin{macrocode}
+\PassOptionsToPackage{no-math}{fontspec}
+% \end{macrocode}
+%
% 使用 \pkg{ctexbook} 类,优于调用 \pkg{ctex} 宏包。
% \begin{macrocode}
-\PassOptionsToPackage{quiet}{fontspec}
\LoadClass[a4paper,UTF8,zihao=-4,scheme=plain,fontset=none]{ctexbook}[2017/04/01]
% \end{macrocode}
%
@@ -1524,11 +1706,6 @@
\RequirePackage{amsmath}
% \end{macrocode}
%
-% 使用 \pkg{unicode-math} 处理数学字体。
-% \begin{macrocode}
-\RequirePackage{unicode-math}
-% \end{macrocode}
-%
% 图形支持宏包。
% \begin{macrocode}
\RequirePackage{graphicx}
@@ -1602,11 +1779,23 @@
%
% 对冲突的宏包报错。
% \begin{macrocode}
-\newcommand\thu@package@conflict[2]{
- \AtBeginOfPackageFile*{#2}{
- \thu@error{The "#2" package is incompatible with required "#1"}
+\newcommand\thu@package@conflict[2]{%
+ \AtEndOfPackageFile*{#1}{%
+ \AtBeginOfPackageFile*{#2}{%
+ \thu@error{The "#2" package is incompatible with "#1"}%
+ }%
+ }%
}
-}
+\thu@package@conflict{biblatex}{bibunits}
+\thu@package@conflict{biblatex}{chapterbib}
+\thu@package@conflict{biblatex}{cite}
+\thu@package@conflict{biblatex}{multibib}
+\thu@package@conflict{biblatex}{natbib}
+
+\thu@package@conflict{bibunits}{biblatex}
+\thu@package@conflict{bibunits}{chapterbib}
+\thu@package@conflict{bibunits}{multibib}
+
\thu@package@conflict{unicode-math}{amscd}
\thu@package@conflict{unicode-math}{amsfonts}
\thu@package@conflict{unicode-math}{amssymb}
@@ -1615,9 +1804,18 @@
\thu@package@conflict{unicode-math}{eucal}
\thu@package@conflict{unicode-math}{eufrak}
\thu@package@conflict{unicode-math}{mathrsfs}
+\thu@package@conflict{unicode-math}{newtxmath}
+\thu@package@conflict{unicode-math}{upgreek}
+
+\thu@package@conflict{natbib}{biblatex}
+\thu@package@conflict{natbib}{cite}
+
+\thu@package@conflict{newtxmath}{amsfonts}
+\thu@package@conflict{newtxmath}{amssymb}
+\thu@package@conflict{newtxmath}{unicode-math}
+\thu@package@conflict{newtxmath}{upgreek}
% \end{macrocode}
%
-%
% \subsection{页面设置}
% \label{sec:layout}
%
@@ -1671,96 +1869,200 @@
\thu@option@hook{output}{\thu@set@geometry}
% \end{macrocode}
%
-% \subsection{主文档格式}
-% \label{sec:mainbody}
%
-% \subsubsection{Three matters}
-% \begin{macro}{\cleardoublepage}
-% 对于 \textsl{openright} 选项,必须保证章首页右开,且如果前章末页无内容须
-% 清空其页眉页脚。
+% \subsection{语言设置}
+%
+% 定义 \cs{thu@main@language},当在导言区修改 \option{language} 时,
+% 保存为论文的主要语言;
+% \cs{thu@reset@main@language} 则用于正文中恢复为主要语言。
% \begin{macrocode}
-\def\cleardoublepage{%
- \clearpage
- \if@twoside
- \ifthu@output@print
- \ifodd\c@page
+\thusetup{main-language=\thu@language}%
+\let\thu@main@language\thu@language
+\thu@option@hook{language}{%
+ \ifx\@begindocumenthook\@undefined\else
+ \thusetup{main-language=\thu@language}%
+ \let\thu@main@language\thu@language
+ \fi
+}
+\newcommand\thu@reset@main@language{%
+ \thusetup{language = \thu@main@language}%
+ \let\thu@language\thu@main@language
+}
+% \end{macrocode}
+%
+% 根据语言设置各章节的名称,只有在导言区设置 \option{degree} 和
+% \option{language} 时会修改,而在正文局部切换语言时则不变。
+% \begin{macrocode}
+\newcommand\thu@set@chapter@names{%
+ \ifthu@main@language@chinese
+ \def\thu@comments@name{指导教师学术评语}%
+ \def\bibname{参考文献}%
+ \def\appendixname{附录}%
+ \def\indexname{索引}%
+ \def\thu@resolution@name{答辩委员会决议书}%
+ \ifthu@degree@bachelor
+ \def\contentsname{目\qquad 录}%
+ \def\listfigurename{插图索引}%
+ \def\listtablename{表格索引}%
+ \def\thu@list@figure@table@name{插图和附表索引}%
+ \def\thu@list@algorithm@name{算法索引}%
+ \def\thu@acknowledgements@name{致\qquad 谢}%
+ \def\listequationname{公式索引}%
+ \def\thu@denotation@name{主要符号对照表}%
+ \def\thu@resume@name{在学期间参加课题的研究成果}%
+ \else
+ \def\listfigurename{插图清单}%
+ \def\listtablename{附表清单}%
+ \def\thu@list@figure@table@name{插图和附表清单}%
+ \def\thu@list@algorithm@name{算法清单}%
+ \def\listequationname{公式清单}%
+ \def\thu@acknowledgements@name{致\quad 谢}%
+ \ifthu@degree@graduate
+ \def\contentsname{目\quad 录}%
+ \def\thu@denotation@name{符号和缩略语说明}%
+ \def\thu@resume@name{个人简历、在学期间完成的相关学术成果}%
+ \else % degree = postdoc
+ \def\contentsname{目\qquad 次}%
+ \def\thu@denotation@name{符号表}%
+ \def\thu@resume@name{个人简历、发表的学术论文与科研成果}%
+ \fi
+ \fi
+ \else
+ \ifthu@main@language@english
+ \def\thu@comments@name{Comments from Thesis Supervisor}%
+ \def\thu@resolution@name{Resolution of Thesis Defense Committee}%
+ \def\indexname{Index}%
+ \ifthu@degree@bachelor
+ \def\contentsname{CONTENTS}%
+ \def\listfigurename{FIGURES}%
+ \def\listtablename{TABLES}%
+ \def\thu@list@figure@table@name{FIGURES AND TABLES}%
+ \def\thu@list@algorithm@name{ALGORITHMS}%
+ \def\listequationname{EQUATIONS}%
+ \def\thu@denotation@name{ABBREVIATIONS}%
+ \def\bibname{REFERENCES}%
+ \def\appendixname{APPENDIX}%
+ \def\thu@acknowledgements@name{ACKNOWLEDGEMENTS}%
+ \def\thu@resume@name{PUBLICATIONS}%
\else
- \thispagestyle{empty}%
- \hbox{}%
- \newpage
- \if@twocolumn
- \hbox{}\newpage
- \fi
+ \def\contentsname{Table of Contents}%
+ \def\listfigurename{List of Figures}%
+ \def\listtablename{List of Tables}%
+ \def\thu@list@figure@table@name{List of Figures and Tables}%
+ \def\thu@list@algorithm@name{List of Algorithms}%
+ \def\listequationname{List of Equations}%
+ \def\thu@denotation@name{List of Symbols and Acronyms}%
+ \def\bibname{References}%
+ \def\appendixname{Appendix}%
+ \def\thu@acknowledgements@name{Acknowledgements}%
+ \def\thu@resume@name{Resume}%
\fi
\fi
\fi
}
+\thu@set@chapter@names
+\thu@option@hook{degree}{\thu@set@chapter@names}
+\thu@option@hook{main-language}{\thu@set@chapter@names}
% \end{macrocode}
-% \end{macro}
%
-% \begin{macro}{\frontmatter}
-% \begin{macro}{\mainmatter}
-% \begin{macro}{\backmatter}
-% 我们的单面和双面模式与常规的不太一样。
+% 这部分名称在正文中局部地修改语言时会发生变化,比如英文摘要、
+% 本科生附录的阅读报告。
% \begin{macrocode}
-\renewcommand\frontmatter{%
- \cleardoublepage
- \@mainmatterfalse
- \pagenumbering{Roman}%
-}
-\renewcommand\mainmatter{%
- \cleardoublepage
- \@mainmattertrue
- \pagenumbering{arabic}%
-}
-\renewcommand\backmatter{%
- \if@openright
- \cleardoublepage
+\newcommand\thu@set@names{%
+ \ifthu@language@chinese
+ \ctexset{
+ figurename = 图,
+ tablename = 表,
+ }%
+ \def\thu@algorithm@name{算法}%
+ \def\thu@equation@name{公式}%
+ \def\thu@assumption@name{假设}%
+ \def\thu@definition@name{定义}%
+ \def\thu@proposition@name{命题}%
+ \def\thu@lemma@name{引理}%
+ \def\thu@theorem@name{定理}%
+ \def\thu@axiom@name{公理}%
+ \def\thu@corollary@name{推论}%
+ \def\thu@exercise@name{练习}%
+ \def\thu@example@name{例}%
+ \def\thu@remark@name{注释}%
+ \def\thu@problem@name{问题}%
+ \def\thu@conjecture@name{猜想}%
+ \def\thu@proof@name{证明}%
+ \def\thu@theorem@separator{:}%
\else
- \clearpage
+ \ifthu@language@english
+ \ctexset{
+ figurename = {Figure},
+ tablename = {Table},
+ }%
+ \def\thu@algorithm@name{Algorithm}%
+ \def\thu@equation@name{Equation}%
+ \def\thu@assumption@name{Assumption}%
+ \def\thu@definition@name{Definition}%
+ \def\thu@proposition@name{Proposition}%
+ \def\thu@lemma@name{Lemma}%
+ \def\thu@theorem@name{Theorem}%
+ \def\thu@axiom@name{Axiom}%
+ \def\thu@corollary@name{Corollary}%
+ \def\thu@exercise@name{Exercise}%
+ \def\thu@example@name{Example}%
+ \def\thu@remark@name{Remark}%
+ \def\thu@problem@name{Problem}%
+ \def\thu@conjecture@name{Conjecture}%
+ \def\thu@proof@name{Proof}%
+ \def\thu@theorem@separator{: }%
+ \fi
\fi
- \@mainmatterfalse
- \thusetup{toc-depth = 0}%
}
+\thu@set@names
+\thu@option@hook{language}{\thu@set@names}
% \end{macrocode}
-% \end{macro}
-% \end{macro}
-% \end{macro}
%
-% \subsubsection{字体}
-% \label{sec:font}
-% 使用 \pkg{fontspec} 配置字体。
+% 带圈数字和星号使用中文字体。
% \begin{macrocode}
-\ifthu@fontset@mac
- \thusetup{
- font = times,
- cjk-font = mac,
- }
-\else
- \ifthu@fontset@windows
- \thusetup{
- font = times,
- cjk-font = windows,
- }
+\xeCJKDeclareCharClass{CJK}{"2460 -> "2473}
+\xeCJKDeclareCharClass{CJK}{"2605}
+% \end{macrocode}
+%
+% \newcommand\unicodechar[1]{U+#1(\symbol{"#1})}
+% 由于 Unicode 的一些标点符号是中西文混用的:
+% \unicodechar{00B7}、
+% \unicodechar{2013}、
+% \unicodechar{2014}、
+% \unicodechar{2018}、
+% \unicodechar{2019}、
+% \unicodechar{201C}、
+% \unicodechar{201D}、
+% \unicodechar{2025}、
+% \unicodechar{2026}、
+% \unicodechar{2E3A},
+% 所以要根据语言设置正确的字体。
+% \footnote{\url{https://github.com/CTeX-org/ctex-kit/issues/389}}
+% 此外切换语言时,有一部分名称是需要被重新定义的。
+% \begin{macrocode}
+\newcommand\thu@set@punctuations{%
+ \ifthu@language@chinese
+ \xeCJKDeclareCharClass{FullLeft}{"2018, "201C}%
+ \xeCJKDeclareCharClass{FullRight}{
+ "00B7, "2019, "201D, "2013, "2014, "2025, "2026, "2E3A,
+ }%
\else
- \ifthu@fontset@fandol
- \thusetup{
- font = termes,
- cjk-font = fandol,
- }
- \else
- \ifthu@fontset@ubuntu
- \thusetup{
- font = termes,
- cjk-font = noto,
- }
- \fi
+ \ifthu@language@english
+ \xeCJKDeclareCharClass{HalfLeft}{"2018, "201C}%
+ \xeCJKDeclareCharClass{HalfRight}{
+ "00B7, "2019, "201D, "2013, "2014, "2025, "2026, "2E3A,
+ }%
\fi
\fi
-\fi
+}
+\thu@set@punctuations
+\thu@option@hook{language}{\thu@set@punctuations}
% \end{macrocode}
%
-% 检测系统
+% \subsection{字体}
+% \label{sec:font}
+% 检测系统。
% \begin{macrocode}
\ifthu@system@auto
\IfFileExists{/System/Library/Fonts/Menlo.ttc}{
@@ -1779,12 +2081,72 @@
\fi
% \end{macrocode}
%
-% XITS 字体于 2018-10-03 更改了字体的文件名,所以需要判断。
-% 原文件名为 \file{xits-regular.otf}、\file{xits-math.otf} 等,
-% 后改为 \file{XITS-Regular.otf}、\file{XITSMath-Regular.otf} 等。
+% 使用 \pkg{fontspec} 配置字体。
+% \begin{macrocode}
+\ifthu@fontset@auto
+ \ifthu@system@windows
+ \thusetup{fontset = windows}
+ \else
+ \IfFontExistsTF{SimSun}{
+ \thusetup{fontset = windows}
+ }{
+ \ifthu@system@mac
+ \thusetup{fontset = mac}
+ \else
+ \IfFontExistsTF{Noto Serif CJK SC}{
+ \thusetup{fontset = ubuntu}
+ }{
+ \thusetup{fontset = fandol}
+ }
+ \fi
+ }
+ \fi
+\fi
+% \end{macrocode}
+%
+% \subsubsection{西文字体}
+%
+% 《指南》要求西文字体使用 Times New Roman 和 Arial,
+% 但是在 Linux 下没有这两个字体,所以使用它们的克隆版 TeX Gyre Termes 和
+% TeX Gyre Heros。
+% \begin{macrocode}
+\ifthu@font@auto
+ \ifthu@fontset@windows
+ \thusetup{font=times}
+ \else
+ \ifthu@fontset@mac
+ \thusetup{font=times}
+ \else
+ \thusetup{font=termes}
+ \fi
+ \fi
+\fi
+% \end{macrocode}
+%
+% STIX 字体的文件名在 v2.10 2020-12-19 从
+% \file{STIXTwoText-Regular.otf}、\file{STIX2Math.otf} 分别改为
+% \file{STIXTwoText-Regular.otf}、\file{STIXTwoMath-Regular.otf}。
+% 需要进行判断。
%
-% Libertinus 字体同样。
+% XITS 字体的文件名在 v1.109 2018-09-30
+% 从 \file{xits-regular.otf}、\file{xits-math.otf} 分别改为
+% \file{XITS-Regular.otf}、\file{XITSMath-Regular.otf}。
+%
+% Libertinus 的文件名在 v6.7 2019-04-03 从小写改为驼峰式,
+% 在大小写敏感的平台上需要进行判断。
% \begin{macrocode}
+\let\thu@font@family@stix\@empty
+\newcommand\thu@set@stix@names{%
+ \ifx\thu@font@family@stix\@empty
+ \IfFontExistsTF{STIXTwoText-Regular.otf}{%
+ \gdef\thu@font@family@stix{STIXTwoText}%
+ \gdef\thu@font@name@stix@math{STIXTwoMath-Regular}%
+ }{%
+ \gdef\thu@font@family@stix{STIX2Text}%
+ \gdef\thu@font@name@stix@math{STIX2Math}%
+ }%
+ \fi
+}
\let\thu@font@family@xits\@empty
\newcommand\thu@set@xits@names{%
\ifx\thu@font@family@xits\@empty
@@ -1794,16 +2156,14 @@
\gdef\thu@font@style@xits@bf{Bold}%
\gdef\thu@font@style@xits@it{Italic}%
\gdef\thu@font@style@xits@bfit{BoldItalic}%
- \gdef\thu@font@name@xits@math@rm{XITSMath-Regular}%
- \gdef\thu@font@name@xits@math@bf{XITSMath-Bold}%
+ \gdef\thu@font@name@xits@math{XITSMath-Regular}%
}{%
\gdef\thu@font@family@xits{xits}%
\gdef\thu@font@style@xits@rm{regular}%
\gdef\thu@font@style@xits@bf{bold}%
\gdef\thu@font@style@xits@it{italic}%
\gdef\thu@font@style@xits@bfit{bolditalic}%
- \gdef\thu@font@name@xits@math@rm{xits-math}%
- \gdef\thu@font@name@xits@math@bf{xits-mathbold}%
+ \gdef\thu@font@name@xits@math{xits-math}%
}%
\fi
}
@@ -1831,18 +2191,8 @@
}
% \end{macrocode}
%
-% 《撰写手册》要求西文字体使用 Times New Roman 和 Arial,
-% 但是在 Linux 下没有这两个字体,所以使用它们的克隆版 TeX Gyre Termes 和
-% TeX Gyre Heros。
% \begin{macrocode}
-\ifthu@font@auto
- \ifthu@system@unix
- \thusetup{font=termes}
- \else
- \thusetup{font=times}
- \fi
-\fi
-\newcommand\thu@load@font@times{%
+\newcommand\thu@set@font@times{%
\setmainfont{Times New Roman}%
\setsansfont{Arial}%
\ifthu@system@mac
@@ -1851,7 +2201,7 @@
\setmonofont{Courier New}[Scale = MatchLowercase]%
\fi
}
-\newcommand\thu@load@font@termes{%
+\newcommand\thu@set@font@termes{%
\setmainfont{texgyretermes}[
Extension = .otf,
UprightFont = *-regular,
@@ -1859,9 +2209,9 @@
ItalicFont = *-italic,
BoldItalicFont = *-bolditalic,
]%
- \thu@load@texgyre@sans@mono
+ \thu@set@texgyre@sans@mono
}
-\newcommand\thu@load@texgyre@sans@mono{%
+\newcommand\thu@set@texgyre@sans@mono{%
\setsansfont{texgyreheros}[
Extension = .otf,
UprightFont = *-regular,
@@ -1878,7 +2228,18 @@
Ligatures = CommonOff,
]%
}
-\newcommand\thu@load@font@xits{%
+\newcommand\thu@set@font@stix{%
+ \thu@set@stix@names
+ \setmainfont{\thu@font@family@stix}[
+ Extension = .otf,
+ UprightFont = *-Regular,
+ BoldFont = *-Bold,
+ ItalicFont = *-Italic,
+ BoldItalicFont = *-BoldItalic,
+ ]%
+ \thu@set@texgyre@sans@mono
+}
+\newcommand\thu@set@font@xits{%
\thu@set@xits@names
\setmainfont{\thu@font@family@xits}[
Extension = .otf,
@@ -1887,9 +2248,9 @@
ItalicFont = *-\thu@font@style@xits@it,
BoldItalicFont = *-\thu@font@style@xits@bfit,
]%
- \thu@load@texgyre@sans@mono
+ \thu@set@texgyre@sans@mono
}
-\newcommand\thu@load@font@libertinus{%
+\newcommand\thu@set@font@libertinus{%
\thu@set@libertinus@names
\setmainfont{\thu@font@family@libertinus@serif}[
Extension = .otf,
@@ -1912,7 +2273,30 @@
BoldItalicFont = *-boldoblique,
]%
}
-\@namedef{thu@load@font@lm}{%
+\newcommand\thu@set@font@newcm{%
+ \setmathrm{NewCM10}[
+ Extension = .otf,
+ UprightFont = *-Book,
+ BoldFont = *-Bold,
+ ItalicFont = *-BookItalic,
+ BoldItalicFont = *-BoldItalic,
+ ]%
+ \setmathsf{NewCMSans10}[
+ Extension = .otf,
+ UprightFont = *-Book,
+ BoldFont = *-Bold,
+ ItalicFont = *-BookOblique,
+ BoldItalicFont = *-BoldOblique,
+ ]%
+ \setmathtt{NewCMMono10}[
+ Extension = .otf,
+ UprightFont = *-Book,
+ ItalicFont = *-BookItalic,
+ BoldFont = *-Bold,
+ BoldItalicFont = *-BoldOblique,
+ ]%
+}
+\newcommand\thu@set@font@lm{%
\setmainfont{lmroman10}[
Extension = .otf,
UprightFont = *-regular,
@@ -1935,77 +2319,36 @@
BoldItalicFont = *-boldoblique,
]%
}
-\newcommand\thu@load@font{%
- \@nameuse{thu@load@font@\thu@font}%
-}
-\thu@load@font
-\thu@option@hook{font}{\thu@load@font}
-% \end{macrocode}
-%
-% 使用 \pkg{unicode-math} 配置数学字体
-% \begin{macrocode}
-\unimathsetup{
- math-style = ISO,
- bold-style = ISO,
- nabla = upright,
- partial = upright,
-}
-\newcommand\thu@load@math@font@xits{%
- \thu@set@xits@names
- \setmathfont{\thu@font@name@xits@math@rm}[
- Extension = .otf,
- BoldFont = \thu@font@name@xits@math@bf,
- StylisticSet = 8,
- ]%
- \setmathfont{\thu@font@name@xits@math@rm}[
- Extension = .otf,
- StylisticSet = 1,
- range = {cal,bfcal},
- ]%
-}
-\newcommand\thu@load@math@font@stix{%
- \setmathfont{STIX2Math}[
- Extension = .otf,
- StylisticSet = 8,
- ]%
- \setmathfont{STIX2Math}[
- Extension = .otf,
- StylisticSet = 1,
- range = {cal,bfcal},
- ]%
-}
-\newcommand\thu@load@math@font@libertinus{%
- \thu@set@libertinus@names
- \setmathfont{\thu@font@name@libertinus@math .otf}%
+\newcommand\thu@set@font@newtx{%
+ \RequirePackage{newtxtext}%
}
-\newcommand\thu@load@math@font@lm{%
- \setmathfont{latinmodern-math.otf}%
+\newcommand\thu@set@font{%
+ \@nameuse{thu@set@font@\thu@font}%
}
-\newcommand\thu@load@math@font{%
- \@nameuse{thu@load@math@font@\thu@math@font}
-}
-\thu@load@math@font
-\thu@option@hook{math-font}{\thu@load@math@font}
+\thu@set@font
+\thu@option@hook{font}{\thu@set@font}
% \end{macrocode}
%
-% 中文字体
+% \subsubsection{中文字体}
+%
% \begin{macrocode}
\ifthu@cjk@font@auto
- \ifthu@system@mac
+ \ifthu@fontset@mac
\thusetup{cjk-font = mac}
\else
- \ifthu@system@windows
+ \ifthu@fontset@windows
\thusetup{cjk-font = windows}
\else
- \IfFontExistsTF{Noto Serif CJK SC}{
+ \ifthu@fontset@ubuntu
\thusetup{cjk-font = noto}
- }{
+ \else
\thusetup{cjk-font = fandol}
- }
+ \fi
\fi
\fi
\fi
-\newcommand\thu@load@cjk@font@windows{%
+\newcommand\thu@set@cjk@font@windows{%
+ \defaultCJKfontfeatures{Script=CJK}%
\xeCJKsetup{EmboldenFactor=3}%
\setCJKmainfont{SimSun}[
AutoFakeBold = true,
@@ -2018,7 +2361,8 @@
\setCJKfamilyfont{zhkai}{KaiTi}%
\setCJKfamilyfont{zhfs}{FangSong}%
}
-\newcommand\thu@load@cjk@font@mac{%
+\newcommand\thu@set@cjk@font@mac{%
+ \defaultCJKfontfeatures{}%
\setCJKmainfont{Songti SC}[
UprightFont = * Light,
BoldFont = * Bold,
@@ -2047,34 +2391,42 @@
%
% 注意 Noto CJK 的 regular 字重名字不带“Regular”。
% \begin{macrocode}
-\newcommand\thu@load@cjk@font@noto{%
+\newcommand\thu@set@cjk@font@noto{%
+ \defaultCJKfontfeatures{}%
\setCJKmainfont{Noto Serif CJK SC}[
UprightFont = * Light,
BoldFont = * Bold,
ItalicFont = FandolKai-Regular,
ItalicFeatures = {Extension = .otf},
+ Script = CJK,
]%
\setCJKsansfont{Noto Sans CJK SC}[
- BoldFont = * Medium,
+ BoldFont = * Medium,
+ Script = CJK,
+ ]%
+ \setCJKmonofont{Noto Sans Mono CJK SC}[
+ Script = CJK,
]%
- \setCJKmonofont{Noto Sans Mono CJK SC}%
\setCJKfamilyfont{zhsong}{Noto Serif CJK SC}[
- UprightFont = * Light,
- UprightFont = * Bold,
+ UprightFont = * Light,
+ UprightFont = * Bold,
+ Script = CJK,
]%
\setCJKfamilyfont{zhhei}{Noto Sans CJK SC}[
- BoldFont = * Medium,
+ BoldFont = * Medium,
+ Script = CJK,
]%
\setCJKfamilyfont{zhfs}{FandolFang}[
- Extension = .otf,
- UprightFont = *-Regular,
+ Extension = .otf,
+ UprightFont = *-Regular,
]%
\setCJKfamilyfont{zhkai}{FandolKai}[
- Extension = .otf,
- UprightFont = *-Regular,
+ Extension = .otf,
+ UprightFont = *-Regular,
]%
}
-\newcommand\thu@load@cjk@font@fandol{%
+\newcommand\thu@set@cjk@font@fandol{%
+ \defaultCJKfontfeatures{}%
\setCJKmainfont{FandolSong}[
Extension = .otf,
UprightFont = *-Regular,
@@ -2115,15 +2467,366 @@
\providecommand\fangsong{\CJKfamily{zhfs}}
\providecommand\kaishu{\CJKfamily{zhkai}}
\fi
-\newcommand\thu@load@cjk@font{%
- \@nameuse{thu@load@cjk@font@\thu@cjk@font}%
+\newcommand\thu@set@cjk@font{%
+ \@nameuse{thu@set@cjk@font@\thu@cjk@font}%
+}
+\thu@set@cjk@font
+\thu@option@hook{cjk-font}{\thu@set@cjk@font}
+% \end{macrocode}
+%
+% \subsubsection{数学字体}
+%
+% 使用 \pkg{unicode-math} 配置数学符号格式。
+% \begin{macrocode}
+\newcommand\thu@set@math@style{%
+ \ifthu@math@style@TeX
+ \thusetup{
+ uppercase-greek = upright,
+ less-than-or-equal = horizontal,
+ integral = slanted,
+ integral-limits = false,
+ partial = italic,
+ math-ellipsis = AMS,
+ }%
+ \else
+ \thusetup{
+ uppercase-greek = italic,
+ integral = upright,
+ integral-limits = true,
+ partial = upright,
+ }%
+ \ifthu@math@style@ISO
+ \thusetup{
+ less-than-or-equal = horizontal,
+ math-ellipsis = lower,
+ }%
+ \else
+ \ifthu@math@style@GB
+ \thusetup{
+ less-than-or-equal = slanted,
+ math-ellipsis = centered,
+ }%
+ \fi
+ \fi
+ \fi
+}
+\ifthu@main@language@chinese
+ \thusetup{math-style=GB}%
+\else
+ \thusetup{math-style=TeX}%
+\fi
+\thu@set@math@style
+\thu@option@hook{math-style}{\thu@set@math@style}
+\thu@option@hook{main-language}{%
+ \ifthu@main@language@chinese
+ \thusetup{math-style=GB}%
+ \else
+ \thusetup{math-style=TeX}%
+ \fi
+}
+% \end{macrocode}
+%
+% 针对 \pkg{unicode-math} 逐项配置数学符号。
+% \begin{macrocode}
+\newcommand\thu@set@unimath@leq{%
+ \ifthu@leq@horizontal
+ \ifx\@begindocumenthook\@undefined
+ \let\le\thu@save@leq
+ \let\ge\thu@save@geq
+ \let\leq\thu@save@leq
+ \let\geq\thu@save@geq
+ \else
+ \AtBeginDocument{%
+ \let\le\thu@save@leq
+ \let\ge\thu@save@geq
+ \let\leq\thu@save@leq
+ \let\geq\thu@save@geq
+ }%
+ \fi
+ \else
+ \ifthu@leq@slanted
+ \ifx\@begindocumenthook\@undefined
+ \let\le\leqslant
+ \let\ge\geqslant
+ \let\leq\leqslant
+ \let\geq\geqslant
+ \else
+ \AtBeginDocument{%
+ \let\le\leqslant
+ \let\ge\geqslant
+ \let\leq\leqslant
+ \let\geq\geqslant
+ }%
+ \fi
+ \fi
+ \fi
+}
+\newcommand\thu@set@unimath@integral@limits{%
+ \ifthu@integral@limits@true
+ \removenolimits{%
+ \int\iint\iiint\iiiint\oint\oiint\oiiint
+ \intclockwise\varointclockwise\ointctrclockwise\sumint
+ \intbar\intBar\fint\cirfnint\awint\rppolint
+ \scpolint\npolint\pointint\sqint\intlarhk\intx
+ \intcap\intcup\upint\lowint
+ }%
+ \else
+ \addnolimits{%
+ \int\iint\iiint\iiiint\oint\oiint\oiiint
+ \intclockwise\varointclockwise\ointctrclockwise\sumint
+ \intbar\intBar\fint\cirfnint\awint\rppolint
+ \scpolint\npolint\pointint\sqint\intlarhk\intx
+ \intcap\intcup\upint\lowint
+ }%
+ \fi
+}
+\newcommand\thu@set@unimath@ellipsis{%
+ \ifthu@math@ellipsis@centered
+ \DeclareRobustCommand\mathellipsis{\mathinner{\unicodecdots}}%
+ \else
+ \DeclareRobustCommand\mathellipsis{\mathinner{\unicodeellipsis}}%
+ \fi
+}
+\newcommand\thu@set@unimath@style{%
+ \ifthu@uppercase@greek@upright
+ \unimathsetup{math-style = TeX}%
+ \else
+ \ifthu@uppercase@greek@italic
+ \unimathsetup{math-style = ISO}%
+ \fi
+ \fi
+ \ifthu@math@style@TeX
+ \unimathsetup{bold-style = TeX}%
+ \else
+ \unimathsetup{bold-style = ISO}%
+ \fi
+ \thu@set@unimath@leq
+ \thu@set@unimath@integral@limits
+ \ifthu@partial@upright
+ \unimathsetup{partial = upright}%
+ \else
+ \ifthu@partial@italic
+ \unimathsetup{partial = italic}%
+ \fi
+ \fi
+ \thu@set@unimath@ellipsis
+}
+% \end{macrocode}
+%
+% \begin{macrocode}
+\newcommand\thu@qed{\rule{1ex}{1ex}}
+\newcommand\thu@load@unimath{%
+ \@ifpackageloaded{unicode-math}{}{%
+ \RequirePackage{unicode-math}%
+ \AtBeginDocument{%
+ \let\thu@save@leq\leq
+ \let\thu@save@geq\geq
+ }%
+% \end{macrocode}
+%
+% 兼容旧的粗体命令:\pkg{bm} 的 \cs{bm} 和 \pkg{amsmath} 的 \cs{boldsymbol}。
+% \begin{macrocode}
+ \DeclareRobustCommand\bm[1]{{\symbfit{##1}}}%
+ \DeclareRobustCommand\boldsymbol[1]{{\symbfit{##1}}}%
+% \end{macrocode}
+%
+% 兼容 \pkg{amsfonts} 和 \pkg{amssymb} 中的一些命令。
+% \begin{macrocode}
+ \newcommand\square{\mdlgwhtsquare}%
+ \newcommand\blacksquare{\mdlgblksquare}%
+ \AtBeginDocument{%
+ \renewcommand\checkmark{\ensuremath{✓}}%
+ }%
+% \end{macrocode}
+%
+% 兼容 \pkg{amsthm} 的 \cs{qedsymbol}。
+% \begin{macrocode}
+ \renewcommand\thu@qed{\ensuremath{\QED}}%
+ }%
+}
+% \end{macrocode}
+%
+% \begin{macrocode}
+\newcommand\thu@xits@integral@stylistic@set{%
+ \ifthu@integral@upright
+ 8%
+ \fi
+}
+\newcommand\thu@set@math@font@xits{%
+ \thu@set@xits@names
+ \setmathfont{\thu@font@name@xits@math}[
+ Extension = .otf,
+ StylisticSet = \thu@xits@integral@stylistic@set,
+ ]%
+ \setmathfont{\thu@font@name@xits@math}[
+ Extension = .otf,
+ StylisticSet = 1,
+ range = {cal,bfcal},
+ ]%
+}
+\newcommand\thu@set@math@font@stix{%
+ \thu@set@stix@names
+ \setmathfont{\thu@font@name@stix@math}[
+ Extension = .otf,
+ StylisticSet = \thu@xits@integral@stylistic@set,
+ ]%
+ \setmathfont{\thu@font@name@stix@math}[
+ Extension = .otf,
+ StylisticSet = 1,
+ range = {scr,bfscr},
+ ]%
+}
+\newcommand\thu@libertinus@integral@stylistic@set{%
+ \ifthu@integral@italic
+ 8%
+ \fi
+}
+\newcommand\thu@set@math@font@libertinus{%
+ \thu@set@libertinus@names
+ \setmathfont{\thu@font@name@libertinus@math .otf}%
}
-\thu@load@cjk@font
-\thu@option@hook{cjk-font}{\thu@load@cjk@font}
+\newcommand\thu@set@math@font@lm{%
+ \setmathfont{latinmodern-math}[Extension=.otf]%
+ \setmathrm{lmroman10}[
+ Extension = .otf,
+ UprightFont = *-regular,
+ BoldFont = *-bold,
+ ItalicFont = *-italic,
+ BoldItalicFont = *-bolditalic,
+ ]%
+ \setmathsf{lmsans10}[
+ Extension = .otf,
+ UprightFont = *-regular,
+ BoldFont = *-bold,
+ ItalicFont = *-oblique,
+ BoldItalicFont = *-boldoblique,
+ ]%
+ \setmathtt{lmmonolt10}[
+ Extension = .otf,
+ UprightFont = *-regular,
+ BoldFont = *-bold,
+ ItalicFont = *-oblique,
+ BoldItalicFont = *-boldoblique,
+ ]%
+}
+\newcommand\thu@newcm@integral@stylistic@set{%
+ \ifthu@integral@upright
+ 2%
+ \fi
+}
+\newcommand\thu@set@math@font@newcm{%
+ \setmathfont{NewCMMath-Book}[
+ Extension = .otf,
+ StylisticSet = \thu@newcm@integral@stylistic@set,
+ ]%
+ \setmathfont{NewCMMath-Book}[
+ Extension = .otf,
+ StylisticSet = 1,
+ range = {scr,bfscr},
+ ]%
+ \setmathrm{NewCM10}[
+ Extension = .otf,
+ UprightFont = *-Book,
+ BoldFont = *-Bold,
+ ItalicFont = *-BookItalic,
+ BoldItalicFont = *-BoldItalic,
+ ]%
+ \setmathsf{NewCMSans10}[
+ Extension = .otf,
+ UprightFont = *-Book,
+ BoldFont = *-Bold,
+ ItalicFont = *-BookOblique,
+ BoldItalicFont = *-BoldOblique,
+ ]%
+ \setmathtt{NewCMMono10}[
+ Extension = .otf,
+ UprightFont = *-Book,
+ ItalicFont = *-BookItalic,
+ BoldFont = *-Bold,
+ BoldItalicFont = *-BoldOblique,
+ ]%
+}
+% \end{macrocode}
+%
+% \begin{macrocode}
+\newcommand\thu@set@math@font@newtx{%
+ \ifthu@font@newtx\else
+ \let\thu@save@encodingdefault\encodingdefault
+ \let\thu@save@rmdefault\rmdefault
+ \let\thu@save@sfdefault\sfdefault
+ \let\thu@save@ttdefault\ttdefault
+ \RequirePackage[T1]{fontenc}%
+ \renewcommand{\rmdefault}{ntxtlf}%
+ \renewcommand{\sfdefault}{qhv}%
+ \renewcommand{\ttdefault}{ntxtt}%
+ \fi
+ \ifthu@uppercase@greek@italic
+ \PassOptionsToPackage{slantedGreek}{newtxmath}%
+ \fi
+ \ifthu@integral@upright
+ \PassOptionsToPackage{upint}{newtxmath}%
+ \fi
+ \RequirePackage{newtxmath}
+ \let\thu@save@leq\leq
+ \let\thu@save@geq\geq
+ \ifthu@leq@slanted
+ \let\le\leqslant
+ \let\ge\geqslant
+ \let\leq\leqslant
+ \let\geq\geqslant
+ \fi
+ \ifthu@integral@limits@true
+ \let\ilimits@\displaylimits
+ \fi
+ \let\thu@save@partial\partial
+ \ifthu@partial@upright
+ \let\partial\uppartial
+ \fi
+ \ifthu@math@ellipsis@centered
+ \DeclareRobustCommand\mathellipsis{\mathinner{\cdotp\cdotp\cdotp}}%
+ \else
+ \DeclareRobustCommand\mathellipsis{\mathinner{\ldotp\ldotp\ldotp}}%
+ \fi
+ \RequirePackage{bm}%
+ \ifthu@font@newtx\else
+ \let\encodingdefault\thu@save@encodingdefault
+ \let\rmdefault\thu@save@rmdefault
+ \let\sfdefault\thu@save@sfdefault
+ \let\ttdefault\thu@save@ttdefault
+ \fi
+ \DeclareRobustCommand\symup[1]{{\mathrm{##1}}}%
+ \DeclareRobustCommand\symbf[1]{{\bm{##1}}}%
+ \let\increment\upDelta%
+ \renewcommand\thu@qed{\openbox}%
+}
+% \end{macrocode}
+%
+% \begin{macrocode}
+\newcommand\thu@set@math@font{%
+ \ifthu@math@font@none\else
+ \ifthu@math@font@newtx
+ \thu@set@math@font@newtx
+ \else
+ \thu@load@unimath
+ \thu@set@unimath@style
+ \@nameuse{thu@set@math@font@\thu@math@font}%
+ \fi
+ \fi
+}
+\thu@option@hook{math-font}{\g@addto@macro\thu@setup@hook{\thu@set@math@font}}
+\newcommand\thu@set@math@font@auto{%
+ \ifthu@math@font@auto
+ \thusetup{math-font=xits}%
+ \fi
+}
+\AtBeginOfPackageFile*{siunitx}{\thu@set@math@font@auto}
+\AtEndPreamble{\thu@set@math@font@auto}
% \end{macrocode}
%
+% \subsubsection{字号}
+%
% \begin{macro}{\normalsize}
-% 正文小四号 (12bp) 字,行距为固定值 20 bp。
+% 正文小四号(12bp)字,行距为固定值 20 bp。
% 其他字号的行距按照相同的比例设置。
%
% 表达式行的行距为单倍行距,段前空 6 磅,段后空 6 磅。
@@ -2228,196 +2931,61 @@
% \end{macrocode}
%
%
-% \subsubsection{语言设置}
-%
-% 定义 \cs{thu@main@language},当在导言区修改 \option{language} 时,
-% 保存为论文的主要语言;
-% \cs{thu@reset@main@language} 则用于正文中恢复为主要语言。
-% \begin{macrocode}
-\thusetup{main-language=\thu@language}%
-\let\thu@main@language\thu@language
-\thu@option@hook{language}{%
- \ifx\@begindocumenthook\@undefined\else
- \thusetup{main-language=\thu@language}%
- \let\thu@main@language\thu@language
- \fi
-}
-\newcommand\thu@reset@main@language{%
- \thusetup{language = \thu@main@language}%
- \let\thu@language\thu@main@language
-}
-% \end{macrocode}
+% \subsection{主文档格式}
+% \label{sec:mainbody}
%
-% 根据语言设置各章节的名称,只有在导言区设置 \option{degree} 和
-% \option{language} 时会修改,而在正文局部切换语言时则不变。
+% \subsubsection{Three matters}
+% \begin{macro}{\cleardoublepage}
+% 对于 \textsl{openright} 选项,必须保证章首页右开,且如果前章末页无内容须
+% 清空其页眉页脚。
% \begin{macrocode}
-\newcommand\thu@set@chapter@names{%
- \ifthu@main@language@chinese
- \ctexset{
- chapter/name = {第,章},
- }%
- \def\bibname{参考文献}%
- \def\appendixname{附录}%
- \def\indexname{索引}%
- \def\thu@acknowledgements@name{致\quad 谢}%
- \ifthu@degree@bachelor
- \def\contentsname{目\quad 录}%
- \def\listfigurename{插图索引}%
- \def\listtablename{表格索引}%
- \def\thu@list@figure@table@name{插图和附表索引}%
- \def\thu@list@algorithm@name{算法索引}%
- \def\listequationname{公式索引}%
- \def\thu@denotation@name{主要符号对照表}%
- \def\thu@resume@name{在学期间参加课题的研究成果}%
- \else
- \def\listfigurename{插图清单}%
- \def\listtablename{附表清单}%
- \def\thu@list@figure@table@name{插图和附表清单}%
- \def\thu@list@algorithm@name{算法清单}%
- \def\listequationname{公式清单}%
- \ifthu@degree@graduate
- \def\contentsname{目\quad 录}%
- \def\thu@denotation@name{符号和缩略语说明}%
- \def\thu@resume@name{个人简历、在学期间完成的相关学术成果}%
- \else % degree = postdoc
- \def\contentsname{目\qquad 次}%
- \def\thu@denotation@name{符号表}%
- \def\thu@resume@name{个人简历、发表的学术论文与科研成果}%
- \fi
- \fi
- \else
- \ifthu@main@language@english
- \ctexset{
- chapter/name = \chaptername\space,
- }%
- \def\indexname{Index}%
- \ifthu@degree@bachelor
- \def\contentsname{CONTENTS}%
- \def\listfigurename{FIGURES}%
- \def\listtablename{TABLES}%
- \def\thu@list@figure@table@name{FIGURES AND TABLES}%
- \def\thu@list@algorithm@name{ALGORITHMS}%
- \def\listequationname{EQUATIONS}%
- \def\thu@denotation@name{ABBREVIATIONS}%
- \def\bibname{REFERENCES}%
- \def\appendixname{APPENDIX}%
- \def\thu@acknowledgements@name{ACKNOWLEDGEMENTS}%
- \def\thu@resume@name{PUBLICATIONS}%
+\def\cleardoublepage{%
+ \clearpage
+ \if@twoside
+ \ifthu@output@print
+ \ifodd\c@page
\else
- \def\contentsname{Contents}%
- \def\listfigurename{List of Figures}%
- \def\listtablename{List of Tables}%
- \def\thu@list@figure@table@name{List of Figures and Tables}%
- \def\thu@list@algorithm@name{List of Algorithms}%
- \def\listequationname{List of Equations}%
- \def\thu@denotation@name{Nomenclature}%
- \def\bibname{Bibliography}%
- \def\appendixname{Appendix}%
- \def\thu@acknowledgements@name{Acknowledgements}%
- \def\thu@resume@name{Resume and Academic Achievements}%
+ \thispagestyle{empty}%
+ \hbox{}%
+ \newpage
+ \if@twocolumn
+ \hbox{}\newpage
+ \fi
\fi
\fi
\fi
}
-\thu@set@chapter@names
-\thu@option@hook{degree}{\thu@set@chapter@names}
-\thu@option@hook{main-language}{\thu@set@chapter@names}
% \end{macrocode}
+% \end{macro}
%
-% 这部分名称在正文中局部地修改语言时会发生变化,比如英文摘要、
-% 本科生附录的阅读报告。
+% \begin{macro}{\frontmatter}
+% \begin{macro}{\mainmatter}
+% \begin{macro}{\backmatter}
+% 我们的单面和双面模式与常规的不太一样。
% \begin{macrocode}
-\newcommand\thu@set@names{%
- \ifthu@language@chinese
- \ctexset{
- figurename = 图,
- tablename = 表,
- }%
- \def\thu@algorithm@name{算法}%
- \def\thu@equation@name{公式}%
- \def\thu@assumption@name{假设}%
- \def\thu@definition@name{定义}%
- \def\thu@proposition@name{命题}%
- \def\thu@lemma@name{引理}%
- \def\thu@theorem@name{定理}%
- \def\thu@axiom@name{公理}%
- \def\thu@corollary@name{推论}%
- \def\thu@exercise@name{练习}%
- \def\thu@example@name{例}%
- \def\thu@remark@name{注释}%
- \def\thu@problem@name{问题}%
- \def\thu@conjecture@name{猜想}%
- \def\thu@proof@name{证明}%
- \def\thu@theorem@separator{:}%
- \else
- \ifthu@language@english
- \ctexset{
- figurename = {Figure},
- tablename = {Table},
- }%
- \def\thu@algorithm@name{Algorithm}%
- \def\thu@equation@name{Equation}%
- \def\thu@assumption@name{Assumption}%
- \def\thu@definition@name{Definition}%
- \def\thu@proposition@name{Proposition}%
- \def\thu@lemma@name{Lemma}%
- \def\thu@theorem@name{Theorem}%
- \def\thu@axiom@name{Axiom}%
- \def\thu@corollary@name{Corollary}%
- \def\thu@exercise@name{Exercise}%
- \def\thu@example@name{Example}%
- \def\thu@remark@name{Remark}%
- \def\thu@problem@name{Problem}%
- \def\thu@conjecture@name{Conjecture}%
- \def\thu@proof@name{Proof}%
- \def\thu@theorem@separator{: }%
- \fi
- \fi
+\renewcommand\frontmatter{%
+ \cleardoublepage
+ \@mainmatterfalse
+ \pagenumbering{Roman}%
}
-\thu@set@names
-\thu@option@hook{language}{\thu@set@names}
-% \end{macrocode}
-%
-% 带圈数字和星号使用中文字体。
-% \begin{macrocode}
-\xeCJKDeclareCharClass{CJK}{"2460 -> "2473}
-\xeCJKDeclareCharClass{CJK}{"2605}
-% \end{macrocode}
-%
-% \newcommand\unicodechar[1]{U+#1(\symbol{"#1})}
-% 由于 Unicode 的一些标点符号是中西文混用的:
-% \unicodechar{00B7}、
-% \unicodechar{2013}、
-% \unicodechar{2014}、
-% \unicodechar{2018}、
-% \unicodechar{2019}、
-% \unicodechar{201C}、
-% \unicodechar{201D}、
-% \unicodechar{2025}、
-% \unicodechar{2026}、
-% \unicodechar{2E3A},
-% 所以要根据语言设置正确的字体。
-% \footnote{\url{https://github.com/CTeX-org/ctex-kit/issues/389}}
-% 此外切换语言时,有一部分名称是需要被重新定义的。
-% \begin{macrocode}
-\newcommand\thu@set@punctuations{%
- \ifthu@language@chinese
- \xeCJKDeclareCharClass{FullLeft}{"2018, "201C}%
- \xeCJKDeclareCharClass{FullRight}{
- "00B7, "2019, "201D, "2013, "2014, "2025, "2026, "2E3A,
- }%
+\renewcommand\mainmatter{%
+ \cleardoublepage
+ \@mainmattertrue
+ \pagenumbering{arabic}%
+}
+\renewcommand\backmatter{%
+ \if@openright
+ \cleardoublepage
\else
- \ifthu@language@english
- \xeCJKDeclareCharClass{HalfLeft}{"2018, "201C}%
- \xeCJKDeclareCharClass{HalfRight}{
- "00B7, "2019, "201D, "2013, "2014, "2025, "2026, "2E3A,
- }%
- \fi
+ \clearpage
\fi
+ \@mainmatterfalse
+ \thusetup{toc-depth = 0}%
}
-\thu@set@punctuations
-\thu@option@hook{language}{\thu@set@punctuations}
% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
%
% \subsubsection{页眉页脚}
% \label{sec:headerfooter}
@@ -2459,11 +3027,27 @@
\let\chaptermark\@gobble
\else
\renewcommand\headrulewidth{0.75bp}%
- \fancyhead[C]{\wuhao\leftmark}%
+ \fancyhead[C]{%
+ \wuhao
+ \ifthu@main@language@chinese
+ \leftmark
+ \else
+ \MakeUppercase{\leftmark}%
+ \fi
+ }%
\fancyfoot[C]{\wuhao\thepage}%
\let\@mkboth\markboth
\def\chaptermark##1{%
- \markboth{\CTEXifname{\CTEXthechapter\quad}{}##1}{}%
+ \markboth{%
+ \CTEXifname{%
+ \CTEXthechapter
+ \ifthu@main@language@chinese
+ \quad
+ \else
+ \space
+ \fi
+ }{}##1%
+ }{}%
}%
\fi
\let\sectionmark\@gobble
@@ -2473,7 +3057,8 @@
%
% \cs{chapter} 会调用特殊的 page style。
% \begin{macrocode}
-\ctexset{chapter/pagestyle = plain}
+\def\ps@chapter{}
+\ctexset{chapter/pagestyle = chapter}
% \end{macrocode}
%
%
@@ -2487,14 +3072,14 @@
space=auto,
}
\newcommand\thu@set@indent{%
- \ifthu@main@language@english
+ \ifthu@main@language@chinese
+ \ctexset{autoindent=2}%
+ \else
\ifthu@degree@bachelor
\ctexset{autoindent=0.8cm}%
\else
- \ctexset{autoindent=2}%
+ \ctexset{autoindent=0.74cm}%
\fi
- \else
- \ctexset{autoindent=2}%
\fi
}
\thu@set@indent
@@ -2635,106 +3220,9 @@
%
% \subsubsection{数学相关}
% \label{sec:equation}
-% \begin{macro}{\ldots}
-% 省略号一律居中,所以 \cs{ldots} 不再居于底部。
-% \begin{macrocode}
-\newcommand\thu@set@math@ellipsis{%
- \ifthu@language@chinese
- \DeclareRobustCommand\mathellipsis{\mathinner{\unicodecdots}}%
- \else
- \ifthu@language@english
- \DeclareRobustCommand\mathellipsis{\mathinner{\unicodeellipsis}}%
- \fi
- \fi
-}
-\thu@set@math@ellipsis
-\thu@option@hook{language}{\thu@set@math@ellipsis}
-% \end{macrocode}
-% \end{macro}
-%
-% \begin{macro}{\le}
-% \begin{macro}{\ge}
-% \begin{macro}{\leq}
-% \begin{macro}{\geq}
-% 小于等于号要使用倾斜的形式。
-% \begin{macrocode}
-\protected\def\le{\leqslant}
-\protected\def\ge{\geqslant}
-\AtBeginDocument{%
- \renewcommand\leq{\leqslant}%
- \renewcommand\geq{\geqslant}%
-}
-% \end{macrocode}
-% \end{macro}
-% \end{macro}
-% \end{macro}
-% \end{macro}
-%
-% \begin{macro}{\int}
-% 积分号 \cs{int} 使用正体,并且上下限默认置于积分号上下两侧。
-% \begin{macrocode}
-\removenolimits{%
- \int\iint\iiint\iiiint\oint\oiint\oiiint
- \intclockwise\varointclockwise\ointctrclockwise\sumint
- \intbar\intBar\fint\cirfnint\awint\rppolint
- \scpolint\npolint\pointint\sqint\intlarhk\intx
- \intcap\intcup\upint\lowint
-}
-% \end{macrocode}
-% \end{macro}
-%
-% \begin{macro}{\Re}
-% \begin{macro}{\Im}
-% 实部、虚部操作符使用罗马体 $\mathrm{Re}$、$\mathrm{Im}$ 而不是 fraktur 体
-% $\Re$、$\Im$。
-% \begin{macrocode}
-\AtBeginDocument{%
- \renewcommand{\Re}{\operatorname{Re}}%
- \renewcommand{\Im}{\operatorname{Im}}%
-}
-% \end{macrocode}
-% \end{macro}
-% \end{macro}
-%
-% \begin{macro}{\nabla}
-% \cs{nabla} 使用粗正体。
-% \begin{macrocode}
-\AtBeginDocument{%
- \renewcommand\nabla{\mbfnabla}%
-}
-% \end{macrocode}
-% \end{macro}
-%
-% \begin{macro}{\bm}
-% \begin{macro}{\boldsymbol}
-% 兼容旧的粗体命令:\pkg{bm} 的 \cs{bm} 和 \pkg{amsmath} 的 \cs{boldsymbol}。
-% \begin{macrocode}
-\DeclareRobustCommand\bm[1]{{\symbf{#1}}}
-\DeclareRobustCommand\boldsymbol[1]{{\symbf{#1}}}
-% \end{macrocode}
-% \end{macro}
-% \end{macro}
-%
-% \begin{macro}{\square}
-% 兼容 \pkg{amssymb} 中的命令。
-% \begin{macrocode}
-\newcommand\square{\mdlgwhtsquare}
-% \end{macrocode}
-% \end{macro}
-%
-% \begin{macro}{\checkmark}
-% 允许在文本模式中使用 \cs{checkmark}。
-% \begin{macrocode}
-\AtBeginDocument{%
- \renewcommand\checkmark{\ensuremath{✓}}%
-}
-% \end{macrocode}
-% \end{macro}
-%
% 允许太长的公式断行、分页等。
% \begin{macrocode}
\allowdisplaybreaks[4]
-\renewcommand\theequation{\ifnum \c@chapter>\z@ \thechapter-\fi\@arabic\c@equation}
% \end{macrocode}
%
% 公式距前后文的距离由 4 个参数控制,参见 \cs{normalsize} 的定义。
@@ -2767,48 +3255,101 @@
\renewcommand{\floatpagefraction}{0.60}
% \end{macrocode}
%
-% 研究生要求表单元格中的文字采用 11pt 宋体字,单倍行距,段前空 3 磅,段后空 3 磅。
-% $(3 + 3) / (11 \times 1.3) \approx 0.4$
+% 允许用户设置图表编号的连接符。
+% \begin{macrocode}
+\thu@define@key{
+ figure-number-separator = {
+ name = figure@number@separator,
+ default = {.},
+ },
+ table-number-separator = {
+ name = table@number@separator,
+ default = {.},
+ },
+ equation-number-separator = {
+ name = equation@number@separator,
+ default = {.},
+ },
+ number-separator = {
+ name = number@separator,
+ default = {.},
+ },
+}
+\renewcommand\thefigure{%
+ \ifnum\c@chapter>\z@
+ \thechapter
+ \thu@figure@number@separator
+ \fi
+ \@arabic\c@figure
+}
+\renewcommand\thetable{%
+ \ifnum\c@chapter>\z@
+ \thechapter
+ \thu@table@number@separator
+ \fi
+ \@arabic\c@table
+}
+\renewcommand\theequation{%
+ \ifnum\c@chapter>\z@
+ \thechapter
+ \thu@equation@number@separator
+ \fi
+ \@arabic\c@equation
+}
+\newcommand\thu@set@number@separator{%
+ \let\thu@figure@number@separator\thu@number@separator
+ \let\thu@table@number@separator\thu@number@separator
+ \let\thu@equation@number@separator\thu@number@separator
+}
+\thu@option@hook{number-separator}{\thu@set@number@separator}
+% \end{macrocode}
+%
+% 研究生要求表单元格中的文字采用 11pt 宋体字,单倍行距。段前空 3 磅,段后空 3 磅。
+% 段前段后的高度直接加到行距上,对于中文,修正后的行距为
+% $11 \times 1.3 + 6 = 20.3$(pt),
+% 而英文版的行距为 $11 \times 1.3 + 6 = 18.65$(pt)。
+% 用户可以手动设置 \cs{arraystretch} 调整表格的行距 。
% \begin{macrocode}
\patchcmd\@floatboxreset{%
\normalsize
}{%
- \fontsize{11bp}{14.3bp}\selectfont
- \renewcommand\arraystretch{1.4}%
+ \ifthu@language@chinese
+ \fontsize{11bp}{20.3bp}\selectfont
+ \else
+ \fontsize{11bp}{18.65bp}\selectfont
+ \fi
}{}{\thu@patch@error{\@floatboxreset}}
% \end{macrocode}
%
+% 对 \pkg{longtable} 跨页表格进行相同的设置。
+% \begin{macrocode}
+\AtEndOfPackageFile*{longtable}{
+ \AtBeginEnvironment{longtable}{%
+ \ifthu@language@chinese
+ \fontsize{11bp}{20.3bp}\selectfont
+ \else
+ \fontsize{11bp}{18.65bp}\selectfont
+ \fi
+ }
+}
+% \end{macrocode}
+%
% 定制浮动图形和表格标题样式,以及改变附录中浮动体的编号规则:
% \begin{itemize}
-% \item 图表标题字体为 11pt, 这里写作大五号
+% \item 图表标题字体为 11pt
% \item 去掉图表号后面的冒号,图序与图名文字之间空一个汉字符宽度
-% \item 本科生附录中的各种浮动体需要编号为类似 A-1 的形式
% \item 图:caption 在下,段前空 6 磅,段后空 12 磅
% \item 表:caption 在上,段前空 12 磅,段后空 6 磅
% \end{itemize}
% \begin{macrocode}
-\ifthu@degree@bachelor
- \AtBeginDocument{% delay the check until all packages are loaded
- \g@addto@macro\appendix{\renewcommand*{\thefigure}{\thechapter-\arabic{figure}}}
- \g@addto@macro\appendix{\renewcommand*{\thetable}{\thechapter-\arabic{table}}}
- }
-\fi
-% \end{macrocode}
-%
-% \begin{macrocode}
-\newcommand\thu@caption@font{}
-\newcommand\thu@set@caption@font{%
+\DeclareCaptionFont{thu}{%
\ifthu@degree@bachelor
- \renewcommand\thu@caption@font{\fontsize{11bp}{15bp}\selectfont}%
+ \fontsize{11bp}{15bp}\selectfont
\else
- \renewcommand\thu@caption@font{\fontsize{11bp}{14.3bp}\selectfont}%
+ \fontsize{11bp}{14.3bp}\selectfont
\fi
}
-\thu@set@caption@font
-\thu@option@hook{degree}{\thu@set@caption@font}
-\DeclareCaptionFont{thu}{\thu@caption@font}
\captionsetup{
- format = hang,
font = thu,
labelsep = quad,
aboveskip = 6bp,
@@ -2855,8 +3396,8 @@
nameformat = {},
numberformat = {},
titleformat = {},
- aftername = \quad,
fixskip = true,
+ aftername = \quad,
afterindent = true,
lofskip = 0pt,
lotskip = 0pt,
@@ -2919,9 +3460,19 @@
},
}%
\ifthu@main@language@chinese
- \ctexset{chapter/number = \thechapter}%
+ \ctexset{
+ chapter = {
+ name = {第,章},
+ number = \thechapter,
+ },
+ }%
\else
- \ctexset{chapter/number = \thu@english@number{chapter}}%
+ \ctexset{
+ chapter = {
+ name = \chaptername\space,
+ number = \thu@english@number{chapter},
+ },
+ }%
\fi
% \end{macrocode}
%
@@ -2953,24 +3504,58 @@
% 由于 Word 的行距算法不同,这里进行了一些调整使得视觉上更接近。
% \begin{macrocode}
\else
+ \ifthu@main@language@chinese
+ \ctexset{%
+ chapter = {
+ format = \centering\sffamily\sanhao,
+ nameformat = {},
+ titleformat = {},
+ name = {第,章},
+ },
+ section = {
+ format = \sffamily\fontsize{14bp}{20bp}\selectfont,
+ },
+ subsection = {
+ format = \sffamily\fontsize{13bp}{20bp}\selectfont,
+ },
+ subsubsection = {
+ format = \sffamily\fontsize{12bp}{20bp}\selectfont,
+ },
+ }%
+ \else
+ \ctexset{%
+ chapter = {
+ format = \centering\sffamily\bfseries\fontsize{16bp}{20bp}\selectfont,
+ nameformat = \MakeUppercase,
+ titleformat = \MakeUppercase,
+ name = \chaptername\space,
+ },
+ section = {
+ format = \sffamily\bfseries\fontsize{14bp}{20bp}\selectfont,
+ },
+ subsection = {
+ format = \sffamily\bfseries\fontsize{13bp}{20bp}\selectfont,
+ },
+ subsubsection = {
+ format = \sffamily\bfseries\fontsize{12bp}{20bp}\selectfont,
+ },
+ }%
+ \fi
\ctexset{%
chapter = {
- format = \centering\sffamily\sanhao,
beforeskip = 27bp,
afterskip = 27bp,
+ number = \thechapter,
},
section = {
- format = \sffamily\fontsize{14bp}{20bp}\selectfont,
beforeskip = 24bp,
afterskip = 6bp,
},
subsection = {
- format = \sffamily\fontsize{13bp}{20bp}\selectfont,
beforeskip = 12bp,
afterskip = 6bp,
},
subsubsection = {
- format = \sffamily\fontsize{12bp}{20bp}\selectfont,
beforeskip = 12bp,
afterskip = 6bp,
},
@@ -2979,6 +3564,7 @@
}
\thu@set@section@format
\thu@option@hook{degree}{\thu@set@section@format}
+\thu@option@hook{main-language}{\thu@set@section@format}
% \end{macrocode}
%
% \begin{macrocode}
@@ -3155,22 +3741,38 @@
% 但是页码仍然用 \cs{rmfamily}。
% \begin{macrocode}
\else
- \titlecontents{chapter}
- [\z@]{\addvspace{6bp}\sffamily}
- {\contentspush{\thecontentslabel\quad}}{}
- {\rmfamily\thu@leaders\thecontentspage}%
- \titlecontents{section}
- [1em]{}
- {\contentspush{\thecontentslabel\quad}}{}
- {\thu@leaders\thecontentspage}%
- \titlecontents{subsection}
- [2em]{}
- {\contentspush{\thecontentslabel\quad}}{}
- {\thu@leaders\thecontentspage}%
+ \ifthu@main@language@chinese
+ \titlecontents{chapter}
+ [\z@]{\addvspace{6bp}\sffamily}
+ {\contentspush{\thecontentslabel\quad}}{}
+ {\rmfamily\thu@leaders\thecontentspage}%
+ \titlecontents{section}
+ [1em]{}
+ {\contentspush{\thecontentslabel\quad}}{}
+ {\thu@leaders\thecontentspage}%
+ \titlecontents{subsection}
+ [2em]{}
+ {\contentspush{\thecontentslabel\quad}}{}
+ {\thu@leaders\thecontentspage}%
+ \else
+ \titlecontents{chapter}
+ [\z@]{\addvspace{6bp}\heiti}
+ {\contentspush{\MakeUppercase{\thecontentslabel}\quad}\MakeUppercase}{\MakeUppercase}
+ {\rmfamily\thu@leaders\thecontentspage}%
+ \titlecontents{section}
+ [1em]{}
+ {\contentspush{\thecontentslabel\space}}{}
+ {\thu@leaders\thecontentspage}%
+ \titlecontents{subsection}
+ [2em]{}
+ {\contentspush{\thecontentslabel\space}}{}
+ {\thu@leaders\thecontentspage}%
+ \fi
\fi
}
\thu@set@toc@format
\thu@option@hook{degree}{\thu@set@toc@format}
+\thu@option@hook{main-language}{\thu@set@toc@format}
% \end{macrocode}
% \end{macro}
%
@@ -3208,6 +3810,9 @@
default = {Name of author},
name = author@en,
},
+ student-id = {
+ name = student@id,
+ },
supervisor = {
default = {导师姓名},
},
@@ -3221,11 +3826,18 @@
associate-supervisor* = {
name = associate@supervisor@en,
},
+ co-supervisor = {
+ name = co@supervisor,
+ },
+ co-supervisor* = {
+ name = co@supervisor@en,
+ },
+ % Reserved for compatibility
joint-supervisor = {
- name = joint@supervisor,
+ name = co@supervisor,
},
joint-supervisor* = {
- name = joint@supervisor@en,
+ name = co@supervisor@en,
},
% \end{macrocode}
%
@@ -3407,8 +4019,10 @@
\thu@spine
\fi
\ifthu@degree@graduate
- \cleardoublepage
- \thu@titlepage@en
+ \ifthu@thesis@type@thesis
+ \cleardoublepage
+ \thu@titlepage@en
+ \fi
\fi
\clearpage
}
@@ -3424,13 +4038,19 @@
\newcommand\thu@titlepage{%
\thusetup{language = chinese}%
\ifthu@degree@graduate
- \ifthu@degree@type@academic
- \thu@titlepage@graduate@academic
- \else
- \ifx\thu@discipline\@empty
- \thu@titlepage@graduate@professional
- \else
+ \ifthu@thesis@type@thesis
+ \ifthu@degree@type@academic
\thu@titlepage@graduate@academic
+ \else
+ \ifx\thu@discipline\@empty
+ \thu@titlepage@graduate@professional
+ \else
+ \thu@titlepage@graduate@academic
+ \fi
+ \fi
+ \else
+ \ifthu@thesis@type@proposal
+ \thu@titlepage@proposal
\fi
\fi
\else
@@ -3462,19 +4082,33 @@
hmargin = 3.5cm,
}%
\thispagestyle{empty}%
- \null\vskip 0.2cm%
+ \null\vskip 8.1pt%
\begingroup
\centering
\parbox[t][2cm][t]{\textwidth}{%
- \hskip -0.69cm%
+ \hskip -21.5pt%
\thu@titlepage@secret
}\par
- \vskip 1.5cm%
- {\thu@titlepage@title}%
- \vskip 0.85cm%
+ \vskip 40.5pt%
+ \begingroup
+ \sffamily\fontsize{26bp}{46.8bp}\selectfont
+ \thu@title\par
+ \endgroup
+ \ifthu@main@language@english
+ \vskip 5.4pt%
+ \begingroup
+ \sffamily\bfseries\fontsize{20bp}{31.2bp}\selectfont
+ \thu@title@en\par
+ \endgroup
+ \vskip -9.2pt%
+ \fi
+ \vskip 24.1pt%
\thu@titlepage@degree
\vfill
- \parbox[t][7.25cm][t]{\textwidth}{\centering\thu@titlepage@info}\par
+ \parbox[t][7.25cm][t]{\textwidth}{%
+ \centering\fangsong\fontsize{16bp}{31.2bp}\selectfont
+ \thu@titlepage@info
+ }\par
\parbox[t][1.03cm][t]{\textwidth}{\centering\thu@titlepage@date}\par
\endgroup
\clearpage
@@ -3499,11 +4133,26 @@
\thu@titlepage@secret
}\par
\vskip 1.5cm%
- {\sffamily\yihao[1.575]\thu@title\par}%
- \vskip 0.9cm%
+ \begingroup
+ % 1.21 倍行距,无网格
+ \sffamily\fontsize{26bp}{40.9bp}\selectfont
+ \thu@title\par
+ \endgroup
+ \ifthu@main@language@english
+ \vskip 5.4pt%
+ \begingroup
+ \sffamily\bfseries\fontsize{20bp}{31.2bp}\selectfont
+ \thu@title@en\par
+ \endgroup
+ \vskip -9.2pt%
+ \fi
+ \vskip 25.5pt%
\thu@titlepage@degree
\vfill
- \parbox[t][5.28cm][t]{\textwidth}{\centering\thu@titlepage@info}\par
+ \parbox[t][5.24cm][t]{\textwidth}{%
+ \centering\fangsong\fontsize{16bp}{1cm}\selectfont
+ \thu@titlepage@info
+ }\par
\parbox[t][1.25cm][t]{\textwidth}{\centering\thu@titlepage@date}\par
\endgroup
\clearpage
@@ -3511,6 +4160,49 @@
}
% \end{macrocode}
%
+% 选题报告封面
+% \begin{macrocode}
+\newcommand\thu@titlepage@proposal{%
+ \newgeometry{
+ top = 5cm,
+ bottom = 3.25cm,
+ hmargin = 3.17cm,
+ }%
+ \thispagestyle{empty}%
+ \begingroup
+ % \vspace*{0.1cm}%
+ \centering
+ % {\thu@titlepage@title}%
+ \parbox[t][3cm]{\textwidth}{%
+ \vskip 0.1cm%
+ \centering
+ \sffamily\fontsize{26bp}{46.8bp}\selectfont
+ \thu@title\par
+ }%
+ \vskip 0.85cm%
+ \thu@titlepage@degree
+ \vfill
+ \parbox[t][8.5cm][t]{\textwidth}{%
+ \centering\CJKfamily+{}%
+ \centering\fangsong\sanhao[1.95]%
+ \thu@titlepage@info
+ }\par
+ \parbox[t][2.5cm][t]{\textwidth}{\centering\thu@titlepage@date}\par
+ \endgroup
+ \clearpage
+ \restoregeometry
+}
+\newcommand\thu@set@student@id{%
+ \ifthu@thesis@type@proposal
+ \ifx\thu@student@id\@empty
+ \thusetup{student-id=2000310000}%
+ \fi
+ \fi
+}
+\thu@set@student@id
+\thu@option@hook{thesis-type}{\thu@set@student@id}
+% \end{macrocode}
+%
% \begin{macrocode}
\newcommand\thu@titlepage@secret{%
\sffamily\sanhao
@@ -3522,22 +4214,33 @@
}
% \end{macrocode}
%
-% 题名使用一号黑体字,一行写不下时可分两行写。
-% 由于 Word 模板这里设置了“对齐到网格”,所以实际行距不是 1.25 倍。
-% \begin{macrocode}
-\newcommand\thu@titlepage@title{%
- \sffamily\yihao[1.8]\thu@title\par
-}
-% \end{macrocode}
-%
% 申请学位的学科门类: 小二号宋体字,字距延伸 0.5bp,
% 所以 \cs{CJKglue} 应该设为 1 bp。
% \begin{macrocode}
\newcommand\thu@titlepage@degree{%
\begingroup
- \def\CJKglue{\hskip 1bp}%
\CJKfamily+{}\xiaoer
- (申请清华大学\thu@degree@name\ifthu@degree@type@professional 专业\fi 学位论文)\par
+ \def\CJKglue{\hskip 1bp}%
+ \ifthu@thesis@type@thesis
+ (申请清华大学\thu@degree@name
+ \ifthu@degree@type@professional
+ 专业%
+ \fi
+ 学位论文)%
+ \else
+ \ifthu@thesis@type@proposal
+ (清华大学%
+ \ifthu@degree@doctor
+ 博士%
+ \else
+ \ifthu@degree@master
+ 硕士%
+ \fi
+ \fi
+ 学位论文选题报告)%
+ \fi
+ \fi
+ \par
\endgroup
}
% \end{macrocode}
@@ -3575,8 +4278,8 @@
##2{##3}\\
\fi
}%
- \fangsong\sanhao[1.95]%
\begin{tabular}{l}%
+ \renewcommand\arraystretch{1}%
#4%
\end{tabular}%
}
@@ -3585,18 +4288,20 @@
\thu@info@item{培养单位}{}{\thu@department}%
\thu@info@item{学科}{}{\thu@discipline}%
\thu@info@item{研究生}{\thu@name@title}{\thu@author}%
+ \thu@info@item{学号}{}{\thu@student@id}%
\thu@info@item{指导教师}{\thu@name@title}{\thu@supervisor}%
\thu@info@item{副指导教师}{\thu@name@title}{\thu@associate@supervisor}%
- \thu@info@item{联合导师}{\thu@name@title}{\thu@joint@supervisor}%
+ \thu@info@item{联合导师}{\thu@name@title}{\thu@co@supervisor}%
}\par
}
\newcommand\thu@titlepage@info@doctor@professional{%
\thu@titlepage@info@tabular{3.03cm}{5em}{1.52cm}{%
\thu@info@item{培养单位}{}{\thu@department}%
\thu@info@item{申请人}{\thu@name@title}{\thu@author}%
+ \thu@info@item{学号}{}{\thu@student@id}%
\thu@info@item{指导教师}{\thu@name@title}{\thu@supervisor}%
\thu@info@item{副指导教师}{\thu@name@title}{\thu@associate@supervisor}%
- \thu@info@item{联合导师}{\thu@name@title}{\thu@joint@supervisor}%
+ \thu@info@item{联合导师}{\thu@name@title}{\thu@co@supervisor}%
}\par
}
\newcommand\thu@titlepage@info@master@academic{%
@@ -3604,9 +4309,10 @@
\thu@info@item{培养单位}{}{\thu@department}%
\thu@info@item{学科}{}{\thu@discipline}%
\thu@info@item{研究生}{\thu@name@title}{\thu@author}%
+ \thu@info@item{学号}{}{\thu@student@id}%
\thu@info@item{指导教师}{\thu@name@title}{\thu@supervisor}%
\thu@info@item{副指导教师}{\thu@name@title}{\thu@associate@supervisor}%
- \thu@info@item{联合指导教师}{\thu@name@title}{\thu@joint@supervisor}%
+ \thu@info@item{联合指导教师}{\thu@name@title}{\thu@co@supervisor}%
}\par
}
\newcommand\thu@titlepage@info@master@engineer{%
@@ -3614,18 +4320,20 @@
\thu@info@item{培养单位}{}{\thu@department}%
\thu@info@item{工程领域}{}{\thu@discipline}%
\thu@info@item{申请人}{\thu@name@title}{\thu@author}%
+ \thu@info@item{学号}{}{\thu@student@id}%
\thu@info@item{指导教师}{\thu@name@title}{\thu@supervisor}%
\thu@info@item{副指导教师}{\thu@name@title}{\thu@associate@supervisor}%
- \thu@info@item{联合指导教师}{\thu@name@title}{\thu@joint@supervisor}%
+ \thu@info@item{联合指导教师}{\thu@name@title}{\thu@co@supervisor}%
}\par
}
\newcommand\thu@titlepage@info@master@other{%
\thu@titlepage@info@tabular{3.28cm}{5em}{1.52cm}{%
\thu@info@item{培养单位}{}{\thu@department}%
\thu@info@item{申请人}{\thu@name@title}{\thu@author}%
+ \thu@info@item{学号}{}{\thu@student@id}%
\thu@info@item{指导教师}{\thu@name@title}{\thu@supervisor}%
\thu@info@item{副指导教师}{\thu@name@title}{\thu@associate@supervisor}%
- \thu@info@item{联合指导教师}{\thu@name@title}{\thu@joint@supervisor}%
+ \thu@info@item{联合指导教师}{\thu@name@title}{\thu@co@supervisor}%
}\par
}
% \end{macrocode}
@@ -3635,8 +4343,9 @@
% \begin{macrocode}
\newcommand\thu@titlepage@date{%
\begingroup
+ \sanhao
\def\CJKglue{\hskip 1bp}%
- \sanhao\thu@format@date{\thu@date@zh@short}{\thu@date}\par
+ \thu@format@date{\thu@date@zh@short}{\thu@date}\par
\endgroup
}
% \end{macrocode}
@@ -3739,12 +4448,13 @@
}
\newcommand\thu@titlepage@en@supervisor{%
\begin{tabular}{r@{\makebox[0.71cm][l]{:}}l}%
- \thu@thesis@name@en{} Supervisor & \thu@supervisor@en \\
+ \renewcommand\arraystretch{1}%
+ \thu@thesis@name@en{} Supervisor & \thu@supervisor@en \\
\ifx\thu@associate@supervisor@en\@empty\else
- Associate Supervisor & \thu@associate@supervisor@en \\
+ Associate Supervisor & \thu@associate@supervisor@en \\
\fi
- \ifx\thu@joint@supervisor@en\@empty\else
- Cooperate Supervisor & \thu@joint@supervisor@en \\
+ \ifx\thu@co@supervisor@en\@empty\else
+ Co-supervisor & \thu@co@supervisor@en \\
\fi
\end{tabular}%
}
@@ -3819,7 +4529,7 @@
\def\thu@info@item##1##2##3{%
\ifx##3\@empty\else
\thu@fixed@box{%
- \ifx\thu@joint@supervisor\@empty
+ \ifx\thu@co@supervisor\@empty
4em%
\else
5.5em%
@@ -3835,7 +4545,7 @@
\thu@info@item{姓名}{\thu@name@title}{\thu@author}%
\thu@info@item{指导教师}{\thu@name@title}{\thu@supervisor}%
\thu@info@item{辅导教师}{\thu@name@title}{\thu@associate@supervisor}%
- \thu@info@item{联合指导教师}{\thu@name@title}{\thu@joint@supervisor}%
+ \thu@info@item{联合指导教师}{\thu@name@title}{\thu@co@supervisor}%
\endgroup
\vskip 1.4cm%
\begingroup
@@ -3907,6 +4617,7 @@
\vskip 0.4cm%
{\xiaosi[2.6]%
\begin{tabular}{l@{\quad}l}%
+ \renewcommand\arraystretch{1}%
\thu@stretch{11em}{博士后姓名} & \thu@author \\
\thu@stretch{11em}{流动站(一级学科)名称} & \thu@discipline@level@i \\
\thu@stretch{11em}{专\quad{}业(二级学科)名称} & \thu@discipline@level@ii \\
@@ -3919,7 +4630,7 @@
研究工作期满时间\quad\thu@format@date{\thu@date@zh@digit}{\thu@end@date}\par
}%
\vskip 2.1cm%
- {\xiaosi[2.6]清华大学人事部(北京)\par}%
+ {\xiaosi[2.6]清华大学人事处(北京)\par}%
\vskip 0.6cm%
{\wuhao\thu@format@date{\thu@date@zh@digit@short}{\thu@date}\par}%
\end{center}%
@@ -3945,7 +4656,12 @@
}%
\kvsetkeys{thu@committee}{#1}%
\ifx\thu@committee@file\@empty
- \thu@chapter*[]{\thu@committee@name}%
+ \begingroup
+ \ifthu@main@language@english
+ \ctexset{chapter/format=\centering\sffamily\fontsize{16bp}{20bp}\selectfont}
+ \fi
+ \thu@chapter*[]{\thu@committee@name}%
+ \endgroup
\else
\thu@pdfbookmark{0}{\thu@committee@name}%
\includepdf{\thu@committee@file}%
@@ -3958,7 +4674,9 @@
afterindent = false,
},
}%
+ \thusetup{language=chinese}
}{%
+ \thu@reset@main@language
}
% \end{macrocode}
% \end{environment}
@@ -3968,18 +4686,20 @@
% 授权说明
% \begin{macrocode}
\newcommand\copyrightpage[1][]{%
+ \cleardoublepage
\ifthu@degree@postdoc\relax\else
\def\thu@@tmp{#1}
\ifx\thu@@tmp\@empty
+ \thusetup{language=chinese}%
\ifthu@degree@bachelor
\thu@copyright@page@bachelor
\else
\thu@copyright@page@graduate
\fi
+ \thu@reset@main@language
\else
- \cleardoublepage
\thispagestyle{empty}%
- \thu@pdfbookmark{0}{\thu@authorization@title}%
+ \thu@pdfbookmark{0}{关于学位论文使用授权的说明}%
\thu@phantomsection
\kv@define@key{thu@copyright}{file}{\includepdf{\kv@value}}%
\kv@set@family@handler{thu@copyright}{%
@@ -4000,7 +4720,6 @@
\newcommand{\thu@authorization@frontdate}{%
日\ifthu@degree@bachelor\hspace{1em}\else\hspace{2em}\fi 期:}
\newcommand\thu@copyright@page@graduate{%
- \cleardoublepage
\newgeometry{
vmargin = 3.8cm,
hmargin = 3.2cm,
@@ -4049,7 +4768,6 @@
\restoregeometry
}
\newcommand\thu@copyright@page@bachelor{%
- \cleardoublepage
\begingroup
\ctexset{
chapter = {
@@ -4118,7 +4836,14 @@
\fi
\thusetup{language = chinese}%
\ifthu@degree@graduate
- \thu@chapter*{\thu@abstract@name}%
+ \begingroup
+ \ifthu@main@language@english
+ \ctexset{%
+ chapter/format = \centering\sffamily\fontsize{16bp}{20bp}\selectfont,
+ }%
+ \fi
+ \thu@chapter*{\thu@abstract@name}%
+ \endgroup
\else
\thu@chapter*[]{\thu@abstract@name}%
\fi
@@ -4292,8 +5017,20 @@
}%
\kvsetkeys{thu@statement}{#1}%
\ifx\thu@statement@file\@empty
- \thu@chapter*{\thu@statement@name}%
- \thispagestyle{\thu@statement@page@style}%
+ \thusetup{language=chinese}%
+ \begingroup
+ \ifthu@degree@graduate
+ \ifthu@main@language@english
+ \ctexset{%
+ chapter/format = \centering\sffamily\fontsize{16bp}{20bp}\selectfont,
+ }%
+ \fi
+ \fi
+ \thu@chapter*{\thu@statement@name}%
+ \endgroup
+ \ifthu@degree@bachelor
+ \thispagestyle{\thu@statement@page@style}%
+ \fi
\thu@statement@text\par
\ifthu@degree@graduate
\vskip 2cm%
@@ -4302,11 +5039,15 @@
\fi
{\hfill\thu@signature\thu@underline[2.5cm]\relax
\thu@backdate\thu@underline[2.5cm]\relax}%
+ \thu@reset@main@language
\else
\includepdf[pagecommand={%
\markboth{\thu@statement@name}{}%
\thu@phantomsection
\addcontentsline{toc}{chapter}{\thu@statement@name}%
+ \ifthu@degree@bachelor\else
+ \thispagestyle{empty}%
+ \fi
}]{\thu@statement@file}%
\fi
\ifthu@degree@bachelor
@@ -4703,7 +5444,7 @@
% 行距采用固定值 16 磅,段前空 3 磅,段后空 0 磅。
%
% 本科生要求宋体五号/Times New Roman 10.5 pt,固定行距 17pt,段前后间距 3pt;
-% 英文专业要求悬挂缩进 0.5inch(1.27 厘米)。
+% 英文专业要求悬挂缩进 0.5inch(1.27 厘米)。
%
% 复用 \pkg{natbib} 的 \texttt{thebibliography} 环境,调整距离。
% \begin{macrocode}
@@ -4855,7 +5596,7 @@
% \end{macrocode}
%
% 这里不要使用 \cs{addcontentsline},
-% 避免写入 \pkg{titletoc} 的 (\file{.ptc}) 文件中,
+% 避免写入 \pkg{titletoc} 的 \file{.ptc} 文件中,
% 造成 \env{survey} 的子目录中 |tocdepth| 为 0。
% \begin{macrocode}
\thu@option@hook{toc-depth}{%
@@ -4987,7 +5728,7 @@
}
% \end{macrocode}
%
-% 调研阅读报告的参考文献(或书面翻译对应的外文资料的原文索引)标题用宋体小四号字,段前 20pt,段后 6pt,行距 20pt。
+% 调研阅读报告的参考文献(或书面翻译对应的外文资料的原文索引)标题用宋体小四号字,段前 20pt,段后 6pt,行距 20pt。
% \begin{macrocode}
\newcommand\thu@appendix@bibsection{%
\par
@@ -5076,6 +5817,36 @@
}
% \end{macrocode}
%
+% \subsection{指导教师/小组学术评语}
+% \begin{environment}{comments}
+% \begin{macrocode}
+\newenvironment{comments}[1][]{%
+ \@mainmatterfalse
+ \kv@define@key{thu@comments}{name}{\let\thu@comments@name\kv@value}%
+ \kv@set@family@handler{thu@comments}{%
+ \ifx\kv@value\relax
+ \let\thu@comments@name\kv@key
+ \else
+ \kv@handled@false
+ \fi
+ }%
+ \kvsetkeys{thu@comments}{#1}%
+ \chapter{\thu@comments@name}%
+}{%
+}
+% \end{macrocode}
+% \end{environment}
+%
+% \subsection{答辩委员会决议书}
+% \begin{environment}{resolution}
+% \begin{macrocode}
+\newenvironment{resolution}{%
+ \@mainmatterfalse
+ \chapter{\thu@resolution@name}%
+}{}
+% \end{macrocode}
+% \end{environment}
+%
% \subsection{综合论文训练记录表}
%
% \begin{macro}{\record}
@@ -5193,18 +5964,6 @@
}
% \end{macrocode}
%
-% \subsubsection{\pkg{longtable} 宏包}
-%
-% 我们采用 \pkg{longtable} 来处理跨页的表格。同样我们需要设置其默认字体为五号。
-% \begin{macrocode}
-\AtEndOfPackageFile*{longtable}{
- \pretocmd\LT@array{%
- \fontsize{11bp}{14.3bp}\selectfont
- \renewcommand\arraystretch{1.4}%
- }{}{\thu@patch@error{\LT@array}}
-}
-% \end{macrocode}
-%
% \subsubsection{\pkg{siunitx} 宏包}
%
% \begin{macrocode}
@@ -5224,7 +5983,7 @@
\else
\ifthu@language@english
\sisetup{
- list-final-separator = { and },
+ list-final-separator = {, and },
list-pair-separator = { and },
range-phrase = { to },
}%
@@ -5272,7 +6031,7 @@
}{%
\popQED\endtrivlist\@endpefalse
}
- \renewcommand\qedsymbol{\ensuremath{\QED}}
+ \renewcommand\qedsymbol{\thu@qed}
}
% \end{macrocode}
%
@@ -5283,7 +6042,7 @@
\AtEndOfPackageFile*{ntheorem}{%
\theorembodyfont{\normalfont}%
\theoremheaderfont{\normalfont\sffamily}%
- \theoremsymbol{\ensuremath{\QED}}%
+ \theoremsymbol{\thu@qed}%
\newtheorem*{proof}{\thu@proof@name}%
\theoremstyle{plain}%
\theoremsymbol{}%
@@ -5314,7 +6073,6 @@
\PassOptionsToPackage{chapter}{algorithm}
\AtEndOfPackageFile*{algorithm}{
\floatname{algorithm}{\thu@algorithm@name}
- \g@addto@macro\appendix{\renewcommand*{\thealgorithm}{\thechapter-\arabic{algorithm}}}
\renewcommand\listofalgorithms{%
\thu@listof{algorithm}%
}
@@ -5357,7 +6115,6 @@
%
% \begin{macrocode}
\AtEndOfPackageFile*{minted}{
- \g@addto@macro\appendix{\renewcommand*{\thelisting}{\thechapter-\arabic{listing}}}%
\newcommand\thu@set@listing@language{%
\ifthu@language@chinese
\floatname{listing}{代码}%
@@ -5541,7 +6298,6 @@
\setmainfont{Palatino}
\setsansfont[Scale=MatchLowercase]{Helvetica}
\setmonofont[Scale=MatchLowercase]{Menlo}
- \xeCJKsetwidth{‘’“”}{1em}
}{
\setmainfont[
Extension = .otf,
@@ -5571,6 +6327,7 @@
math-style=ISO,
bold-style=ISO,
}
+\DeclareRobustCommand\mathellipsis{\mathinner{\unicodecdots}}
\IfFontExistsTF{XITSMath-Regular.otf}{
\setmathfont[
Extension = .otf,
@@ -5679,6 +6436,15 @@
\newcommand{\note}[2][Note]{{%
\color{magenta}{\bfseries #1}\emph{#2}}}
+\g@addto@macro\UrlBreaks{%
+ \do0\do1\do2\do3\do4\do5\do6\do7\do8\do9%
+ \do\A\do\B\do\C\do\D\do\E\do\F\do\G\do\H\do\I\do\J\do\K\do\L\do\M
+ \do\N\do\O\do\P\do\Q\do\R\do\S\do\T\do\U\do\V\do\W\do\X\do\Y\do\Z
+ \do\a\do\b\do\c\do\d\do\e\do\f\do\g\do\h\do\i\do\j\do\k\do\l\do\m
+ \do\n\do\o\do\p\do\q\do\r\do\s\do\t\do\u\do\v\do\w\do\x\do\y\do\z
+}
+\Urlmuskip=0mu plus 0.1mu
+
\DeclareDocumentCommand{\githubuser}{m}{\href{https://github.com/#1}{@#1}}
\def\thuthesis{\textsc{Thu}\-\textsc{Thesis}}
diff --git a/macros/latex/contrib/thuthesis/thuthesis.ins b/macros/latex/contrib/thuthesis/thuthesis.ins
index 0dec4fcbdc..05c5920b9e 100644
--- a/macros/latex/contrib/thuthesis/thuthesis.ins
+++ b/macros/latex/contrib/thuthesis/thuthesis.ins
@@ -1,18 +1,17 @@
%%
-%% Copyright (C) 2005-2020 by Ruini Xue <xueruini@gmail.com>
+%% Copyright (C) 2005-2021 by Tsinghua University TUNA Association <tuna@tsinghua.edu.cn>
%%
%% This file is part of the ThuThesis package project.
%% ---------------------------------------------------
%%
%% This work may be distributed and/or modified under the
-%% conditions of the LaTeX Project Public License, either version 1.3
+%% conditions of the LaTeX Project Public License, either version 1.3c
%% of this license or (at your option) any later version.
%% The latest version of this license is in
-%% http://www.latex-project.org/lppl.txt
-%% and version 1.3 or later is part of all distributions of LaTeX
-%% version 2005/12/01 or later.
+%% https://www.latex-project.org/lppl.txt
+%% and version 1.3c or later is part of all distributions of LaTeX
+%% version 2008 or later.
%%
-%% This work has the LPPL maintenance status `maintained'.
\input docstrip
@@ -25,15 +24,15 @@
This is a generated file.
-Copyright (C) 2005-\the\year by Ruini Xue <xueruini@gmail.com>
+Copyright (C) 2005-\the\year by Tsinghua University TUNA Association <tuna@tsinghua.edu.cn>
This work may be distributed and/or modified under the
-conditions of the LaTeX Project Public License, either version 1.3
+conditions of the LaTeX Project Public License, either version 1.3c
of this license or (at your option) any later version.
The latest version of this license is in
- http://www.latex-project.org/lppl.txt
-and version 1.3 or later is part of all distributions of LaTeX
-version 2005/12/01 or later.
+ https://www.latex-project.org/lppl.txt
+and version 1.3c or later is part of all distributions of LaTeX
+version 2008 or later.
To produce the documentation run the original source files ending with `.dtx'
through LaTeX.
diff --git a/macros/latex/contrib/thuthesis/thuthesis.pdf b/macros/latex/contrib/thuthesis/thuthesis.pdf
index 40ebbc9fe0..c32a334de2 100644
--- a/macros/latex/contrib/thuthesis/thuthesis.pdf
+++ b/macros/latex/contrib/thuthesis/thuthesis.pdf
Binary files differ