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

QFontDatabase does not show styles for some Arial font styles and shows empty squares for EuroRoman point size >= 64

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Not Evaluated
    • Resolution: Out of scope
    • Affects Version/s: 4.8.0
    • Fix Version/s: None
    • Labels:
      None
    • Environment:
      Main: Qt for Embedded Linux QWS
      For Comparison:
      Ubuntu 10.10 (VMWare VM)
      Windows 7 (64-bit)

      Description

      In Qt Embedded, QFontDatabase does not show the styles for any Arial Narrow, Arial Black, and Arial Unicode MS TTF fonts. Also, for EuroRoman font, it shows emptry squares for pointsizes that are greater/equal then 64.

      The attached test project and ttfonts can be used to reproduce the issues detected. By default, the program loads the ttfont files from
      /var/uf. When run, several buttons are provided for showing the font tree of the font families, styles, and smooth sizes for all the fonts
      loaded. Two buttons load Arial and Arial Narrow on demand and the font tree is re-shown with loaded fonts. Another button shows a QFontDialog that is used for camparison to QFontDatabase. The EuroRoman font file is loaded when the font tree is shown. Clicking on each font family on the font tree will draw all the smooth sizes for each style.

      After loading the font files and running the program on a embedded device, you'll will notice that Arial Narrow & Arial Black font styles will not be shown. For the EuroRoman font family, you'll notice that smooth sizes up to 42 are Ok, but size 72 is an unfilled square. I was not able to upload the Arial Unicode MS font file do to maximum upload limitation, but if you can get a copy of this font file from Windows/Linux, you'll notice that this font family/style is not shown either.

      For comparison, I compiled and ran the test program on both Ubuntu and Windows 7 machines and I got the following results inconsistancies:
      o Arial font families/styles:
       Win7: Arial Narrow and Arial Black font files show up as styles under Arial font family. Arial Unicode MS shows as different family
       Ubuntu: Arial Black & Arial Narrow appear as styles under Arial font family. Arial Unicode MS shows up as different family
       Embedded: Arial Black, Arial Narrow, and Arial Unicode MS do not appear at all. What is shown is only Arial font family with typical styles
      o EuroRoman font:
       Win7: Normal styles and all supported sizes are displayed
       Ubuntu: Shows unfilled squares for all styles and sizes no matter what. Might be the TTFont Engine since OpenOffice Word Processer shows similar results
       Embedded: Shows all styles but for point sizes 64 or greater, it shows unfilled squares

      Suggestions for QFontDatabase class: Since addApplicationFont(..) returns an Id for the font family loaded, it would be great if this same Id could be used to return the QFont for this id. Similar to QFontDatabase::font(..) but with the Id as the parameter. This would return the exact font object and then I can set the size, and other style properties as needed.

        Attachments

        1. test_ttf.zip
          9 kB
        2. ttfonts.zip
          1.90 MB
        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

            Assignee:
            Unassigned Unassigned
            Reporter:
            agonet Al Gomez
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Gerrit Reviews

                There are no open Gerrit changes