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

Ugly rendering of large fonts

asked 2014-12-19 12:10:57 +0300

Jonni gravatar image

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 Screen-Message app

screenshot from Planning poker app

screenshot from Planning poker app

edit retag flag offensive 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?

pichlo ( 2014-12-21 10:33:24 +0300 )edit

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.

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

1 Answer

Sort by » oldest newest most voted

answered 2015-01-05 11:47:15 +0300

sletta gravatar image

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.

edit flag offensive delete publish link 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?

Nicd ( 2015-02-08 14:24:09 +0300 )edit

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.

sletta ( 2015-02-09 13:54:33 +0300 )edit

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. :)

Nicd ( 2015-02-09 14:12:01 +0300 )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...

Aros ( 2015-05-23 20:54:25 +0300 )edit
Login/Signup to Answer

Question tools



Asked: 2014-12-19 12:10:57 +0300

Seen: 1,362 times

Last updated: Jan 05 '15