Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-80359

Fonts display with incorrect weights in macOS 10.15.1 Catalina

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • P2: Important
    • None
    • 5.13.2, 5.14.0
    • GUI: Font handling
    • None
    • macOS 10.15.1
      Qt 5.13.2
    • macOS

    Description

      Fonts display with incorrect weights in macOS 10.15.1 Catalina. I've made a simple html content to see the difference. Here the same html file opened on both QTextEdit and built-in TextEdit application of macOS:

      As far as I can tell there is a problem with Light and Bold versions of the font. I put an example application project below. Also the Roboto font (by Google) and other necessary things.

      Moreover, if I remove the Roboto font from my system completely and try to register it only for my example application, via someting like that:

      const QString& fontPath = QStringLiteral("/Users/omergoktas/Desktop/Roboto");
      for (const QString& fontName : QDir(fontPath).entryList(QDir::Files))
          QFontDatabase::addApplicationFont(fontPath + '/' + fontName);
      

      This time the example application looks like that:

      Thin and Light versions are thicker this time, which is weird. Shouldn't the fonts look the same no matter how you register them? Registering them into the OS or registering them only for the application via QFontDatabase.
       
       

      Attachments

        1. difference.jpg
          difference.jpg
          579 kB
        2. qfontdatabase.jpg
          qfontdatabase.jpg
          122 kB
        3. qtfontoncatalina.zip
          0.7 kB
        4. Roboto.zip
          1.07 MB
        5. test.html
          1 kB

        Issue Links

          For Gerrit Dashboard: QTBUG-80359
          # Subject Branch Project Status CR V

          Activity

            People

              esabraha Eskil Abrahamsen Blomfeldt
              kozmon Ömer Göktaş
              Votes:
              1 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:

                Gerrit Reviews

                  There are no open Gerrit changes