Skip to content

Commit c87a683

Browse files
authored
[11_40] Tune font substitution for roman cjk and Stix cjk
1 parent 01b6600 commit c87a683

File tree

2 files changed

+8
-11
lines changed

2 files changed

+8
-11
lines changed

TeXmacs/fonts/font-substitutions.scm

+5-6
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
((FandolSong sansserif) (FandolHei))
22
((FandolSong typewriter) (FandolFang))
33
((FandolSong italic) (FandolKai))
4+
45
((Hiragino\ Mincho\ Pro sansserif) (Hiragino\ Kaku\ Gothic\ Pro))
56
((Hiragino\ Mincho\ ProN sansserif) (Hiragino\ Kaku\ Gothic\ ProN))
67
((IPAMincho bold) (IPAGothic))
@@ -11,6 +12,7 @@
1112
((MS\ Mincho sansserif) (MS\ Gothic))
1213
((Sazanami\ Mincho bold) (Sazanami\ Gothic))
1314
((Sazanami\ Mincho sansserif) (Sazanami\ Gothic))
15+
1416
((SimSun bold) (SimHei))
1517
((SimSun sansserif) (SimHei))
1618
((SimSun italic) (KaiTi_GB2312))
@@ -30,12 +32,9 @@
3032
((UnBatang italic) (UnGraphic))
3133
((UnBatang typewriter) (UnGungseo))
3234

33-
((concrete cjk) (FandolSong))
34-
((concrete cjk) (SimSun))
35-
((roman cjk) (FandolSong))
36-
((roman cjk) (SimSun))
37-
((Stix cjk) (FandolSong))
38-
((Stix cjk) (SimSun))
35+
((concrete cjk) (Noto\ CJK\ SC))
36+
((roman cjk) (Noto\ CJK\ SC))
37+
((Stix cjk) (Noto\ CJK\ SC))
3938

4039
((Bodoni\ 72 smallcaps) (Bodoni\ 72\ Smallcaps))
4140
((Bodoni\ 72\ Oldstyle smallcaps) (Bodoni\ 72\ Smallcaps))

src/Graphics/Fonts/font_database.cpp

+3-5
Original file line numberDiff line numberDiff line change
@@ -286,11 +286,9 @@ font_database_load_substitutions (url u) {
286286
is_atomic (t[i][0][0]) && is_atomic (t[i][1][0])) {
287287
string key= t[i][0][0]->label;
288288
string im = t[i][1][0]->label;
289-
if (N (font_database_styles (im, font_table)) != 0) {
290-
if (!font_substitutions->contains (key))
291-
font_substitutions (key)= tree (TUPLE);
292-
font_substitutions (key) << t[i];
293-
}
289+
if (!font_substitutions->contains (key))
290+
font_substitutions (key)= tree (TUPLE);
291+
font_substitutions (key) << t[i];
294292
}
295293
}
296294
}

0 commit comments

Comments
 (0)