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

Improve QFont::defaultFamily() for X11 on fontconfig-enabled configurations

XMLWordPrintable

    • Icon: Suggestion Suggestion
    • Resolution: Unresolved
    • Icon: P3: Somewhat important P3: Somewhat important
    • None
    • 4.0.0
    • GUI: Font handling
    • None
    • X11

      This suggestion comes after QTBUG-20973 which after discussion with Tor Arne has been closed. I propose improving QFont::defaultFamily() for X11 on fontconfig-enabled configurations (is it supported to not have fontconfig on X11?). From what I found, fontconfig is able to provide nice default fonts for families "sans-serif", "serif", "monospace", "cursive", and "fantasy". Thus I propose changing (at least some of) hardcoded values in QFont::defaultFamily() for X11 so that values that came from FontConfig matching process are returned.

      On my particular system, results for "monospace", "cursive", and "fantasy" are the same as the currently hardcoded families. For "sans-serif" and "serif" I'm getting "DejaVu Sans" and "DejaVu Serif", respectively, instead of ugly pcf fonts or even Nimbus fonts. Note that this problem with Qt has been even reported long time ago to Ubuntu[1].

      It would be very nice if it could be changed in Qt 4.8, at least to avoid possible problems that some users might have, as I had with QTBUG-20973.

      [1] https://bugs.launchpad.net/ubuntu/+source/qt4-x11/+bug/209358

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

            Unassigned Unassigned
            beevvy Bartosz Brachaczek
            Votes:
            2 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:

                There are no open Gerrit changes