Skip to content
  • Akira TAGOH's avatar
    Add 35-lang-normalize.conf · f555f50a
    Akira TAGOH authored
    This avoids a situation where the score of lang becomes lower or equal to others
    and then figures out the best font according to other properties and the order
    of family names.
    
    This typically happens only when our orthography files are the subset of lang
    in patterns. i.e. fc-match :lang=en-us to match on en.orth.
    In this case, the score is lower than the exact match (en to en) and the partial
    match (en to en-us). thus, the result of 'fc-match :lang=en-us' isn't necessarily
    same to 'fc-match :lang=en'.
    
    So 35-lang-normalize.conf contains languages only which is available as orth
    without countries and tries to update properties to match on orth exactly like:
    
      <match>
        <test name="lang" compare="contains">
          <string>en</string>
        </test>
        <edit name="lang" mode="assign" binding="same">
          <string>en</string>
        </edit>
      </match>
    
    Fixes fontconfig/fontconfig#155
    f555f50a