Skip to content

Commit 1fb9065

Browse files
committed
Font and CI
1 parent 3558645 commit 1fb9065

File tree

2 files changed

+25
-2
lines changed

2 files changed

+25
-2
lines changed

.github/workflows/build.yaml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: Render paper.pdf
2+
on: push
3+
jobs:
4+
render-paper:
5+
runs-on: ubuntu-latest
6+
steps:
7+
- uses: actions/checkout@v4
8+
- uses: typst-community/setup-typst@v3
9+
10+
- name: Get Source Han Serif font
11+
run: |
12+
wget https://github.com/adobe-fonts/source-han-serif/releases/download/2.002R/09_SourceHanSerifSC.zip
13+
unzip 09_SourceHanSerifSC.zip
14+
15+
wget https://cdn.jsdelivr.net/npm/katex@0.16.9/dist/fonts/KaTeX_Caligraphic-Regular.ttf
16+
mv KaTeX_Caligraphic-Regular.ttf OTF/SimplifiedChinese
17+
wget https://cdn.jsdelivr.net/npm/katex@0.16.9/dist/fonts/KaTeX_Caligraphic-Bold.ttf
18+
mv KaTeX_Caligraphic-Bold.ttf OTF/SimplifiedChinese
19+
- run: typst compile main.typ model.pdf --font-path ./OTF/SimplifiedChinese/
20+
- uses: actions/upload-artifact@v4
21+
with:
22+
name: model
23+
path: model.pdf

common.typ

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,8 @@
3131
#let definition = thmstyle("theorem", "定义")
3232
#let proof = thmproof(
3333
"proof", "证明",
34-
separator: [. ],
35-
titlefmt: text.with(font: ("Latin Modern Roman", "Kaiti SC")),
34+
separator: h(0em),
35+
titlefmt: box.with(stroke: 0.5pt, outset: (top: 0.25em, bottom: 0.25em, left: 0.1em, right: 0.1em)),
3636
inset: (left: 0em, right: 0em),
3737
)
3838

0 commit comments

Comments
 (0)