summaryrefslogtreecommitdiffstats
path: root/tests/auto/gui/util
Commit message (Collapse)AuthorAgeFilesLines
* Another round of replacing 0 with nullptrAllan Sandfeld Jensen2020-10-072-10/+10
| | | | | | | | | This time based on grepping to also include documentation, tests and examples previously missed by the automatic tool. Change-Id: Ied1703f4bcc470fbc275f759ed5b7c588a5c4e9f Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* CMake: Regenerate projects to use new qt_internal_ APIAlexandru Croitor2020-09-2313-14/+14
| | | | | | | | | | | Modify special case locations to use the new API as well. Clean up some stale .prev files that are not needed anymore. Clean up some project files that are not used anymore. Task-number: QTBUG-86815 Change-Id: I9947da921f98686023c6bb053dfcc101851276b5 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
* Rename QLibraryInfo::location() to path()Lars Knoll2020-09-122-2/+2
| | | | | | | | As per ### Qt6 comment. Also rename the LibraryLocation enum to LibraryPath. Change-Id: I556025a19c5bcdf2ff52598eaba32269522d4128 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Remove most compiler warnings about missing overridesLars Knoll2020-09-112-22/+22
| | | | | | | | | | | | Remove around 1000 compiler warnings about missing overrides in our auto tests. This significantly reduce the compiler warning noise in our auto tests, so that one can actually better see the real problems inbetween. Change-Id: Id0c04dba43fcaf55d8cd2b5c6697358857c31bf9 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Don't capture this explicitly in testsTor Arne Vestbø2020-07-292-5/+5
| | | | | | | Some compilers implicitly captures, and will warn about the unused capture. Change-Id: Ib5e1cc3956c7eb0dc87cee834cce8a2b3dd0d30b Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* QTestlib: Enable comparing QList against initializer lists/arraysFriedemann Kleint2020-07-211-6/+7
| | | | | | | | | | | | | | | | | | | | | It is unnecessary to create a QList container just for comparison. Split out helpers for comparing sequence sizes and sequences from qCompare(QList) and add a template for an array with a non-type template parameter for the size. One can then write something like: const int expected[] = {10, 12,...}; QCOMPARE(QFontDatabase.pointSizes(...), expected) Unfortunately, any commas in such an array will be misread by macro expansion as macro argument separators, so any expected array with more than one entry needs an extra macro expanding __VA_ARGS__. Change-Id: Ie7c8dc20bf669bbb25f6d7f8562455f8d03968c8 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* Tests: Use QVERIFY instead of QCOMPARE for empty listsFriedemann Kleint2020-07-101-2/+2
| | | | | | Pick-to: 5.15 Change-Id: I4da02fa11583eca3844bf42efcdf818b8bbd6a94 Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
* CMake: Regenerate tests with new qt_ prefixed APIsAlexandru Croitor2020-07-0913-14/+14
| | | | | | | | Use pro2cmake with '--api-version 2' to force regenerate projects to use the new prefixed qt_foo APIs. Change-Id: I055c4837860319e93aaa6b09d646dda4fc2a4069 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Use QList instead of QVector in gui testsJarek Kobus2020-06-254-57/+55
| | | | | | Task-number: QTBUG-84469 Change-Id: Ia86f39597de418dde6cd9ae3170ef919bd27416a Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Remove winrtOliver Wolff2020-06-061-1/+1
| | | | | | | | | Macros and the await helper function from qfunctions_winrt(_p).h are needed in other Qt modules which use UWP APIs on desktop windows. Task-number: QTBUG-84434 Change-Id: Ice09c11436ad151c17bdccd2c7defadd08c13925 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* Remove deprecated QDesktopServices APIsVolker Hilsheimer2020-05-131-37/+0
| | | | | Change-Id: Ic21ad2938b20c1aa3ae499a921c9cff92f615816 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Move undo framework out of Qt WidgetsMitch Curtis2020-03-3012-1/+4660
| | | | | | | | | | | | | | | - Moves QUndo* classes (except QUndoView) from src/widgets/utils to src/gui/utils - Moves related auto tests from widgets to gui - Replaces QUndoAction with lambdas that do text prefixing [ChangeLog][Undo Framework] QUndo* classes (except QUndoView) were moved from Qt Widgets to Qt GUI. Done-with: volker.hilsheimer@qt.io Fixes: QTBUG-40040 Change-Id: I3bd8d4d32c64f8dee548f62159a1df2126da89d8 Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Remove QRegExpValidatorLars Knoll2020-03-176-112/+0
| | | | | | | As QRegExp will be moved to a compat library in Qt 6. Change-Id: I181aec45bd798f49d2c50a0e7fb64782e004b854 Reviewed-by: Samuel Gaist <samuel.gaist@idiap.ch>
* Merge remote-tracking branch 'origin/5.15' into devQt Forward Merge Bot2020-02-262-8/+242
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: examples/network/bearermonitor/CMakeLists.txt examples/network/CMakeLists.txt src/corelib/tools/qlinkedlist.h src/sql/kernel/qsqldriver_p.h src/sql/kernel/qsqlresult_p.h src/widgets/kernel/qwidget.cpp src/widgets/kernel/qwidget_p.h tests/auto/network/socket/platformsocketengine/tst_platformsocketengine.cpp tests/auto/network/socket/qtcpsocket/tst_qtcpsocket.cpp tests/auto/tools/moc/allmocs_baseline_in.json Change-Id: I21a3c34570ae79ea9d30107fae71759d7eac17d9
| * Merge remote-tracking branch 'origin/5.14' into 5.15Qt Forward Merge Bot2020-02-221-0/+123
| |\ | | | | | | | | | Change-Id: Iace12004afdfe765a3068dfcf6f1320c1123c539
| | * QShaderGenerator: Allow more expressions in input nodesNicolas Guichard2020-02-201-0/+50
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently QShaderGenerator will crash when encountering some expressions in input nodes. For example, this node prototype would make it crash: "VERTEX_COLOR": { "outputs": ["color", "alpha"], "rules": [ "headerSnippets": ["in vec4 vertexColor;"], "substitution": "vec3 $color = vertexColor.rgb; float $alpha = vertexColor.a;" ] } Change-Id: I37abb8099d376843a4cb13228140467dc1b8f60c Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
| | * QShaderGenerator: Don't crash when a node has multiple outputsNicolas Guichard2020-02-201-0/+73
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It was already possible to declare a node prototype with multiple outputs, but trying to assign to all those outputs was not possible and instead resulted in a crash. It is now possible to declare nodes like this without crashing: "SEPERATE_XYZ": { "inputs": ["vector"], "outputs": ["x", "y", "z"], "rules": [ { "substitution": "float $x = $vector.x; float $y = $vector.y; float $z = $vector.z;" } ] } Change-Id: I748e77e84c9120dc688c573eee33dc13c6bfbace Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
| * | Merge remote-tracking branch 'origin/5.14' into 5.15Friedemann Kleint2020-02-202-8/+74
| |\| | | | | | | | | | Change-Id: Ide8768d0d95aaeec943658aea27a03737d7dbf3f
| | * QShaderGraph: don't generate statements with undefined inputsNicolas Guichard2020-02-191-8/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This fixes the shader generation for graphs like this one: Function0 ------> Output0 (with unbound input) Input ------> Function1 ------> Output1 With those graphs, createStatements will not return any statement for nodes Function0 and Output0. Change-Id: Iec32aa51623e176b03ae23e580f06d14df80a194 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
| | * Fix QShaderGenerator crashing when a node port name prefixed another oneNicolas Guichard2020-02-191-0/+70
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QShaderGenerator didn't handle substitutions like `vec4 $color = mix($color1, $color2, $fac);` Note that `$color` is a prefix to `$color1` and `$color2`. For the substitution `QByteArray::replace` was used so if `$color` was handled first and replaced by `v1`, `$color1` and `$color2` were never correctly replaced and instead became `v11` and `v12` which caused a crash later on. Change-Id: Idaf800fdac468f33c323eb722701da5f8eb918d6 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
| * | Merge remote-tracking branch 'origin/5.14' into 5.15Liang Qi2020-02-181-0/+45
| |\| | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/tools/qlinkedlist.h src/plugins/platforms/wasm/qwasmintegration.cpp src/plugins/platforms/wasm/qwasmscreen.cpp Change-Id: Iefca7f9f4966bdc20e7052aca736874861055738
| | * QShaderGraph: Fix statement creation for graphs with dangling branchesNicolas Guichard2020-02-171-0/+45
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For graphs like this one: Input ----> Function1 ----> Output \ ---> Function2 (unbound output) We would have generated only 2 statements, for Function1 and Output. This change fixes this by treating Function2 like an output. Therefore it generates 4 statements: Input, Function1, Output and Function2. Change-Id: Iaada40b9b949d771806dd47efad4f7ef2a775b48 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* | | Use the new QMetaType API in QVariantOlivier Goffart2020-02-251-0/+4
| | | | | | | | | | | | | | | Change-Id: I5495ee1159864ebd64083fadbfac7e07177ed406 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | | Regenerate projects one last time before mergewip/cmakeAlexandru Croitor2020-02-126-12/+6
| | | | | | | | | | | | | | | | | | Change-Id: Ia24cf56b79ca6dacd370a7e397024e9b663e0167 Reviewed-by: Liang Qi <liang.qi@qt.io> Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | | Merge remote-tracking branch 'origin/dev' into merge-devLeander Beernaert2020-01-241-0/+1
|\| | | | | | | | | | | Change-Id: I31b761cfd5ea01373c60d02a5da8c33398d34739
| * | QDoubleValidator: Fix thousand separator handlingFabian Kosmale2019-12-051-0/+1
| |/ | | | | | | | | | | | | | | | | | | | | QDoubleValidator would accept "1,23" as valid in a locale which has ',' as a thousand separator. However, it should have been Intermediate instead, as there is still one digit missing. Fixes: QTBUG-75110 Change-Id: I6de90f0b6f1eae95dc8dfc8e5f9658e482e46db3 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* | Regenerate rest of tests/auto/guiAlexandru Croitor2019-11-132-1/+15
| | | | | | | | | | Change-Id: Iaaea50790161715517f7a4085116d5c893fa286b Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | Convert remaining gui utils testsLeander Beernaert2019-11-0412-15/+174
| | | | | | | | | | | | | | | | Fixes:QTBUG-78229 Change-Id: I3bff1b562e1c146f291e5692c90d2c38f162d395 Reviewed-by: Qt CMake Build Bot Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* | Merge branch 'wip/qt6' into wip/cmakeAlexandru Croitor2019-08-151-0/+4
|\| | | | | | | Change-Id: I50ac36b8803c296998149e98cc61e38687cdd14b
| * Remove usages of deprecated APIs of qtbase/guiSona Kurazyan2019-07-131-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Replaced the usages of deprecated APIs by corresponding alternatives in the library code and documentation. - Modified the tests to make them build when deprecated APIs disabled: * Made the the parts of the tests testing the deprecated APIs to be compiled conditionally, only when the corresponding methods are enabled. * If the test-case tests only the deprecated API, but not the corresponding replacement, added tests for the replacement. Change-Id: Ic38245015377fc0c8127eb5458c184ffd4b450f1 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* | Merge remote-tracking branch 'origin/dev' into wip/cmakeAlexandru Croitor2019-06-031-108/+443
|\| | | | | | | | | | | Take 5. Change-Id: Ifb2d20e95ba824e45e667fba6c2ba45389991cc3
| * Merge remote-tracking branch 'origin/5.12' into 5.13Liang Qi2019-05-031-31/+183
| |\ | | | | | | | | | | | | | | | | | | Conflicts: src/3rdparty/pcre2/qt_attribution.json Change-Id: Ibae941cb12662f27bd6962ee02bc235971c59a15
| | * Only generate temporaries when it makes sensePaul Lemire2019-05-021-31/+183
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Never for global inputs - Otherwise only if the temporary is referenced more than once -> meaning it's actually caching the result of some operation Tests updated accordingly. Change-Id: Ic76615370d23dee3965ca6350d5257a8be5a3e22 Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
| * | Merge remote-tracking branch 'origin/5.12' into 5.13Liang Qi2019-04-161-100/+283
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/tools/qlocale.qdoc tests/auto/corelib/io/qfileinfo/tst_qfileinfo.cpp Done-with: Edward Welbourne <edward.welbourne@qt.io> Done-with: Volker Hilsheimer <volker.hilsheimer@qt.io> Change-Id: I88e0757b2d020f0a244714c87844631df4b3fd13
| | * QShaderGenerator: don't generate temporary variables for global inputsPaul Lemire2019-04-101-40/+146
| | | | | | | | | | | | | | | | | | | | | | | | | | | Up until now, the QShaderGenerator would create temporary variables for uniform, attributes, const. This change makes it use the global inputs directly rather than relying on the intermediate properties. Change-Id: Ia9497367d61e536969fe87536606f309c286dbb2 Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
| | * QShaderGenerator: fix substitution for attributes on GL2/ES2Paul Lemire2019-04-101-70/+147
| | | | | | | | | | | | | | | | | | | | | | | | GL2/ES2 expect it to be attribute and not in like later versions of OpenGL. Task-number: QTBUG-74829 Change-Id: Iddd22386ed315d6e6843d8225e49a4b73b6ad9ba Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* | | Merge commit 'dev' into 'wip/cmake-merge'Tobias Hunger2019-04-164-24/+48
|\| | | | | | | | | | | Change-Id: I176c40d031be26a1dd1cf08843e448a660598783
| * | QTextureFileReader: add support for astc format filesEirik Aavitsland2019-02-274-24/+48
| |/ | | | | | | | | | | | | The standard astc encoder has its own file format. Change-Id: I9a2f7b1fa20ba344b79637bafb50ff2bd0596747 Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
* / Begin port of qtbase to CMakeSimon Hausmann2018-11-015-0/+17
|/ | | | | | | | | | | | | | | Done-by: Alexandru Croitor <alexandru.croitor@qt.io> Done-by: Frederik Gladhorn <frederik.gladhorn@qt.io> Done-by: Kevin Funk <kevin.funk@kdab.com> Done-by: Mikhail Svetkin <mikhail.svetkin@qt.io> Done-by: Simon Hausmann <simon.hausmann@qt.io> Done-by: Tobias Hunger <tobias.hunger@qt.io> Done-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io> Done-by: Volker Krause <volker.krause@kdab.com> Change-Id: Ida4f8bd190f9a4849a1af7b5b7981337a5df5310 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> Reviewed-by: Tobias Hunger <tobias.hunger@qt.io> Reviewed-by: Mikhail Svetkin <mikhail.svetkin@qt.io>
* Texture file support: add mipmap reading to ktx handlerv5.12.0-alpha1Eirik Aavitsland2018-09-123-11/+26
| | | | | Change-Id: Ic2c10b3e64d63d2272a8a3922d2b3f99dfd45bdb Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* Add API for reading and decoding graphical texture filesEirik Aavitsland2018-07-246-1/+109
| | | | | | | | | | | | | | Add a framework for reading and decoding stored graphical texture file formats. Includes decoders for the PKM and KTX formats. This is basically the same texture file reading that was added to qtdeclarative for 5.11, but has been refactored to be independent of the scenegraph and opengl. Task-number: QTBUG-67026 Change-Id: I87d8117550d8a2112f4f58c03e9ac6b3249cbc5a Reviewed-by: Kai Koehne <kai.koehne@qt.io> Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* QIntValidator: Intermediate for number if digits equal or less than maxTuomas Heimonen2018-06-291-4/+4
| | | | | | | | | | | | | | Input value which is over the highest acceptable value, but consisting of a number of digits equal to or less than the max value should be considered intermediate. [ChangeLog][QtGui][QIntValidator] Input value with over the highest acceptable value, but with equal or less amount of digits than the maximum value is now considered intermediate. Task-number: QTBUG-59650 Change-Id: I71a77c9c266f0f3b62c71ac6cb995019385c1cf5 Reviewed-by: Andy Shaw <andy.shaw@qt.io>
* QDoubleValidator: Allow intermediate values as close as possible to one ↵Andy Shaw2018-04-171-0/+8
| | | | | | | | | | | | | | | | | | considered invalid The documentation states that if you have a range of 0.00-2.00 with the number of decimals set to 2 then any number up to 9.99 would be considered intermediate. This is because the number of digits still matches both before and after the decimal point. If it is 10.0 or 9.999 then it is still considered invalid. In the case of 9.999 being invalid in this case, the documentation is corrected as this was incorrectly indicated as Intermediate, as the code indicates it as Invalid. Change-Id: I07b433e856f355916a1240deafdf4ef58e680639 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Enable BuiltIn input in the shader graph builderJuan Jose Casafranca2018-04-101-0/+4
| | | | | | | | BuiltIn inputs shouldnt be translated into a code input. We comment the input line for this variables Change-Id: I3b7d2fd06afc6a122d90a999fc5a5246fc93234e Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
* GLSL 1.00 ES must be selected using "#version 100"Kevin Ottens2017-08-041-3/+3
| | | | | | | | I was mistaken before, the "es" part for that version isn't optional, it *must* be omitted. Change-Id: I9e83d2317523fb0a905e40b95a56033cf693b93b Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Implement graph layers support in QShaderGeneratorKevin Ottens2017-08-021-2/+185
| | | | | Change-Id: I823f7866bc5e1f3b262f1aacf4c341dabda7305d Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* Add support for layers in QShaderGraphLoader formatKevin Ottens2017-08-021-8/+14
| | | | | Change-Id: I5038600e73523ac7eb37a88ddff1f942af18f18e Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* Implement graph layers support in QShaderGraphKevin Ottens2017-08-021-0/+117
| | | | | | | | | | | When creating the statements, it is now possible to pass a list of enabled layer names. Every node or edge which is not in the list of enabled layers will be pruned from the graph prior to traversal. Note that an empty layer list for a node or an edge means it is on all layers. Change-Id: I61a4df7d395b4beb42ee55ce08fef8ebe04263c9 Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* Add the layer concept to QShaderNode and QShaderGraph::EdgeKevin Ottens2017-08-022-2/+12
| | | | | | | This will be used in further commits Change-Id: I49977f1ea482b97dc0a159f69a0d2eda3865ec44 Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* Add support for QShaderLanguage enums in QShaderGeneratorKevin Ottens2017-08-021-0/+357
| | | | | Change-Id: I93306d783309cda09fedae3713afde851df3e9a3 Reviewed-by: Sean Harmer <sean.harmer@kdab.com>