Commit 6da1090c authored by Jørgen Lind's avatar Jørgen Lind Committed by The Qt Project
Browse files

QWindowsFontEnginge uses GetGlyphOutline which seems to fail


for fonts containing embedded bitmaps.

Change-Id: I035df24d16f1c9707fff54b0920c8139fda3ddec
Reviewed-by: default avatarEskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
parent d82a17b9
Branches
Tags
No related merge requests found
Showing with 9 additions and 2 deletions
......@@ -144,8 +144,15 @@ QSGGlyphNode *QQuickTextNode::addGlyphs(const QPointF &position, const QGlyphRun
{
QSGRenderContext *sg = QQuickItemPrivate::get(m_ownerElement)->sceneGraphRenderContext();
QRawFont font = glyphs.rawFont();
bool smoothScalable = QFontDatabase().isSmoothlyScalable(font.familyName(), font.styleName());
bool preferNativeGlyphNode = m_useNativeRenderer || !smoothScalable;
bool preferNativeGlyphNode = m_useNativeRenderer;
if (!preferNativeGlyphNode) {
QRawFontPrivate *fontPriv = QRawFontPrivate::get(font);
if (fontPriv->fontEngine->hasUnreliableGlyphOutline())
preferNativeGlyphNode = true;
else
preferNativeGlyphNode = !QFontDatabase().isSmoothlyScalable(font.familyName(), font.styleName());
}
QSGGlyphNode *node = sg->sceneGraphContext()->createGlyphNode(sg, preferNativeGlyphNode);
node->setOwnerElement(m_ownerElement);
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment