Bug 1585538 - [zh_CN][zh_TW] unexpected result for fc-match monospace.
Summary: [zh_CN][zh_TW] unexpected result for fc-match monospace.
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Fedora
Classification: Fedora
Component: fontconfig
Version: 28
Hardware: x86_64
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Akira TAGOH
QA Contact: Fedora Extras Quality Assurance
Lijun Li
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-06-04 02:49 UTC by Lijun Li
Modified: 2018-06-04 06:27 UTC (History)
12 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-06-04 05:22:23 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Lijun Li 2018-06-04 02:49:27 UTC
Description of problem:
[zh_CN][zh_TW] unexpected result for fc-match monospace.

Version-Release number of selected component (if applicable):
fedora28

How reproducible:
100%

Steps to Reproduce:
1. Open terminal.
2. Run 
$ LANG=zh_CN.UTF-8 fc-match monospace
$ LANG=zh_TW.UTF-8 fc-match monospace


Actual results:
$ LANG=zh_CN.UTF-8 fc-match monospace
DejaVuSansMono.ttf: "DejaVu Sans Mono" "Book"
$ LANG=zh_TW.UTF-8 fc-match monospace
DejaVuSansMono.ttf: "DejaVu Sans Mono" "Book"

Expected results:
Source Han Sans CN
Source Han Sans TW

Additional info:

Comment 1 Akira TAGOH 2018-06-04 05:22:23 UTC
This is the expected result by adobe-source-han-sans-cn-fonts:

    <match>
        <test name="lang">
            <string>zh-cn</string>
        </test>
        <test name="family">
            <string>monospace</string>
        </test>
        <edit name="family" mode="prepend">
        <string>Source Han Sans CN</string>
        <string>Source Han Sans TW</string>
        </edit>
        <edit name="family" mode="prepend" binding="strong">
        <string>DejaVu Sans Mono</string>
        </edit>
    </match>

DejaVu Sans Mono is added as strong binding so it is used prior than any Chinese fonts.

Comment 2 Akira TAGOH 2018-06-04 05:23:33 UTC
just to clarify for zh_TW, it comes from adobe-souruce-han-sans-tw-fonts:

    <match>
        <test name="lang">
            <string>zh-tw</string>
        </test>
        <test name="family">
            <string>monospace</string>
        </test>
        <edit name="family" mode="prepend">
        <string>Source Han Sans TW</string>
        <string>Source Han Sans CN</string>
        </edit>
        <edit name="family" mode="prepend" binding="strong">
        <string>DejaVu Sans Mono</string>
        </edit>
    </match>

Comment 3 Lijun Li 2018-06-04 06:27:58 UTC
Ah, okay, I got the reference from:
https://tagoh.fedorapeople.org/fonts/f26-defaultfonts-fcquery.html


Note You need to log in before you can comment on or make changes to this bug.