From 6d3bfc9ff70e0940aebf9414972bdea27115535d Mon Sep 17 00:00:00 2001 From: Yu Xiong Date: Thu, 21 Mar 2024 21:52:08 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E5=A4=8D=E6=88=90=E6=9E=9C?= =?UTF-8?q?=E5=88=97=E8=A1=A8=E4=B8=AD=E6=96=87=E5=A7=93=E5=90=8D=E5=8A=A0?= =?UTF-8?q?=E7=B2=97=E7=9A=84=E9=97=AE=E9=A2=98=20(#192)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 5 +++++ source/njuthesis.dtx | 13 +++++++++---- 2 files changed, 14 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 4a0b82a..8ad33b2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,10 @@ ## [未发布] +### 修复 + +- 修复成果列表中文姓名加粗的问题 - [#192] + ## [1.4.0] - 2024-03-19 ### 新增 @@ -626,6 +630,7 @@ [#173]: https://github.com/nju-lug/NJUThesis/issues/173 [#181]: https://github.com/nju-lug/NJUThesis/issues/181 [#191]: https://github.com/nju-lug/NJUThesis/issues/191 +[#192]: https://github.com/nju-lug/NJUThesis/discussions/192 [#200]: https://github.com/nju-lug/NJUThesis/discussions/200 [#202]: https://github.com/nju-lug/NJUThesis/discussions/202 [#204]: https://github.com/nju-lug/NJUThesis/issues/204 diff --git a/source/njuthesis.dtx b/source/njuthesis.dtx index 5a0f172..45c4c25 100644 --- a/source/njuthesis.dtx +++ b/source/njuthesis.dtx @@ -4357,7 +4357,7 @@ To produce the documentation run the original source files ending with \sys_if_engine_xetex:T { \RequirePackage { xeCJKfntef } - \NewDocumentCommand \njuline { m } { \CJKunderline{#1} } + \cs_new_eq:NN \njuline \CJKunderline } % \end{macrocode} % \pkg{lua-ul} 中需要在结尾使用 \tn{null} 保护尾部空白。 @@ -4365,7 +4365,7 @@ To produce the documentation run the original source files ending with \sys_if_engine_luatex:T { \RequirePackage { lua-ul } - \NewDocumentCommand \njuline { m } { \underLine{#1} \@@_null: } + \NewDocumentCommand \njuline { m } { \underLine {#1} \@@_null: } } % % \end{macrocode} @@ -8191,6 +8191,7 @@ To produce the documentation run the original source files ending with % \changes{v0.10}{2021/09/29}{新增了成果列表页面。} % \changes{v0.14}{2021/12/20}{成果列表中可突出指定作者姓名及年份。} % \changes{v1.2}{2023/04/07}{修复成果列表与章末参考文献表的冲突。} +% \changes{v1.4}{2024/03/21}{修复成果列表中文姓名加粗的问题。} % 成果列表。 % \begin{macrocode} \NewDocumentCommand \njupaperlist @@ -8199,13 +8200,17 @@ To produce the documentation run the original source files ending with \group_begin: % \end{macrocode} % 修改姓名的显示方式,使被注解的姓名可被加粗下划线表示。 +% 由于 \pkg{biblatex} 提供的 \tn{MakeCapital} 是一个 robust 命令, +% 在绘制下划线过程中无法被完全展开,我们将其替换为 +% 可被展开的 \cs{str_uppercase:f} 以避免造成错误。 % \begin{macrocode} + \cs_set_eq:NN \MakeCapital \str_uppercase:f \RenewDocumentCommand \mkbibnamegiven { m } { \ifitemannotation { thesisauthor } - { \njuline { \bf ##1 } } {##1} } + { \bfseries \njuline {##1} } {##1} } \RenewDocumentCommand \mkbibnamefamily { m } { \ifitemannotation { thesisauthor } - { \njuline { \bf ##1 } } {##1} } + { \bfseries \njuline {##1} } {##1} } % \end{macrocode} % 修改年份的显示方式,默认进行加粗。 % \begin{macrocode}