This commit is contained in:
2025-12-05 00:10:27 +01:00
parent 3e56a80ee2
commit b4e8dcd75a
3 changed files with 86 additions and 9 deletions

View File

@@ -100,11 +100,4 @@ Based on [noelsimbolon/mpv-config](https://github.com/noelsimbolon/mpv-config.gi
## Fonts
including:
- Maple Mono NF CN
- MesloLGM Nerd Font (& Mono)
- WenQuanYi Micro Hei
- Sour Gummy
- Noto Sans
- ...
See [fontconfig.md](https://github.com/Uyanide/dotfiles/blob/main/memo/fontconfig.md).

View File

@@ -7,7 +7,7 @@
/* Font(s) */
* {
/* main font icons CJK fallback */
font-family: 'Sour Gummy Light', 'Meslo LGM Nerd Font Mono', 'WenQuanYi Micro Hei', 'Noto Sans', sans-serif;
font-family: 'Sour Gummy Light', 'Meslo LGM Nerd Font Mono', 'Sarasa UI SC', 'Noto Sans', sans-serif;
font-size: 16px;
}

84
memo/fontconfig.md Normal file
View File

@@ -0,0 +1,84 @@
### Font packages (involved in fontconfig)
- ttf-sarasa-gothi
- ttf-symbola (AUR)
- noto-fonts
- noto-fonts-cjk
- noto-fonts-emoji
- ttf-nerd-fonts-symbols
- maplemono-nf-cn (AUR)
### Other fonts (used but not involved in fontconfig)
- Sour Gummy
- Font Awesome 6 Free
- Meslo LGM Nerd Font Mono
### Fontconfig configuration
> `~/.config/fontconfig/fonts.conf`
```xml
<?xml version='1.0'?>
<!DOCTYPE fontconfig SYSTEM 'urn:fontconfig:fonts.dtd'>
<fontconfig>
<match target="font">
<edit mode="assign" name="antialias"><bool>true</bool></edit>
<edit mode="assign" name="hinting"><bool>true</bool></edit>
<edit mode="assign" name="hintstyle"><const>hintslight</const></edit>
<edit mode="assign" name="rgba"><const>none</const></edit>
<edit mode="assign" name="embeddedbitmap"><bool>false</bool></edit>
<edit mode="assign" name="lcdfilter"><const>lcddefault</const></edit>
</match>
<!-- For danmuku -->
<match target="pattern">
<test name="family">
<string>Noto Sans CJK SC</string></test>
<edit name="family" mode="append">
<string>Symbola</string>
</edit>
</match>
<alias>
<family>sans-serif</family>
<prefer>
<family>Sarasa UI SC</family>
<family>Sarasa UI J</family>
<family>Noto color Emoji</family>
<family>Symbols Nerd Font</family>
</prefer>
</alias>
<alias>
<family>system-ui</family>
<prefer>
<family>Sarasa UI SC</family>
<family>Noto Color Emoji</family>
<family>Symbols Nerd Font</family>
</prefer>
</alias>
<alias>
<family>serif</family>
<prefer>
<family>Noto Serif</family>
<family>Noto Serif CJK SC</family>
<family>Noto Serif CJK JP</family>
<family>Noto Color Emoji</family>
<family>Symbols Nerd Font</family>
</prefer>
</alias>
<alias>
<family>monospace</family>
<prefer>
<family>Maple Mono NF CN</family>
<family>Sarasa Mono SC</family>
<family>Sarasa Mono J</family>
<family>Noto Color Emoji</family>
<family>Symbols Nerd Font</family>
</prefer>
</alias>
</fontconfig>
```