From 1599e6b35e1f560370f42545a6880e0094359995 Mon Sep 17 00:00:00 2001 From: 1FCENdoge <438033873a@gmail.com> Date: Fri, 5 Jun 2026 15:47:19 +0800 Subject: [PATCH 1/6] =?UTF-8?q?=E9=BB=98=E8=AE=A4=E6=95=B0=E5=AD=A6?= =?UTF-8?q?=E7=AC=A6=E5=8F=B7=E9=A3=8E=E6=A0=BC=20math-style=20=E6=94=B9?= =?UTF-8?q?=E4=B8=BA=20TeX=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 4 ++++ sysuthesis-guide.tex | 8 ++++---- sysuthesis.cls | 25 +++++++++++++------------ 3 files changed, 21 insertions(+), 16 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 06fb013..91e6b47 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +### Changed + +- 默认数学符号风格 `math-style` 改为 `TeX`。 + ## [2.1.0] - 2026-06-01 ### 版本亮点 diff --git a/sysuthesis-guide.tex b/sysuthesis-guide.tex index ee6de12..9968e12 100644 --- a/sysuthesis-guide.tex +++ b/sysuthesis-guide.tex @@ -32,8 +32,8 @@ \xeCJKsetwidth{‘’“”}{1em} }{} \unimathsetup{ - math-style=ISO, - bold-style=ISO, + math-style=TeX, + bold-style=TeX, } \IfFontExistsTF{xits-math.otf}{ \setmathfont[ @@ -491,10 +491,10 @@ \subsection{数学} \DescribeOption{math-style} 用户可以通过设置 \opt{math-style} 选择数学符号样式(可选: -\opt{GB}(中文默认),\opt{TeX}(英文默认)和 \opt{ISO}),比如: +\opt{TeX}(默认),\opt{GB}(默认)和 \opt{ISO}),比如: \begin{latex} \sysusetup{ - math-style = ISO, + math-style = GB, } \end{latex} diff --git a/sysuthesis.cls b/sysuthesis.cls index f8305eb..1b8cb0f 100644 --- a/sysuthesis.cls +++ b/sysuthesis.cls @@ -1145,21 +1145,22 @@ \fi } -\ifsysu@main@language@chinese - \sysusetup{math-style = GB}% -\else - \sysusetup{math-style = TeX}% -\fi +% \ifsysu@main@language@chinese +% \sysusetup{math-style = GB}% +% \else +% \sysusetup{math-style = TeX}% +% \fi +\sysusetup{math-style = TeX}% \sysu@set@math@style \sysu@option@hook{math-style}{\sysu@set@math@style} -\sysu@option@hook{main-language}{% - \ifsysu@main@language@chinese - \sysusetup{math-style = GB}% - \else - \sysusetup{math-style = TeX}% - \fi -} +% \sysu@option@hook{main-language}{% +% \ifsysu@main@language@chinese +% \sysusetup{math-style = GB}% +% \else +% \sysusetup{math-style = TeX}% +% \fi +% } % 针对 \pkg{unicode-math} 逐项配置数学符号。 From b70b7f0531d6909d5960426506c265693c2631a2 Mon Sep 17 00:00:00 2001 From: 1FCENdoge <438033873a@gmail.com> Date: Fri, 5 Jun 2026 16:31:34 +0800 Subject: [PATCH 2/6] =?UTF-8?q?=E4=BF=AE=E6=AD=A3=E4=BA=86=E8=B0=83?= =?UTF-8?q?=E7=94=A8=20mathtools=20=E5=90=8E=20\eqref=20=E4=B8=8E=E5=89=8D?= =?UTF-8?q?=E6=96=87=E9=97=B4=E8=B7=9D=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 4 ++++ sysuthesis.cls | 62 ++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 66 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 91e6b47..34ba74f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,6 +11,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - 默认数学符号风格 `math-style` 改为 `TeX`。 +### Fixed + +- 修正了调用 `mathtools` 后 `\eqref` 与前文间距的问题([tuna/thuthesis#1043](https://github.com/tuna/thuthesis/discussions/1043))。 + ## [2.1.0] - 2026-06-01 ### 版本亮点 diff --git a/sysuthesis.cls b/sysuthesis.cls index 1b8cb0f..64fa4b5 100644 --- a/sysuthesis.cls +++ b/sysuthesis.cls @@ -350,6 +350,13 @@ }, default = false, }, + eqn-paren-style = { + name = eqn@paren@style, + choices = { + full, + half, + } + }, } % 将 \sysu@cite@style 置空方便后续进行判断。 @@ -2898,6 +2905,41 @@ \patchcmd{\@getpen}{\@M}{\@Mi} {}{\sysu@patch@error{\@getpen}} +% \subsection{表达式} + +% 重定义 `\eqref`,使`式~\eqref` 这样的写法不产生额外的空格。 +% \DeclareRobustCommand{\eqref}[1]{\textup{\tagform@{\ref{#1}}}} +\DeclareRobustCommand{\eqref}[1]{% + \ifsysu@language@chinese + \ifsysu@eqn@paren@style@full + \unskip + \fi + \fi + \textup{\tagform@{\ref{#1}}}% + \ifsysu@language@chinese + \ifsysu@eqn@paren@style@full + \ignorespaces + \fi + \fi +} + +% 修改 `amsmath` 的 `\tagform@` +% \def\tagform@#1{\maketag@@@{(\ignorespaces#1\unskip\@@italiccorr)}} +\def\tagform@#1{% + \ifsysu@language@chinese + \ifsysu@eqn@paren@style@full + % 这里的 `\unskip` 是为了 `式~\eqref` 不产生额外的空格。 + \unskip + % \kern 0pt 防止中文左括号与前面文字的距离过窄 + % 防止中文左括号与前面文字的距离过窄 + \maketag@@@{\kern 0pt\relax (\ignorespaces#1\unskip\@@italiccorr)}% + \else + \maketag@@@{(\ignorespaces#1\unskip\@@italiccorr)}% + \fi + \else + \maketag@@@{(\ignorespaces#1\unskip\@@italiccorr)}% + \fi +} % \subsection{参考文献} @@ -3502,11 +3544,31 @@ % \pkg{mathtools} 会修改 \pkg{unicode-math} 的 `\underbrace` 和 `\overbrace`, % 需要还原为 `\LaTeXunderbrace` 和 `\LaTeXoverbrace`, % 参考 \url{https://tex.stackexchange.com/q/521394/82731}。 +% +% \pkg{mathtools} 的 `showonlyrefs` 选项修改了 `\eqref`, +% 需要重新处理括号与前后文字的空白。 +% 见 。 \AtEndOfPackageFile*{mathtools}{ \@ifpackageloaded{unicode-math}{ \let\underbrace\LaTeXunderbrace \let\overbrace\LaTeXoverbrace }{} + \expandafter\def\csname MT_extended_eqref:n\endcsname#1{% + \ifsysu@language@chinese + \ifsysu@eqn@paren@style@full + \unskip + \fi + \fi + \protected@write\@auxout{} + {\string\MT@newlabel{#1}}% + \textup{\let\df@label\@empty\csname MT_prev_tagform:n\endcsname{\ref{#1}}}% + \ifsysu@language@chinese + \ifsysu@eqn@paren@style@full + \ignorespaces + \fi + \fi + } + \expandafter\MakeRobust\csname MT_extended_eqref:n\endcsname } % \subsubsection{\pkg{nomencl} 宏包} From 921471e710c913996af4fccd9a8e24762d1d2ef3 Mon Sep 17 00:00:00 2001 From: 1FCENdoge <438033873a@gmail.com> Date: Fri, 5 Jun 2026 17:59:18 +0800 Subject: [PATCH 3/6] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E7=94=B1=E7=BC=BA?= =?UTF-8?q?=E5=A4=B1=E6=B3=A8=E9=87=8A=E5=AF=BC=E8=87=B4=E7=9A=84=E5=A4=9A?= =?UTF-8?q?=E4=BD=99=E7=A9=BA=E6=A0=BC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- sysuthesis.cls | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sysuthesis.cls b/sysuthesis.cls index 64fa4b5..1b0d2f9 100644 --- a/sysuthesis.cls +++ b/sysuthesis.cls @@ -1761,10 +1761,10 @@ \csname clist_use:Nn\endcsname{#1}{#2}% } \newcommand\sysu@supervisor@names{% - \sysu@clist@use{\sysu@supervisor}{\quad} + \sysu@clist@use{\sysu@supervisor}{\quad}% } \newcommand\sysu@practice@supervisor@names{% - \sysu@clist@use{\sysu@practice@supervisor}{\quad} + \sysu@clist@use{\sysu@practice@supervisor}{\quad}% } \newcounter{sysu@count} \newcommand\sysu@supervisor@en@line{% From 76f0b726ce8989887ded57e7fc99bb13e8e7880a Mon Sep 17 00:00:00 2001 From: 1FCENdoge <438033873a@gmail.com> Date: Fri, 5 Jun 2026 18:18:27 +0800 Subject: [PATCH 4/6] =?UTF-8?q?=E6=9C=AC=E7=A7=91=E7=94=9F=E6=A8=A1?= =?UTF-8?q?=E6=9D=BF=E5=8E=BB=E6=8E=89=E5=86=85=E5=B0=81=E9=9D=A2=E4=B9=A6?= =?UTF-8?q?=E7=AD=BE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 1 + sysuthesis.cls | 3 +-- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 34ba74f..db476f2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,6 +10,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Changed - 默认数学符号风格 `math-style` 改为 `TeX`。 +- 本科生模板去掉 pdf 文件内封面的书签。 ### Fixed diff --git a/sysuthesis.cls b/sysuthesis.cls index 1b0d2f9..aa89953 100644 --- a/sysuthesis.cls +++ b/sysuthesis.cls @@ -1965,7 +1965,7 @@ % 本科生的外封 \newcommand\sysu@cover{% \begin{titlepage}% - \sysu@pdfbookmark{Cover}% + \sysu@pdfbookmark{封面}% \centering \vskip 0.5cm% \includegraphics[width=3cm]{\sysu@logo@path/sysu-logo.pdf} @@ -2021,7 +2021,6 @@ % 本科生的扉页(内封) \newcommand\sysu@title@page@bachelor{% \begin{titlepage}% - \sysu@pdfbookmark{Title page}% \centering \ \vskip 2cm% { From f01b277caf897aff8e9b4037e6814931bd986f01 Mon Sep 17 00:00:00 2001 From: 1FCENdoge <438033873a@gmail.com> Date: Fri, 5 Jun 2026 18:45:57 +0800 Subject: [PATCH 5/6] =?UTF-8?q?=E4=BF=AE=E6=AD=A3=20biblatex=20=E4=B8=AD?= =?UTF-8?q?=20authoryear=20=E5=8F=82=E8=80=83=E6=96=87=E7=8C=AE=E6=A0=B7?= =?UTF-8?q?=E5=BC=8F=E4=B8=8D=E5=90=8C=E4=BD=9C=E8=80=85=E4=BB=85=E5=9B=A0?= =?UTF-8?q?=E5=90=8C=E5=A7=93=E8=A2=AB=E9=94=99=E8=AF=AF=E5=9C=B0=E8=AE=A4?= =?UTF-8?q?=E4=B8=BA=E6=98=AF=E5=90=8C=E4=B8=80=E4=BD=9C=E8=80=85=E7=9A=84?= =?UTF-8?q?=E9=94=99=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 1 + sysuthesis-authoryear.bbx | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index db476f2..ac4981e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -15,6 +15,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Fixed - 修正了调用 `mathtools` 后 `\eqref` 与前文间距的问题([tuna/thuthesis#1043](https://github.com/tuna/thuthesis/discussions/1043))。 +- 修正 biblatex 中 authoryear 参考文献样式不同作者仅因同姓被错误地认为是同一作者的错误([ustctug/ustcthesis#499](https://github.com/ustctug/ustcthesis/issues/499)、[hushidong/biblatex-gb7714-2015#236](https://github.com/hushidong/biblatex-gb7714-2015/issues/236))。 ## [2.1.0] - 2026-06-01 diff --git a/sysuthesis-authoryear.bbx b/sysuthesis-authoryear.bbx index 7d6878e..ede2e7e 100644 --- a/sysuthesis-authoryear.bbx +++ b/sysuthesis-authoryear.bbx @@ -796,7 +796,7 @@ % v1.0s,20190828 \@ifpackagelater{biblatex}{2019/08/16}{% \ExecuteBibliographyOptions{% - nohashothers=true}}{} + nohashothers=false}}{} %===================================================================== From 9a354b424e96996ce092c1df45ddc3abad5df210 Mon Sep 17 00:00:00 2001 From: 1FCENdoge <438033873a@gmail.com> Date: Fri, 5 Jun 2026 21:09:15 +0800 Subject: [PATCH 6/6] =?UTF-8?q?=E5=BE=AE=E8=B0=83=E7=A4=BA=E4=BE=8B?= =?UTF-8?q?=E5=86=85=E5=AE=B9=EF=BC=8C=E5=87=8F=E5=B0=91=E4=B8=80=E6=9D=A1?= =?UTF-8?q?=E4=BF=A1=E6=81=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docs/chap03.tex | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/docs/chap03.tex b/docs/chap03.tex index 434c429..e9cee55 100644 --- a/docs/chap03.tex +++ b/docs/chap03.tex @@ -41,6 +41,9 @@ \section{公式} \section{例子、定理与证明} +示例文件中使用 \pkg{amsthm} 宏包配置了定理、引理和证明等环境。 +用户也可以使用 \pkg{ntheorem} 宏包。 + \begin{theorem}[定理例子] \label{the:example-theorem} 这是一个定理。 @@ -67,10 +70,5 @@ \section{例子、定理与证明} \begin{proof} - - 下面我们开始证明: - - 由本定理的证明可见,我可以引用\autoref{the:example-theorem}和引理\ref{the:example-corollary}以及推论\ref{the:example-lemma}来证明我这个 \LaTeX 可以用来写各种证明。 \\ - - \autoref{the:example-theorem-sysu-thesis}得证。 + Trivial. \end{proof} \ No newline at end of file