Store the font's scalability in QFontEngine.
This is an enabler to fallback to native font rendering when using a bitmap font in Qt Quick. Task-number: QTBUG-32737 Change-Id: I6d841dd5ef54d78a00f7fab9d80e9c95ff7f7b98 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>bb10
parent
e8f2c4d2cd
commit
65b12fbdb1
|
|
@ -184,6 +184,7 @@ QFontEngine *loadSingleEngine(int script,
|
|||
if (!engine) {
|
||||
engine = pfdb->fontEngine(def, QChar::Script(script), size->handle);
|
||||
if (engine) {
|
||||
engine->smoothScalable = style->smoothScalable;
|
||||
QFontCache::Key key(def,script);
|
||||
QFontCache::instance()->instance()->insertEngine(key,engine);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -208,7 +208,8 @@ Q_AUTOTEST_EXPORT QList<QFontEngine *> QFontEngine_stopCollectingEngines()
|
|||
QFontEngine::QFontEngine()
|
||||
: ref(0),
|
||||
font_(0), font_destroy_func(0),
|
||||
face_(0), face_destroy_func(0)
|
||||
face_(0), face_destroy_func(0),
|
||||
smoothScalable(false)
|
||||
{
|
||||
cache_cost = 0;
|
||||
fsType = 0;
|
||||
|
|
|
|||
|
|
@ -302,6 +302,8 @@ public:
|
|||
|
||||
inline QVariant userData() const { return m_userData; }
|
||||
|
||||
bool smoothScalable;
|
||||
|
||||
protected:
|
||||
QFixed lastRightBearing(const QGlyphLayout &glyphs, bool round = false);
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue