diff --git a/src/gui/text/qtextengine.cpp b/src/gui/text/qtextengine.cpp index 3a537fb58..ecbbbf536 100644 --- a/src/gui/text/qtextengine.cpp +++ b/src/gui/text/qtextengine.cpp @@ -1133,7 +1133,7 @@ void QTextEngine::resolveAdditionalFormats() const QTextFormatCollection *collection = this->formats(); specialData->resolvedFormatIndices.clear(); - QVarLengthArray indices(layoutData->items.count()); + QStdVector indices(layoutData->items.count()); for (int i = 0; i < layoutData->items.count(); ++i) { QTextCharFormat f = format(&layoutData->items.at(i)); indices[i] = collection->indexForFormat(f); diff --git a/src/gui/text/qtextengine_p.h b/src/gui/text/qtextengine_p.h index 05a407f3f..4ee8530f8 100644 --- a/src/gui/text/qtextengine_p.h +++ b/src/gui/text/qtextengine_p.h @@ -33,7 +33,7 @@ // We mean it. // -#include "qvarlengtharray.h" +#include "qstdcontainers_p.h" #include "qfont_p.h" #include "qpaintengine.h" #include "qtextdocument_p.h" @@ -176,10 +176,10 @@ struct QGlyphLayout void grow(char *address, int totalGlyphs); }; -class QVarLengthGlyphLayoutArray : private QVarLengthArray, public QGlyphLayout +class QVarLengthGlyphLayoutArray : private QStdVector, public QGlyphLayout { private: - typedef QVarLengthArray Array; + typedef QStdVector Array; public: QVarLengthGlyphLayoutArray(int totalGlyphs) : Array(QSPACEFORGLYPHS(totalGlyphs) / QT_POINTER_SIZE + 1) @@ -258,7 +258,7 @@ struct Q_AUTOTEST_EXPORT QScriptItem QFixed height() const { return ascent + descent + 1; } }; -typedef QVarLengthArray QScriptItemArray; +typedef QVector QScriptItemArray; struct Q_AUTOTEST_EXPORT QScriptLine { @@ -299,7 +299,7 @@ inline void QScriptLine::operator+=(const QScriptLine &other) length += other.length; } -typedef QVarLengthArray QScriptLineArray; +typedef QStdVector QScriptLineArray; class QFontPrivate; class QTextFormatCollection; @@ -441,8 +441,8 @@ public: struct SpecialData { QList addFormats; - QVarLengthArray addFormatIndices; - QVarLengthArray resolvedFormatIndices; + QStdVector addFormatIndices; + QStdVector resolvedFormatIndices; }; SpecialData *specialData;