summaryrefslogtreecommitdiffstats
path: root/src/tools/uic/ui4.cpp
Commit message (Collapse)AuthorAgeFilesLines
* uic: Generate QFont::WeightFriedemann Kleint2023-06-061-0/+18
| | | | | | | | | Check for the new "fontweight" attribute before "bold". Pick-to: 6.6 6.5 Task-number: QTBUG-113670 Change-Id: Ib34ab5a19872adb3c063861ffbe6b2d3374afcaa Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
* uic: Generate QFont::HintingPreferenceFriedemann Kleint2023-05-231-0/+18
| | | | | | | Task-number: QTBUG-113670 Pick-to: 6.5 Change-Id: I326d310b2a0df9a6f11e33588e553dff66e5a6f4 Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
* Use SPDX license identifiersLucie Gérard2022-05-161-27/+2
| | | | | | | | | | | | | Replace the current license disclaimer in files by a SPDX-License-Identifier. Files that have to be modified by hand are modified. License files are organized under LICENSES directory. Task-number: QTBUG-67283 Change-Id: Id880c92784c40f3bbde861c0d93f58151c18b9f1 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
* Adapt generated sources of uic to latest string changesFriedemann Kleint2022-04-221-612/+615
| | | | | | | | | | Use _s literals everywhere, removing all codepaths generating QLatin1Strings for comparisons and other optimizations. This is now possible since string literals are now longer duplicated. Task-number: QTBUG-98434 Change-Id: Ie35199593dc13a36afd92e3a0dd8d58ec492e4b7 Reviewed-by: Sona Kurazyan <sona.kurazyan@qt.io>
* Ignore weight in .ui files instead of converting itEskil Abrahamsen Blomfeldt2020-09-031-13/+0
| | | | | | | | | | | | | | | | | | | | | | | In 3558704ed5c3d2c6dc6d024dfa454997469ca75f, we added code to support old .ui files which used the old integer scale for font weights by checking for a special attribute which would help separate new and old files. Since then, it has become apparent that the weight element in .ui is not actually used for anything, since it is only emitted when the bold flag is set and always has to match QFont::Bold in these cases. So instead of converting, we simply ignore it now, and respect the bold flag instead. This also reverts the changes to ui4.* in uic, since the scale attribute is no longer needed. Task-number: QTBUG-42248 Change-Id: I1898868b58004099590f4eaf01f24c57bd34d779 Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
* Use OpenType font weightsJonas Karlsson2020-08-281-0/+13
| | | | | | | Task-number: QTBUG-42248 Change-Id: Icdb301b27d6699c2b842c4563fbef9df73c23cbc Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
* Use QList instead of QVector in uicJarek Kobus2020-06-221-39/+39
| | | | | | Task-number: QTBUG-84469 Change-Id: I2ce8ca51409c8e29a84d88bdda968e6dec419bea Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* uic: Migrate from QList to QVectorFriedemann Kleint2019-11-261-15/+15
| | | | | | | | Replace QList by QVector in the ui4.cpp/.h files and replace occurrences in remaining code. Change-Id: I15913710b339ef1ef5f7e3c72a7a1be69a87079b Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
* uic: Update ui4.cpp/h sourcesFriedemann Kleint2019-11-141-89/+89
| | | | | | | | Apply changes from qttools/4235774262f633da196a192248dbacf4f67f085e. Task-number: QTBUG-79896 Change-Id: I49466980a7c5983f57d4948386b15e8fcec82343 Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
* uic: Implement form window setting to disable QObject::connectSlotsByName()Friedemann Kleint2019-07-021-0/+7
| | | | | | Task-number: QTBUG-76375 Change-Id: I16ad147366aa7d52b7a0e17ae240127d8ac34b3c Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
* uic: Modernize the ui4.cpp/.h filesFriedemann Kleint2018-07-241-416/+339
| | | | | | | | | | | | | | | | | | | | | | Apply a change from Qt Designer. Silence clang-tidy warnings in the generated files - use nullptr [modernize-use-nullptr]: Use nullptr where applicable and simplify the switch() statement in write() on this occasion to use member variables instead of accessors. - use '= default' to define a trivial destructor [modernize-use-equals-default] Check if any delete statements are required. If not, use "= default". - use auto when initializing with new to avoid duplicating the type name [modernize-use-auto] Use auto. Change-Id: I7b48872fd42a6118e7cca8510aacb9ffa7e01839 Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
* uic: Support id-based translationsFriedemann Kleint2018-01-181-0/+21
| | | | | | | | | Use Ids from newly introduced id attribute depending on the global form setting. Change-Id: I0a5094d5543c0714c88511fa159b60afc9be3c81 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* uic: Ignore deprecated elements instead of raising an errorJarek Kobus2017-06-271-0/+31
| | | | | | | | | [ChangeLog][QtCore][uic] Ignore old images embedded in ui files, which were imported from Qt 3. uic will now behave consistently with Qt Designer - both will ignore them. Change-Id: Ib2dfd0bb28c0532463fdee2d46a8f0979c28c80c Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Remove ancient embedded pixmaps and scripts from uicJarek Kobus2017-06-121-1597/+49
| | | | | Change-Id: Iec06e1af91a6d61226ae484325b1ec82810d634d Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Keep in sync uic sources with qttools moduleJarek Kobus2017-05-041-2511/+1231
| | | | | | Change-Id: I680505b8d68f363e6dc86d090632ec9b021ee981 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* uic: Port Ui classes to QVectorFriedemann Kleint2017-04-131-27/+27
| | | | | | | | | | Regenerate the ui4* files after a change in qttools replacing QList by QVector in the Dom* classes with the exception of QList<DomProperty *> since that affects the public interfaces of QAbstractFormBuilder. Change-Id: I0922127fb911a5abc125d93ef97a0b22ff94788a Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
* uic: eradicate all Q_FOREACH loops [generated code]Marc Mutz2016-01-261-35/+70
| | | | | | | ... by replacing them with C++11 range-for loops. Change-Id: I0561174d9981ee2171c23644b5e7aebeb8c25665 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* Updated license headersJani Heikkinen2016-01-211-17/+12
| | | | | | | | | | | | | From Qt 5.7 -> tools & applications are lisenced under GPL v3 with some exceptions, see http://blog.qt.io/blog/2016/01/13/new-agreement-with-the-kde-free-qt-foundation/ Updated license headers to use new GPL-EXCEPT header instead of LGPL21 one (in those files which will be under GPL 3 with exceptions) Change-Id: I42a473ddc97101492a60b9287d90979d9eb35ae1 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* uic: updates from running generate_ui (III)Marc Mutz2015-10-191-101/+101
| | | | | | | | | (as of qttools:a7ff0d7d9ac2ff17e540521ef59029bf5cb35e14) Saves almost 10K of text size on optimized GCC 4.9 AMD64 Linux builds. Change-Id: Ib059e8b076362dbf81356861bebaec3810af6dcc Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
* uic: updates from running generate_ui (II)Marc Mutz2015-10-191-25/+25
| | | | | | | (as of qttools:1ed9418c0f38190cd839164229eeb7504438f740) Change-Id: I4a30878450218a56fa6af23b6784b314ab499338 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
* uic: updates from running generate_uiMarc Mutz2015-10-151-0/+86
| | | | | | | (as of qttools:9ed1cfb27d7354cbc1020563569b8f65a3311303) Change-Id: I2f539d2a20428cf167c04ea9f5881b1f5d58beb0 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
* Update copyright headersJani Heikkinen2015-02-111-7/+7
| | | | | | | | | | | | | | | | | | Qt copyrights are now in The Qt Company, so we could update the source code headers accordingly. In the same go we should also fix the links to point to qt.io. Outdated header.LGPL removed (use header.LGPL21 instead) Old header.LGPL3 renamed to header.LGPL3-COMM to match actual licensing combination. New header.LGPL-COMM taken in the use file which were using old header.LGPL3 (src/plugins/platforms/android/extract.cpp) Added new header.LGPL3 containing Commercial + LGPLv3 + GPLv2 license combination Change-Id: I6f49b819a8a20cc4f88b794a8f6726d975e8ffbe Reviewed-by: Matti Paaso <matti.paaso@theqtcompany.com>
* uic: don't use QStringLiteral in comparisonsMarc Mutz2015-02-021-273/+273
| | | | | | | | | | | | | | | | | (this is committing the new output of generate_ui from qttools) For QLatin1String, operator== is overloaded, even for QStringRef, so comparing to a latin-1 (C) string literal is efficient, since strlen() is comparatively fast. OTOH, QStringLiteral, when not using RVO, litters the code with QString dtor calls, which are not inline. Worse, absent lambdas, it even allocates memory. So, just compare using QLatin1String instead. Change-Id: I5035d259085c21689ab0f62fd49819ab5223ffe8 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* uic: update sources from current generate_uiMarc Mutz2015-02-021-62/+65
| | | | | Change-Id: I3b64fa94bd5904feeed753d34e80f4fc0611725e Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
* Removing a few unneeded "? true : false"Alessandro Portale2014-10-091-7/+7
| | | | | | | Change-Id: Ib13f0ddd65fe78f5559f343f2fc30756b1d3ef76 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com> Reviewed-by: Orgad Shaneh <orgads@gmail.com> Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* Update license headers and add new license filesMatti Paaso2014-09-241-19/+11
| | | | | | | | | - Renamed LICENSE.LGPL to LICENSE.LGPLv21 - Added LICENSE.LGPLv3 - Removed LICENSE.GPL Change-Id: Iec3406e3eb3f133be549092015cefe33d259a3f2 Reviewed-by: Iikka Eklund <iikka.eklund@digia.com>
* Update copyright year in Digia's license headersSergio Ahumada2013-01-181-1/+1
| | | | | Change-Id: Ic804938fc352291d011800d21e549c10acac66fb Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Change copyrights from Nokia to DigiaIikka Eklund2012-09-221-24/+24
| | | | | | | | Change copyrights and license headers from Nokia to Digia Change-Id: If1cc974286d29fd01ec6c19dd4719a67f4c3f00e Reviewed-by: Lars Knoll <lars.knoll@digia.com> Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
* Remove "All rights reserved" line from license headers.Jason McDonald2012-01-301-1/+1
| | | | | | | | | | As in the past, to avoid rewriting various autotests that contain line-number information, an extra blank line has been inserted at the end of the license text to ensure that this commit does not change the total number of lines in the license header. Change-Id: I311e001373776812699d6efc045b5f742890c689 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Update contact information in license headers.Jason McDonald2012-01-231-1/+1
| | | | | | | Replace Nokia contact email address with Qt Project website. Change-Id: I431bbbf76d7c27d8b502f87947675c116994c415 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* uic: Add translation-attributes to string list properties.Friedemann Kleint2012-01-201-7/+39
| | | | | | | | Task-number: QTBUG-8926 Task-number: QTBUG-20440 Change-Id: I57d92110bf532c717451336bd1943c9571020478 Reviewed-by: Jarek Kobus <jaroslaw.kobus@nokia.com>
* Update copyright year in license headers.Jason McDonald2012-01-051-1/+1
| | | | | Change-Id: I02f2c620296fcd91d4967d58767ea33fc4e1e7dc Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Submit ui4.cpp/h as generated by corresponding change in qttools.Friedemann Kleint2011-08-121-2863/+616
| | | | | | | | | | | | | | Change: 6b02fc50ec6a5236f628b08ebeca50e62b22f362 (Remove QDom code). Also introduces QStringLiteral. Remove QtXml from uitools profile. Done-with: Kai Koehne <kai.koehne@nokia.com> Change-Id: I56ee88a5dc76041eeb3685a982f2e9c60bcebd13 Reviewed-on: http://codereview.qt.nokia.com/2907 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* Update licenseheader text in source files for qtbase Qt moduleJyri Tahtela2011-05-241-17/+17
| | | | | | | Updated version of LGPL and FDL licenseheaders. Apply release phase licenseheaders for all source files. Reviewed-by: Trust Me
* Initial import from the monolithic Qt.Qt by Nokia2011-04-271-0/+11154
This is the beginning of revision history for this module. If you want to look at revision history older than this, please refer to the Qt Git wiki for how to use Git history grafting. At the time of writing, this wiki is located here: http://qt.gitorious.org/qt/pages/GitIntroductionWithQt If you have already performed the grafting and you don't see any history beyond this commit, try running "git log" with the "--follow" argument. Branched from the monolithic repo, Qt master branch, at commit 896db169ea224deb96c59ce8af800d019de63f12