diff options
Diffstat (limited to 'src/gui/text')
-rw-r--r-- | src/gui/text/qfontdatabase.cpp | 7 | ||||
-rw-r--r-- | src/gui/text/qfontengine.cpp | 4 | ||||
-rw-r--r-- | src/gui/text/qfontsubset.cpp | 6 | ||||
-rw-r--r-- | src/gui/text/qtextdocumentwriter.cpp | 4 | ||||
-rw-r--r-- | src/gui/text/qtextengine.cpp | 8 |
5 files changed, 18 insertions, 11 deletions
diff --git a/src/gui/text/qfontdatabase.cpp b/src/gui/text/qfontdatabase.cpp index 97ac604197..6da103e931 100644 --- a/src/gui/text/qfontdatabase.cpp +++ b/src/gui/text/qfontdatabase.cpp @@ -57,6 +57,7 @@ #include <stdlib.h> #include <limits.h> +#include <algorithm> // #define QFONTDATABASE_DEBUG @@ -1119,7 +1120,7 @@ QList<QFontDatabase::WritingSystem> QFontDatabase::writingSystems() const list.append(writingSystem); } } - qSort(list); + std::sort(list.begin(), list.end()); return list; } @@ -1411,7 +1412,7 @@ QList<int> QFontDatabase::pointSizes(const QString &family, if (smoothScalable) return standardSizes(); - qSort(sizes); + std::sort(sizes.begin(), sizes.end()); return sizes; } @@ -1514,7 +1515,7 @@ QList<int> QFontDatabase::smoothSizes(const QString &family, if (smoothScalable) return QFontDatabase::standardSizes(); - qSort(sizes); + std::sort(sizes.begin(), sizes.end()); return sizes; } diff --git a/src/gui/text/qfontengine.cpp b/src/gui/text/qfontengine.cpp index d8a8e34b0b..9e6b8d6ffd 100644 --- a/src/gui/text/qfontengine.cpp +++ b/src/gui/text/qfontengine.cpp @@ -50,6 +50,8 @@ #include <qendian.h> #include <private/qharfbuzz_p.h> +#include <algorithm> + QT_BEGIN_NAMESPACE static inline bool qtransform_equals_no_translate(const QTransform &a, const QTransform &b) @@ -969,7 +971,7 @@ void QFontEngine::loadKerningPairs(QFixed scalingFactor) } } end: - qSort(kerning_pairs); + std::sort(kerning_pairs.begin(), kerning_pairs.end()); // for (int i = 0; i < kerning_pairs.count(); ++i) // qDebug() << 'i' << i << "left_right" << hex << kerning_pairs.at(i).left_right; } diff --git a/src/gui/text/qfontsubset.cpp b/src/gui/text/qfontsubset.cpp index 3c39272d11..01ae5888e2 100644 --- a/src/gui/text/qfontsubset.cpp +++ b/src/gui/text/qfontsubset.cpp @@ -48,6 +48,8 @@ #include "qfontsubset_agl.cpp" +#include <algorithm> + QT_BEGIN_NAMESPACE // This map is used for symbol fonts to get the correct glyph names for the latin range @@ -998,7 +1000,7 @@ static QList<QTtfTable> generateGlyphTables(qttf_font_tables &tables, const QLis { const int max_size_small = 65536*2; QList<QTtfGlyph> glyphs = _glyphs; - qSort(glyphs); + std::sort(glyphs.begin(), glyphs.end()); Q_ASSERT(tables.maxp.numGlyphs == glyphs.at(glyphs.size()-1).index + 1); int nGlyphs = tables.maxp.numGlyphs; @@ -1076,7 +1078,7 @@ static QByteArray bindFont(const QList<QTtfTable>& _tables) { QList<QTtfTable> tables = _tables; - qSort(tables); + std::sort(tables.begin(), tables.end()); QByteArray font; const int header_size = sizeof(qint32) + 4*sizeof(quint16); diff --git a/src/gui/text/qtextdocumentwriter.cpp b/src/gui/text/qtextdocumentwriter.cpp index b4a4a07c42..a294bceacc 100644 --- a/src/gui/text/qtextdocumentwriter.cpp +++ b/src/gui/text/qtextdocumentwriter.cpp @@ -52,6 +52,8 @@ #include "qtextdocumentfragment_p.h" #include "qtextodfwriter_p.h" +#include <algorithm> + QT_BEGIN_NAMESPACE class QTextDocumentWriterPrivate @@ -366,7 +368,7 @@ QList<QByteArray> QTextDocumentWriter::supportedDocumentFormats() answer << "ODF"; #endif // QT_NO_TEXTODFWRITER - qSort(answer); + std::sort(answer.begin(), answer.end()); return answer; } diff --git a/src/gui/text/qtextengine.cpp b/src/gui/text/qtextengine.cpp index 4c2ca61d39..7a12b241e8 100644 --- a/src/gui/text/qtextengine.cpp +++ b/src/gui/text/qtextengine.cpp @@ -2770,10 +2770,10 @@ void QTextEngine::resolveAdditionalFormats() const addFormatSortedByStart.append(i); } QVarLengthArray<int, 64> addFormatSortedByEnd = addFormatSortedByStart; - qSort(addFormatSortedByStart.begin(), addFormatSortedByStart.end(), - FormatRangeComparatorByStart(specialData->addFormats)); - qSort(addFormatSortedByEnd.begin(), addFormatSortedByEnd.end(), - FormatRangeComparatorByEnd(specialData->addFormats)); + std::sort(addFormatSortedByStart.begin(), addFormatSortedByStart.end(), + FormatRangeComparatorByStart(specialData->addFormats)); + std::sort(addFormatSortedByEnd.begin(), addFormatSortedByEnd.end(), + FormatRangeComparatorByEnd(specialData->addFormats)); QVarLengthArray<int, 16> currentFormats; const int *startIt = addFormatSortedByStart.constBegin(); |