Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Colored artifacts in font antialiasing
Forum Updated to NodeBB v4.3 + New Features

Colored artifacts in font antialiasing

Scheduled Pinned Locked Moved Unsolved General and Desktop
1 Posts 1 Posters 486 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • R Offline
    R Offline
    rrendec
    wrote on last edited by
    #1

    I'm using Qt 5.7.1 on linux (Fedora 25) with MATE Desktop Environment. I'm experiencing a strange font rendering issue: I can see some colored artifacts around antialiased font letters. It looks as if fonts were rendered without type hinting and the specific blending around the letter edges were colored. The behavior is inconsistent with Qt 4 and GTK.

    I'm using qt5ct and the GTK style (provided by the qt5-qtstyleplugins package) - not sure if this makes any difference.

    I have a custom per-user fontconfig configuration that looks like this:

    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE fontconfig SYSTEM "fonts.dtd">
    <fontconfig>
        <match target="font">
            <edit name="antialias" mode="assign">
                <bool>true</bool>
            </edit>
            <edit name="hinting" mode="assign">
                <bool>true</bool>
            </edit>
            <edit name="hintstyle" mode="assign">
                <const>hintfull</const>
            </edit>
            <edit name="rgba" mode="assign">
                <const>rgb</const>
            </edit>
            <edit name="autohint" mode="assign">
                <bool>false</bool>
            </edit>
            <edit name="lcdfilter" mode="assign">
                <const>lcdnone</const>
            </edit>
        </match>
    </fontconfig>
    

    Xft settings (as returned by "xrdb -q") are the following:

    Xft.antialias:	1
    Xft.dpi:	96.1025390625
    Xft.hinting:	1
    Xft.hintstyle:	hintfull
    Xft.lcdfilter:	none
    Xft.rgba:	none
    

    What I expect instead is full type hinting, which means that "straight line" characters (such as "L" or "E") should have no pixel blending around them (they should be drawn the same as their non-antialiased version). Also, where antialiasing must occur (i.e. curved lines), I expect the antialiasing to be grayscale.

    Any suggestion what settings may affect this behavior and what I could try in order to get the behavior that I want? Thank you!

    1 Reply Last reply
    0

    • Login

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Get Qt Extensions
    • Unsolved