Fix build with -no-directwrite
QWindowsFontDatabaseBase::invalidate() was defined inside an the declaration was not. Since the font file loader is only protected by QT_CONFIG(directwrite), we move it out from the previous block and add an #if for the contents instead. Change-Id: Iedc02cceb15fe3d25d21b49af1486659a4d6373b Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> (cherry picked from commit 0d1ac449bbc38aee4341dd47189de901860d7870) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
This commit is contained in:
parent
96d03949d2
commit
1b90af74dd
@ -710,6 +710,13 @@ QFont QWindowsFontDatabaseBase::systemDefaultFont()
|
|||||||
return systemFont;
|
return systemFont;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void QWindowsFontDatabaseBase::invalidate()
|
||||||
|
{
|
||||||
|
#if QT_CONFIG(directwrite)
|
||||||
|
m_fontFileLoader.reset(nullptr);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
#if QT_CONFIG(directwrite) && QT_CONFIG(direct2d)
|
#if QT_CONFIG(directwrite) && QT_CONFIG(direct2d)
|
||||||
IDWriteFontFace *QWindowsFontDatabaseBase::createDirectWriteFace(const QByteArray &fontData)
|
IDWriteFontFace *QWindowsFontDatabaseBase::createDirectWriteFace(const QByteArray &fontData)
|
||||||
{
|
{
|
||||||
@ -719,11 +726,6 @@ IDWriteFontFace *QWindowsFontDatabaseBase::createDirectWriteFace(const QByteArra
|
|||||||
return faces.isEmpty() ? nullptr : faces.first();
|
return faces.isEmpty() ? nullptr : faces.first();
|
||||||
}
|
}
|
||||||
|
|
||||||
void QWindowsFontDatabaseBase::invalidate()
|
|
||||||
{
|
|
||||||
m_fontFileLoader.reset(nullptr);
|
|
||||||
}
|
|
||||||
|
|
||||||
QList<IDWriteFontFace *> QWindowsFontDatabaseBase::createDirectWriteFaces(const QByteArray &fontData,
|
QList<IDWriteFontFace *> QWindowsFontDatabaseBase::createDirectWriteFaces(const QByteArray &fontData,
|
||||||
bool queryVariations) const
|
bool queryVariations) const
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user