Skip to content

Commit

Permalink
refactor!: remove searching for STXihei due to poor performance.
Browse files Browse the repository at this point in the history
  • Loading branch information
fky2015 committed Jul 4, 2022
1 parent 3c42300 commit 26d715e
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 8 deletions.
1 change: 1 addition & 0 deletions templates/paper-translation/main.tex
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
},
cover = {
headerImage = images/header.png,
xiheiFont = STXIHEI.TTF,
},
info = {
title = 北京理工大学本科生毕业设计(论文)题目,
Expand Down
Binary file added templates/undergraduate-thesis-en/STXIHEI.TTF
Binary file not shown.
1 change: 1 addition & 0 deletions templates/undergraduate-thesis-en/main.tex
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
},
cover = {
headerImage = images/header.png,
xiheiFont = STXIHEI.TTF,
},
info = {
TITLE = Your Thesis Title,
Expand Down
11 changes: 3 additions & 8 deletions templates/undergraduate-thesis/bitundergrad.cls
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@
date .tl_set:N = \l_bit_coverdate_tl,
headerImage .tl_set:N = \l_bit_coverheaderimage_tl,
xiheiFont .tl_set:N = \l_@@_cover_xihei_font_path_tl,
xiheiFont .default:n = {STXihei},
}

\keys_define:nn { bitundergrad / info }
Expand Down Expand Up @@ -124,15 +125,9 @@
\int_compare:nNnTF {\g_@@_thesis_type_int} < {3}
{
\tl_if_blank:VTF \l_@@_cover_xihei_font_path_tl {
\IfFontExistsTF{STXihei}{
\setCJKfamilyfont{xihei}[AutoFakeBold,AutoFakeSlant]{STXihei}
}{
\IfFontExistsTF{STXIHEI.TTF}{
\setCJKfamilyfont{xihei}[AutoFakeBold,AutoFakeSlant]{STXIHEI.TTF}
}{}
}

} {
\setCJKfamilyfont{xihei}[AutoFakeBold,AutoFakeSlant]{[\l_@@_cover_xihei_font_path_tl]}
\setCJKfamilyfont{xihei}[AutoFakeBold,AutoFakeSlant]{\l_@@_cover_xihei_font_path_tl}
}

\tl_set:Nn \g_@@_toc_title_tl {目\quad 录}
Expand Down
2 changes: 2 additions & 0 deletions templates/undergraduate-thesis/main.tex
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@
\BITUndergraduateThesisSetup{
cover = {
headerImage = images/header.png,
% 在封面标题中使用思源黑体,使用此选项可以保证与 Word 封面标题的字体一致。
xiheiFont = STXIHEI.TTF,
},
info = {
title = 北京理工大学本科生毕业设计(论文)题目,
Expand Down

0 comments on commit 26d715e

Please sign in to comment.