summaryrefslogtreecommitdiffstats
path: root/src/gui
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui')
-rw-r--r--src/gui/configure.cmake7
-rw-r--r--src/gui/text/qrawfont.cpp9
-rw-r--r--src/gui/text/qrawfont.h13
3 files changed, 16 insertions, 13 deletions
diff --git a/src/gui/configure.cmake b/src/gui/configure.cmake
index b14f7e74ad2..e34f4d8b30a 100644
--- a/src/gui/configure.cmake
+++ b/src/gui/configure.cmake
@@ -28,8 +28,11 @@ set_property(CACHE INPUT_libpng PROPERTY STRINGS undefined no qt system)
#### Libraries
-qt_set01(X11_SUPPORTED LINUX OR HPUX OR FREEBSD OR NETBSD OR OPENBSD OR SOLARIS OR
- HURD)
+if(LINUX OR HPUX OR FREEBSD OR NETBSD OR OPENBSD OR SOLARIS OR HURD)
+ set(X11_SUPPORTED 1)
+else()
+ set(X11_SUPPORTED 0)
+endif()
qt_feature_vcpkg_scope(gui)
qt_find_package(ATSPI2 MODULE PROVIDED_TARGETS PkgConfig::ATSPI2 MODULE_NAME gui QMAKE_LIB atspi)
qt_find_package(DirectFB PROVIDED_TARGETS PkgConfig::DirectFB MODULE_NAME gui QMAKE_LIB directfb)
diff --git a/src/gui/text/qrawfont.cpp b/src/gui/text/qrawfont.cpp
index 9eb3b62443c..7acc3c5218c 100644
--- a/src/gui/text/qrawfont.cpp
+++ b/src/gui/text/qrawfont.cpp
@@ -554,7 +554,6 @@ bool QRawFont::glyphIndexesForChars(const QChar *chars, int numChars, quint32 *g
}
/*!
- \fn QList<QPointF> QRawFont::advancesForGlyphIndexes(const QList<quint32> &glyphIndexes, LayoutFlags layoutFlags) const
\since 5.1
Returns the QRawFont's advances for each of the \a glyphIndexes in pixel units. The advances
@@ -570,6 +569,14 @@ bool QRawFont::glyphIndexesForChars(const QChar *chars, int numChars, quint32 *g
\sa QTextLine::horizontalAdvance(), QFontMetricsF::horizontalAdvance(), QTextLayout::glyphRuns()
*/
+QList<QPointF> QRawFont::advancesForGlyphIndexes(const QList<quint32> &glyphIndexes, QRawFont::LayoutFlags layoutFlags) const
+{
+ QList<QPointF> advances(glyphIndexes.size());
+ if (advancesForGlyphIndexes(glyphIndexes.constData(), advances.data(), int(glyphIndexes.size()), layoutFlags))
+ return advances;
+ return QList<QPointF>();
+}
+
/*!
\fn QList<QPointF> QRawFont::advancesForGlyphIndexes(const QList<quint32> &glyphIndexes) const
diff --git a/src/gui/text/qrawfont.h b/src/gui/text/qrawfont.h
index d0bed84a68a..f13f04ebe37 100644
--- a/src/gui/text/qrawfont.h
+++ b/src/gui/text/qrawfont.h
@@ -65,8 +65,8 @@ public:
QList<quint32> glyphIndexesForString(const QString &text) const;
inline QList<QPointF> advancesForGlyphIndexes(const QList<quint32> &glyphIndexes) const;
- inline QList<QPointF> advancesForGlyphIndexes(const QList<quint32> &glyphIndexes,
- LayoutFlags layoutFlags) const;
+ QList<QPointF> advancesForGlyphIndexes(const QList<quint32> &glyphIndexes,
+ LayoutFlags layoutFlags) const;
bool glyphIndexesForChars(const QChar *chars, int numChars, quint32 *glyphIndexes, int *numGlyphs) const;
bool advancesForGlyphIndexes(const quint32 *glyphIndexes, QPointF *advances, int numGlyphs) const;
bool advancesForGlyphIndexes(const quint32 *glyphIndexes, QPointF *advances, int numGlyphs, LayoutFlags layoutFlags) const;
@@ -128,14 +128,7 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QRawFont::LayoutFlags)
Q_GUI_EXPORT size_t qHash(const QRawFont &font, size_t seed = 0) noexcept;
-inline QList<QPointF> QRawFont::advancesForGlyphIndexes(const QList<quint32> &glyphIndexes,
- QRawFont::LayoutFlags layoutFlags) const
-{
- QList<QPointF> advances(glyphIndexes.size());
- if (advancesForGlyphIndexes(glyphIndexes.constData(), advances.data(), int(glyphIndexes.size()), layoutFlags))
- return advances;
- return QList<QPointF>();
-}
+
inline QList<QPointF> QRawFont::advancesForGlyphIndexes(const QList<quint32> &glyphIndexes) const
{