Details
-
Bug
-
Resolution: Done
-
P1: Critical
-
5.0.0
-
None
-
Mac OS 10.6.8, Mac OS 10.7.1
-
89cfe9eb01ad75c14121dbd6038b7c791226acf1, d281f94c30aa15765c9c1ec0a613311514033076 (4.8)
Description
From the output of Qt.fontFamilies(), it appears that the QML engine is only finding a limited subset of the installed fonts. Although Tahoma is an installed font on my system, the Text element is unable to render text with this font.
It seems this cannot be fixed by using a FontLoader either. E.g. below, the FontLoader loads the attached RoundStyleSimple.ttf (from openfontlibrary.org) and reports its status as FontLoader.Ready, but the text is not rendered with this font.
Both text elements in the example below appear to be rendered with the default font.
import QtQuick 2.0 Row { Text { font.family: "Tahoma" font.pixelSize: 30 text: "Hello" } Text { font.family: loader.name font.pixelSize: 30 text: "Hello" } FontLoader { id: loader source: "RoundStyleSimple.ttf" onStatusChanged: print("FontLoader status:", status) Component.onCompleted: print("FontLoader starting status:", status) } Component.onCompleted: { print("Found fonts:", Qt.fontFamilies()) } }