<!DOCTYPE html><html><head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  </head>
  <body>
    <br>
    For the fonts like sans serif, FX just asks fontconfig for the list
    of fonts that make it up for the current locale.<br>
    Garbled text isn't likely to be due to a font selection difference.
    More likely a bug in mapping to the correct font<br>
    so I am not sure API methods on Font will help.<br>
    <br>
    Also canDisplay() is a tricky one as I've discussed this recently on
    the client-libs list.<br>
    It was designed to report what glyphs *that physical font* supports.<br>
    Reporting pseudo-glyphs, and glyphs from fall backs distort it.<br>
    <br>
    -phil.<br>
    <br>
    <div class="moz-cite-prefix">On 5/12/25 8:44 AM, Glavo wrote:<br>
    </div>
    <blockquote type="cite" cite="mid:CAJL5A3mZg6F8q7fy0CKWAcNtJ+gciCihiNSckjKLFMeeauy8JQ@mail.gmail.com">
      
      <div dir="ltr">
        <div dir="ltr">
          <div dir="ltr">
            <div dir="ltr">
              <div dir="ltr">I hope this issue gets more attention. Can
                anyone take a look at this email?</div>
              <div dir="ltr"><br>
              </div>
              <div dir="ltr">Glavo</div>
            </div>
          </div>
        </div>
      </div>
      <br>
      <div class="gmail_quote gmail_quote_container">
        <div dir="ltr" class="gmail_attr">On Sun, May 4, 2025 at 4:18 PM
          Glavo <<a href="mailto:zjx001202@gmail.com" moz-do-not-send="true" class="moz-txt-link-freetext">zjx001202@gmail.com</a>>
          wrote:<br>
        </div>
        <blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
          <div dir="ltr">Hi,<br>
            <div><br>
            </div>
            <div>We have noticed that JavaFX's strategy for selecting
              default fonts can sometimes be quite odd, <br>
              and at times it doesn't properly follow the fontconfig
              configuration. As a result, <br>
              we frequently receive feedback from Linux users reporting
              that all Chinese characters appear as garbled text.<br>
              This[1] is one piece of the feedback that contains useful
              information.<br>
              <br>
              We are not sure whether these problems can be solved.
              However, we've noticed that unlike AWT,<br>
              javafx.scene.text.Font API lacks most useful methods. For
              example, it does not provide <br>
              canDisplay/canDisplayUpTo methods, making it impossible to
              determine whether <br>
              a font can render a given text. I found that
              CharToGlyphMapper actually contains <br>
              the corresponding method, but it is not exposed through
              the Font API.<br>
              <br>
              So is it possible to add more useful API methods to Font,
              like AWT does?<br>
              This will be of great help to us.</div>
            <div><br>
            </div>
            <div>Glavo</div>
            <div><br>
            </div>
            <div>[1]: <a href="https://github.com/HMCL-dev/HMCL/issues/3104" target="_blank" moz-do-not-send="true" class="moz-txt-link-freetext">https://github.com/HMCL-dev/HMCL/issues/3104</a></div>
          </div>
        </blockquote>
      </div>
    </blockquote>
    <br>
  </body>
</html>