Skip to content

Commit a000a29

Browse files
committed
modify
1 parent 83ef2e0 commit a000a29

File tree

2 files changed

+9
-2
lines changed

2 files changed

+9
-2
lines changed

.readthedocs.yaml

+1
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ build:
1616
# golang: "1.19"
1717
apt_packages:
1818
- fontconfig
19+
- fonts-noto-cjk
1920

2021
# Build documentation in the "docs/" directory with Sphinx
2122
sphinx:

source/conf.py

+8-2
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,13 @@
2828

2929

3030
latex_engine = 'xelatex'
31-
latex_use_xindy = False
3231
latex_elements = {
33-
'preamble': '\\usepackage[UTF8]{ctex}\n',
32+
'preamble': r'''
33+
\usepackage{xeCJK}
34+
\setCJKmainfont[BoldFont=Noto Sans CJK TC, ItalicFont=Noto Serif CJK TC]{Noto Sans CJK TC}
35+
\setCJKsansfont{Noto Sans CJK TC}
36+
\setCJKmonofont{Noto Sans Mono CJK TC}
37+
\XeTeXlinebreaklocale "zh"
38+
\XeTeXlinebreakskip = 0pt plus 1pt
39+
''',
3440
}

0 commit comments

Comments
 (0)