<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
<fontconfig>

  <!-- Set up fallback for Emmentaler fonts.
       Must come before the definition of the 'LilyPond Serif' alias. -->
  <match target="pattern">
    <test name="family" compare="contains">
      <string>Emmentaler</string>
    </test>
    <edit name="family" mode="append" binding="strong">
      <string>LilyPond Serif</string>
    </edit>
  </match>

  <!--
  Define LilyPond default fonts. Where a character doesn't exist in the
  first font listed, the next font listed will be used instead for that
  character. Also see scm/font.scm.
  -->

  <alias binding="strong">
    <family>LilyPond Serif</family>
    <prefer>
      <!-- Ghostscript (URW) font:
           gs 9.20+ includes Greek and Cyrillic glyphs. -->
      <family>C059</family>                   <!-- gs 9.20 -->
      <family>Century SchoolBook URW</family> <!-- gs 9.16 -->
      <family>Century Schoolbook L</family>   <!-- gs 9.15, 9.18, 9.19 -->
      <!-- TeX Gyre Schola:
           Latin glyphs only. Has some issues with certain characters but
           is a good fallback, mostly for Vietnamese to match URW. -->
      <family>TeX Gyre Schola</family>
      <!-- Substitute font:
           Most Unicode glyphs except CJK are included. -->
      <family>DejaVu Serif</family>
      <!-- Substitute font for Japanese, which gets used for
           building LilyPond's documentation.

           Debian GNU/Linux, Ubuntu:
               Noto Serif CJK JP in fonts-noto-cjk package
           Red Hat Fedora:
               Noto Serif JP in google-noto-serif-jp-fonts package -->
      <family>Noto Serif CJK JP</family>
      <family>Noto Serif JP</family>
    </prefer>
    <default>
      <!-- Fontconfig default serif font alias:
           For CJK glyphs etc. -->
      <family>serif</family>
    </default>
  </alias>

  <alias binding="strong">
    <family>LilyPond Sans Serif</family>
    <prefer>
      <!-- Ghostscript (URW) font:
           gs 9.16+ includes Greek and Cyrillic glyphs. -->
      <family>Nimbus Sans</family>    <!-- gs 9.20, 9.16 -->
      <family>Nimbus Sans L</family>  <!-- gs 9.15, 9.18, 9.19 -->
      <!-- TeX Gyre font:
           Latin glyphs only. Has issues with certain characters but
           provides matching extra support for extended ranges. -->
      <family>TeX Gyre Heros</family>
      <!-- Substitute font:
           Most Unicode glyphs except CJK are included. -->
      <family>DejaVu Sans</family>
    </prefer>
    <default>
      <!-- Fontconfig default san-serif font alias:
           For CJK glyphs etc. -->
      <family>sans-serif</family>
    </default>
  </alias>

  <alias binding="strong">
    <family>LilyPond Monospace</family>
    <prefer>
      <!-- Ghostscript (URW) font:
           gs 9.16+ includes Greek and Cyrillic glyphs. -->
      <family>Nimbus Mono PS</family>   <!-- gs 9.20 -->
      <family>Nimbus Mono</family>      <!-- gs 9.16, 9.18, 9.19 -->
      <family>Nimbus Mono L</family>    <!-- gs 9.15 -->
      <!-- TeX Gyre font:
           Latin glyphs only. Has issues with certain characters but
           provides matching extra support for extended ranges. -->
      <family>TeX Gyre Cursor</family>
      <!-- Substitute font:
           Most Unicode glyphs except CJK are included. -->
      <family>DejaVu Sans Mono</family>
    </prefer>
    <default>
      <!-- Fontconfig default monospace font alias:
           For CJK glyphs etc. -->
      <family>monospace</family>
    </default>
  </alias>

</fontconfig>
