diff options
| author | Tarja Sundqvist <tarja.sundqvist@qt.io> | 2025-08-26 12:55:14 +0300 |
|---|---|---|
| committer | Tarja Sundqvist <tarja.sundqvist@qt.io> | 2025-08-26 12:55:14 +0300 |
| commit | d000041a232a428ba08e31323840d484642f5886 (patch) | |
| tree | 9ecc0f8890b75d52651a8c0c0804776701514b21 | |
| parent | a78a36d69a792ae66fc062e461b83c28152a6856 (diff) | |
| parent | 70cb1950ded9a42875f4991c86ebd1d36754fde8 (diff) | |
Merge tag 'v6.2.13-lts' into tqtc/lts-6.2-opensourcev6.2.13-lts-lgpl6.2
Qt 6.2.13-lts release
Conflicts solved:
dependencies.yaml
Change-Id: I7fe2bca54cdac33db6d52ba57270bd1ea9820137
| -rw-r--r-- | .cmake.conf | 2 | ||||
| -rw-r--r-- | .qmake.conf | 2 | ||||
| -rw-r--r-- | dependencies.yaml | 6 | ||||
| -rw-r--r-- | src/designer/src/lib/shared/qdesigner_utils_p.h | 7 | ||||
| -rw-r--r-- | src/designer/src/lib/uilib/abstractformbuilder.cpp | 14 | ||||
| -rw-r--r-- | src/designer/src/lib/uilib/properties.cpp | 33 | ||||
| -rw-r--r-- | tests/auto/linguist/lupdate/tst_lupdate.cpp | 2 |
7 files changed, 41 insertions, 25 deletions
diff --git a/.cmake.conf b/.cmake.conf index 7733def21..0fcb9b1a0 100644 --- a/.cmake.conf +++ b/.cmake.conf @@ -1,2 +1,2 @@ -set(QT_REPO_MODULE_VERSION "6.2.12") +set(QT_REPO_MODULE_VERSION "6.2.13") set(QT_REPO_MODULE_PRERELEASE_VERSION_SEGMENT "") diff --git a/.qmake.conf b/.qmake.conf index b7ad2645b..f32b408f5 100644 --- a/.qmake.conf +++ b/.qmake.conf @@ -2,4 +2,4 @@ load(qt_build_config) DEFINES += QT_NO_JAVA_STYLE_ITERATORS -MODULE_VERSION = 6.2.12 +MODULE_VERSION = 6.2.13 diff --git a/dependencies.yaml b/dependencies.yaml index 239f11bbf..cb8c3b3e4 100644 --- a/dependencies.yaml +++ b/dependencies.yaml @@ -1,10 +1,10 @@ dependencies: ../tqtc-qtactiveqt: - ref: c9d993cb0578faada1d1ca872c5b05e71ccfd69f + ref: 5ef9e2421f75cb19f32cf5df3b52961654b8d62f required: false ../tqtc-qtbase: - ref: 3a82051eade32b34c2f4f6f652a9d8ef0db96c71 + ref: a963a536e623499cc56b0231c35dc5790a4bbc29 required: true ../tqtc-qtdeclarative: - ref: a7c766a9863605eb81e8f0cdb4d2b93e087b5bde + ref: c6fdadd916a7568c1d71b750e054ca9aa2fd5dfc required: false diff --git a/src/designer/src/lib/shared/qdesigner_utils_p.h b/src/designer/src/lib/shared/qdesigner_utils_p.h index 38cb31c9d..b7ec3e37b 100644 --- a/src/designer/src/lib/shared/qdesigner_utils_p.h +++ b/src/designer/src/lib/shared/qdesigner_utils_p.h @@ -136,9 +136,10 @@ QString MetaEnum<IntType>::valueToKey(IntType value, bool *ok) const template <class IntType> IntType MetaEnum<IntType>::keyToValue(QString key, bool *ok) const { - if (!m_scope.isEmpty() && key.startsWith(m_scope)) - key.remove(0, m_scope.size() + m_separator.size()); - const typename KeyToValueMap::const_iterator it = m_keyToValueMap.find(key); + const auto lastSep = key.lastIndexOf(m_separator); + if (lastSep != -1) + key.remove(0, lastSep + m_separator.size()); + const auto it = m_keyToValueMap.find(key); const bool found = it != m_keyToValueMap.constEnd(); if (ok) *ok = found; diff --git a/src/designer/src/lib/uilib/abstractformbuilder.cpp b/src/designer/src/lib/uilib/abstractformbuilder.cpp index 32b82b98e..f8a735529 100644 --- a/src/designer/src/lib/uilib/abstractformbuilder.cpp +++ b/src/designer/src/lib/uilib/abstractformbuilder.cpp @@ -787,19 +787,19 @@ static inline Qt::Alignment alignmentFromDom(const QString &in) if (!in.isEmpty()) { const auto flags = QStringView{in}.split(QLatin1Char('|')); for (const auto &f : flags) { - if (f == QStringLiteral("Qt::AlignLeft")) { + if (f.endsWith(QLatin1String("::AlignLeft"))) { rc |= Qt::AlignLeft; - } else if (f == QStringLiteral("Qt::AlignRight")) { + } else if (f.endsWith(QLatin1String("::AlignRight"))) { rc |= Qt::AlignRight; - } else if (f == QStringLiteral("Qt::AlignHCenter")) { + } else if (f.endsWith(QLatin1String("::AlignHCenter"))) { rc |= Qt::AlignHCenter; - } else if (f == QStringLiteral("Qt::AlignJustify")) { + } else if (f.endsWith(QLatin1String("::AlignJustify"))) { rc |= Qt::AlignJustify; - } else if (f == QStringLiteral("Qt::AlignTop")) { + } else if (f.endsWith(QLatin1String("::AlignTop"))) { rc |= Qt::AlignTop; - } else if (f == QStringLiteral("Qt::AlignBottom")) { + } else if (f.endsWith(QLatin1String("::AlignBottom"))) { rc |= Qt::AlignBottom; - } else if (f == QStringLiteral("Qt::AlignVCenter")) { + } else if (f.endsWith(QLatin1String("::AlignVCenter"))) { rc |= Qt::AlignVCenter; } } diff --git a/src/designer/src/lib/uilib/properties.cpp b/src/designer/src/lib/uilib/properties.cpp index a5ab40d59..99005a01b 100644 --- a/src/designer/src/lib/uilib/properties.cpp +++ b/src/designer/src/lib/uilib/properties.cpp @@ -60,14 +60,30 @@ namespace QFormInternal { #endif -static inline void fixEnum(QString &s) +static QStringView fixEnum(QStringView s) { - int qualifierIndex = s.lastIndexOf(QLatin1Char(':')); - if (qualifierIndex == -1) - qualifierIndex = s.lastIndexOf(QLatin1Char('.')); - if (qualifierIndex != -1) - s.remove(0, qualifierIndex + 1); + qsizetype valuePos = s.lastIndexOf(u':'); // "E::A" -> 3 + if (valuePos == -1) + valuePos = s.lastIndexOf(u'.'); + return valuePos != -1 ? s.sliced(valuePos + 1) : s; } + +// "QDialogButtonBox::StandardButton::Cancel|QDialogButtonBox::StandardButton::Ok" +// -> "Cancel|Ok" +// ### FIXME Remove/check when QTBUG-118240 is fixed. +static inline QString fixFlags(QStringView s) +{ + QString result; + result.reserve(s.size()); + const auto flags = s.split(u'|'); + for (const auto &flag : flags) { + if (!result.isEmpty()) + result.append(u'|'); + result.append(fixEnum(flag)); + } + return result; +} + // Convert complex DOM types with the help of QAbstractFormBuilder QVariant domPropertyToVariant(QAbstractFormBuilder *afb,const QMetaObject *meta,const DomProperty *p) { @@ -107,17 +123,16 @@ QVariant domPropertyToVariant(QAbstractFormBuilder *afb,const QMetaObject *meta, const QMetaEnum e = meta->property(index).enumerator(); Q_ASSERT(e.isFlag() == true); - return QVariant(e.keysToValue(p->elementSet().toUtf8())); + return QVariant(e.keysToValue(fixFlags(p->elementSet()).toUtf8())); } case DomProperty::Enum: { const QByteArray pname = p->attributeName().toUtf8(); const int index = meta->indexOfProperty(pname); - QString enumValue = p->elementEnum(); + const QStringView enumValue = fixEnum(p->elementEnum()); // Triggers in case of objects in Designer like Spacer/Line for which properties // are serialized using language introspection. On preview, however, these objects are // emulated by hacks in the formbuilder (size policy/orientation) - fixEnum(enumValue); if (index == -1) { // ### special-casing for Line (QFrame) -- fix for 4.2. Jambi hack for enumerations if (!qstrcmp(meta->className(), "QFrame") diff --git a/tests/auto/linguist/lupdate/tst_lupdate.cpp b/tests/auto/linguist/lupdate/tst_lupdate.cpp index 2e0012857..c34b64a30 100644 --- a/tests/auto/linguist/lupdate/tst_lupdate.cpp +++ b/tests/auto/linguist/lupdate/tst_lupdate.cpp @@ -328,7 +328,7 @@ void tst_lupdate::good() const QString command = m_cmdLupdate + ' ' + lupdateArguments.join(' '); proc.start(m_cmdLupdate, lupdateArguments, QIODevice::ReadWrite | QIODevice::Text); QVERIFY2(proc.waitForStarted(), qPrintable(command + QLatin1String(" :") + proc.errorString())); - QVERIFY2(proc.waitForFinished(30000), qPrintable(command)); + QVERIFY2(proc.waitForFinished(60000), qPrintable(command)); const QString output = QString::fromLocal8Bit(proc.readAll()); QVERIFY2(proc.exitStatus() == QProcess::NormalExit, qPrintable(QLatin1Char('"') + command + "\" crashed\n" + output)); |
