We have moved to a new Sailfish OS Forum. Please start new discussions there.

# Ugly rendering of large fonts

When an application uses a large font the font rendering dosn't look too nice. All curves come very jagged. Below is an example from two different applications. The same problem can also be witnessed in the lockscreen clock, but the as the font is a bit smaller there, the problem is not so clearly visible.

Is there is something an app developer could set in the code to make the redering more smooth? Or is this a problem in the system libraries?

screenshot from Screen-Message app

screenshot from Planning poker app

edit retag close delete

Looks like a font issue, in which case there is nothing the app developer can do :( Have the fonts been dumbed down to save a little space?

( 2014-12-21 10:33:24 +0200 )edit
1

I just have to comment here. Large digits on lockscreen clock are terrible. Their jagged edges are obvious even from the normal viewing distance (I must admit that I have good eyesight though). If there is something that can be done about it, it would be great. In case of the lockscreen clock, using bitmap glyphs for 10 digits and ":" divider won't consume a lot more memory, and results will be much more pleasant to the eye.

( 2015-03-06 14:35:53 +0200 )edit

Sort by » oldest newest most voted

This is a know side effect of the distance field rendering technique used for font rendering by default on the device. In the QML, you should be able to switch to the rendering type by changing http://doc.qt.io/qt-5/qml-qtquick-text.html#renderType-prop to "NativeRendering". This will switch the rendering to use bitmap glyphs which don't deteriorate for large sizes (though they will consume more memory).

Ideally, Qt Quick should be able to handle larger font sizes by creating bigger distance fields on the fly or switching its rendering strategy to something else.

more

I'm unable to make this work. Setting renderType to either Text.QtRendering or Text.NativeRendering seems to have no effect whatsoever. Is there something else I need to do?

( 2015-02-08 14:24:09 +0200 )edit
2

You are right, we're missing the Qt patch that allows overriding the default renderType. The only option then is to force the application to always use non-distancefield based text by setting QML_DISABLE_DISTANCEFIELD=1 in the environment before Qt Quick is initialized. I'll see about getting that patch backported.

( 2015-02-09 13:54:33 +0200 )edit
1

When QML_DISABLE_DISTANCEFIELD=1 is on, the big characters are not antialiased so they are ugly. You might want to look at that if you backport the patch. :)

( 2015-02-09 14:12:01 +0200 )edit

And what should I do if I need to use distance field rendering (because of the fluent animation involving resizing the text) and really big fonts? It really looks ugly and have some nasty artifacts. There should be a way to increase the distance field map resoultion...

( 2015-05-23 20:54:25 +0200 )edit