小编Oma*_*ara的帖子

使用 fontconfig 更改某种语言/脚本字符的字体系列?

我在 Arch Linux,Deepin 桌面。我使用Noto Serif作为我的标准字体,但我不喜欢它的阿拉伯字符。所以我的目标是为阿拉伯字符使用另一种字体。

这是我尝试过的。我创建了一个新的配置文件,/etc/fonts/conf.d/内容如下:

<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
<fontconfig>
    <match target="pattern">
        <test name="lang" compare="contains">
            <string>ar</string>
        </test>
        <test qual="any" name="family">
            <string>sans-serif</string>
        </test>
        <edit name="family" mode="prepend" binding="strong">
            <string>Noto Naskh Arabic</string>
        </edit>
    </match>

    <match target="pattern">
        <test name="lang" compare="contains">
            <string>ar</string>
        </test>
        <test qual="any" name="family">
            <string>serif</string>
        </test>
        <edit name="family" mode="prepend" binding="strong">
            <string>Noto Naskh Arabic</string>
        </edit>
    </match>
</fontconfig>
Run Code Online (Sandbox Code Playgroud)

我接着跑fc-cache -r。但这不起作用,相同的字体仍在使用中,并且像以前一样运行fc-match返回NotoSerif-Regular.ttf: "Noto Serif" "Regular"

linux fonts fontconfig deepin

9
推荐指数
1
解决办法
1946
查看次数

打开多个应用程序时 ALSA 不起作用

我正在编写一些与声音相关的 python 程序,所以我使用了使用 PortAudio 库的 SoundDevice python 模块。我在使用 deepin 桌面的 arch linux 上。

如果我只是打开计算机并打印可用的设备,我会得到:

   0 HDA Intel PCH: ALC887-VD Analog (hw:0,0), ALSA (2 in, 2 out)
   1 HDA Intel PCH: ALC887-VD Digital (hw:0,1), ALSA (0 in, 2 out)
   2 HDA Intel PCH: ALC887-VD Alt Analog (hw:0,2), ALSA (2 in, 0 out)
   3 HDA ATI HDMI: 0 (hw:1,3), ALSA (0 in, 8 out)
   4 sysdefault, ALSA (128 in, 128 out)
   5 front, ALSA (0 in, 2 out)
   6 surround40, ALSA (0 …
Run Code Online (Sandbox Code Playgroud)

arch-linux alsa audio pulseaudio deepin

4
推荐指数
1
解决办法
4464
查看次数

标签 统计

deepin ×2

alsa ×1

arch-linux ×1

audio ×1

fontconfig ×1

fonts ×1

linux ×1

pulseaudio ×1