summaryrefslogtreecommitdiffstats
path: root/tests/auto/widgets/styles
Commit message (Collapse)AuthorAgeFilesLines
* QTBUG36933_brokenPseudoClassLookup() remove setActiveWindow()Frédéric Lefebvre9 days1-1/+0
| | | | | | | | | | | 2f6fe3a26843ff68c5d3f9af0a2fc3cce6caac22 has made calls to QApplicationPrivate::setActiveWindow() redundant. Remove redundant calls. Task-number: QTBUG-121488 Change-Id: I32991b158685d2aa6a9ced225f97ff9f0e6b13d3 Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
* task232085_spinBoxLineEditBg() remove setActiveWindow()Frédéric Lefebvre9 days1-1/+0
| | | | | | | | | | | 2f6fe3a26843ff68c5d3f9af0a2fc3cce6caac22 has made calls to QApplicationPrivate::setActiveWindow() redundant. Remove redundant calls. Task-number: QTBUG-121488 Change-Id: I8f941c2188563f72f1ff261a8d68bb0e62ae18fd Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
* tst_QStylesheetStyle::complexWidgetFocus() remove setActiveWindow()Frédéric Lefebvre9 days1-1/+0
| | | | | | | | | | | 2f6fe3a26843ff68c5d3f9af0a2fc3cce6caac22 has made calls to QApplicationPrivate::setActiveWindow() redundant. Remove redundant calls. Task-number: QTBUG-121488 Change-Id: I9fc6957376a0e42958e0f4c93025058f9f67bf20 Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
* tst_QStylesheetStyle::tooltip() remove setActiveWindow()Frédéric Lefebvre9 days1-1/+0
| | | | | | | | | | | 2f6fe3a26843ff68c5d3f9af0a2fc3cce6caac22 has made calls to QApplicationPrivate::setActiveWindow() redundant. Remove redundant calls. Task-number: QTBUG-121488 Change-Id: Icad230fe31f7bf06e2f2af462297227b5f47eb63 Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
* tst_QStylesheetStyle::hoverColors remove setActiveWindow()Frédéric Lefebvre9 days1-1/+0
| | | | | | | | | | | 2f6fe3a26843ff68c5d3f9af0a2fc3cce6caac22 has made calls to QApplicationPrivate::setActiveWindow() redundant. Remove redundant calls. Task-number: QTBUG-121488 Change-Id: I264c1703a0396356f6e17a3122b71bcb8f1813ad Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
* tst_QStylesheet::focusColors() remove setActiveWindow()Frédéric Lefebvre9 days1-1/+0
| | | | | | | | | | | 2f6fe3a26843ff68c5d3f9af0a2fc3cce6caac22 has made calls to QApplicationPrivate::setActiveWindow() redundant. Remove redundant calls. Task-number: QTBUG-121488 Change-Id: Idaca35d27b843c47f4c5f88a5a68c01b3cd8fb37 Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
* Change license for tests filesLucie Gérard2024-02-044-4/+4
| | | | | | | | | | | | According to QUIP-18 [1], all tests file should be LicenseRef-Qt-Commercial OR GPL-3.0-only [1]: https://contribute.qt-project.org/quips/18 Pick-to: 6.7 Task-number: QTBUG-121787 Change-Id: I9657df5d660820e56c96d511ea49d321c54682e8 Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
* Reset palette resolve mask in windows vista styleSanthosh Kumar2023-09-051-11/+54
| | | | | | | | | | | | | | The palette set by windows vista style during polish doesn't allow style- sheet style to override it. This patch reset resolve mask for the palette set by windows vista style and thus it can be overridden. Fixes: QTBUG-115511 Pick-to: 6.6 6.5 Change-Id: Ifcaf441f806cfa0273599b3dce83fdfaec3f5a66 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
* Rename accent color in QPaletteSanthosh Kumar2023-08-181-3/+3
| | | | | | | | | | Accent color role has been renamed according to name rule of other color roles in QPalette. Fixes: QTBUG-116107 Pick-to: 6.6 Change-Id: I70ac98a1e97afbdc7ea5f8d79f808c307e170712 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* CMake: Make widgets tests standalone projectsAlexandru Croitor2023-07-054-0/+24
| | | | | | | | | | | | | | | | | Add the boilerplate standalone test prelude to each test, so that they can be opened with an IDE without the qt-cmake-standalone-test script, but directly with qt-cmake or cmake. Boilerplate was added using the following scripts: https://git.qt.io/alcroito/cmake_refactor Manual adjustments were made where the code was inserted in the wrong location. Task-number: QTBUG-93020 Change-Id: I3c0d1a63c474969e5eaee5fdbb1bb0229482fc5b Reviewed-by: Amir Masoud Abdol <amir.abdol@qt.io> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* QStyleSheetStyle: Default to foreground for unset brushes onlyAxel Spoerl2023-06-091-0/+27
| | | | | | | | | | | | | | | | | | | | If a foreground style has been defined in the style sheet, QStyleSheetStyle populates its brushes for the color roles ButtonText, WindowText, Text, and the widget's foregroundRole with the foreground brush. PlaceholderText is set to the same brush with a modified color. That sets their resolve bits in QStyleSheeetStyle's palette and prevents these color roles from being inherited by the widget's palette - in contrast to all other brushes. This patch makes the brushes mentioned default to the widget's palette if they are set there. It adds a test in tst_QStyleSheetStyle. Fixes: QTBUG-93009 Pick-to: 6.6 6.5 Change-Id: Ie3df9dbd17b96fa72beee90792fc7eca1933cdbe Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Implement color role AccentColor in QStyleSheetStyle and QCssParserAxel Spoerl2023-05-221-0/+10
| | | | | | | | | | | | | | | | | The color role AccentColor has been added to QPalette. This patch implements the new color role in QCssParser and subsequently in QStyleSheetStyle. The QBrush variable names used to populate brushes, have been changed into speaking names for better code readability. tst_QCssParser has been adapted accordingly. The test function accentColor() has been added in tst_QStyleSheetStyle. Documentation has been updated. Change-Id: Ib09ddc1b61868f2bb8f70f654e83ea1c35276d30 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* tests: Remove remains of qmake conversion from CMakeLists.txt filesFriedemann Kleint2023-02-175-14/+0
| | | | | | | Pick-to: 6.5 Change-Id: I8d106554bb86ac1ec9bb7a4083de4c376bcbab1d Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Port from container::count() and length() to size() - V5Marc Mutz2022-11-031-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a semantic patch using ClangTidyTransformator as in qtbase/df9d882d41b741fef7c5beeddb0abe9d904443d8, but extended to handle typedefs and accesses through pointers, too: const std::string o = "object"; auto hasTypeIgnoringPointer = [](auto type) { return anyOf(hasType(type), hasType(pointsTo(type))); }; auto derivedFromAnyOfClasses = [&](ArrayRef<StringRef> classes) { auto exprOfDeclaredType = [&](auto decl) { return expr(hasTypeIgnoringPointer(hasUnqualifiedDesugaredType(recordType(hasDeclaration(decl))))).bind(o); }; return exprOfDeclaredType(cxxRecordDecl(isSameOrDerivedFrom(hasAnyName(classes)))); }; auto renameMethod = [&] (ArrayRef<StringRef> classes, StringRef from, StringRef to) { return makeRule(cxxMemberCallExpr(on(derivedFromAnyOfClasses(classes)), callee(cxxMethodDecl(hasName(from), parameterCountIs(0)))), changeTo(cat(access(o, cat(to)), "()")), cat("use '", to, "' instead of '", from, "'")); }; renameMethod(<classes>, "count", "size"); renameMethod(<classes>, "length", "size"); except that the on() matcher has been replaced by one that doesn't ignoreParens(). a.k.a qt-port-to-std-compatible-api V5 with config Scope: 'Container'. Added two NOLINTNEXTLINEs in tst_qbitarray and tst_qcontiguouscache, to avoid porting calls that explicitly test count(). Change-Id: Icfb8808c2ff4a30187e9935a51cad26987451c22 Reviewed-by: Ivan Solovev <ivan.solovev@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
* Port from qAsConst() to std::as_const()Marc Mutz2022-10-112-3/+3
| | | | | | | | | | | | | | | | We've been requiring C++17 since Qt 6.0, and our qAsConst use finally starts to bother us (QTBUG-99313), so time to port away from it now. Since qAsConst has exactly the same semantics as std::as_const (down to rvalue treatment, constexpr'ness and noexcept'ness), there's really nothing more to it than a global search-and-replace, with manual unstaging of the actual definition and documentation in dist/, src/corelib/doc/ and src/corelib/global/. Task-number: QTBUG-99313 Change-Id: I4c7114444a325ad4e62d0fcbfd347d2bbfb21541 Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
* Style sheets: add placeholder text color property for edit widgetsEirik Aavitsland2022-09-291-0/+4
| | | | | | | | | The placeholder text was given its own QPalette color role in Qt 5.12, but there has been no way to specify it from a Qt style sheet. Fixes: QTBUG-93009 Change-Id: If58ca844c19c65b7eee14c6d5730a4ba27640c33 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* StyleSheetStyle: Fix color of placeholder texts in text editsEirik Aavitsland2022-09-271-3/+11
| | | | | | | | | | | | | | | | | | | | | | | | Prior to 5.12, the placeholder text color was hardcoded to be the same as the text color, but with an alpha of 128, i.e. semi-transparent. In 5.12, it instead got its own ColorRole in QPalette. So behavior changed (In some cases in 5.12 and later, consistently from Qt 6): placeholder texts no longer got a "light" (semi-transparent) version of the css-styled color, but just the default gray/semi-transparent black. That problem was reported as QTBUG-89815. However, the fix for that bug did not apply the semi-transparency, but only used the same color as the text. That caused a confusing visual expression, as actual and placeholder text would look the same. This commit fixes that. The problem was made worse since there is no way to specify the placeholder text color from css, i.e. to style it independently. A follow up commit will aim to add that. Fixes: QTBUG-92199 Task-number: QTBUG-93009 Pick-to: 6.4 6.2 5.15 Change-Id: I9e6698d34eba91cbf65c4da07aa5ac6d9f96a9ed Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Deprecate QApplication::setActiveWindow() and mark as internalTor Arne Vestbø2022-08-271-6/+8
| | | | | | | | | | | | | | The function is used the internal window activation machinery and should not be called by user code. Many tests still use this function, and should be ported over to QWidget::activateWindow(). For now they are using the private helper in QApplicationPrivate, so that we can progress with the public API deprecation. Change-Id: I29f1575acf9efdcbae4c005ee9b2eb1bb0c8e5b5 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
* Change the license of all CMakeLists.txt and *.cmake files to BSDLucie Gérard2022-08-235-5/+5
| | | | | | | Task-number: QTBUG-105718 Change-Id: I5d3ef70a31235868b9be6cb479b7621bf2a8ba39 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
* Add license headers to cmake filesLucie Gérard2022-08-035-0/+15
| | | | | | | | | | | | CMakeLists.txt and .cmake files of significant size (more than 2 lines according to our check in tst_license.pl) now have the copyright and license header. Existing copyright statements remain intact Task-number: QTBUG-88621 Change-Id: I3b98cdc55ead806ec81ce09af9271f9b95af97fa Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
* CMake: Don't use PUBLIC_LIBRARIES for tests and test helpersAlexandru Croitor2022-07-284-4/+4
| | | | | Change-Id: I9b7404e1d3a78fe0726ec0f5ce1461f6c209e90d Reviewed-by: Alexey Edelev <alexey.edelev@qt.io>
* Use SPDX license identifiersLucie Gérard2022-05-164-108/+8
| | | | | | | | | | | | | 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>
* Remove remnants of the old Intel C++ compilerThiago Macieira2022-05-111-1/+1
| | | | | | | | | | | | | We don't support it any more. I don't think it has ever properly compiled Qt 6 (and it's no longer working for me against GCC 12's libstdc++ headers). If you report a bug against it, Intel support's first question is if you can try instead the new Clang/LLVM-based oneAPI C++ compiler. So we support only that one, which identifies itself as Q_CC_CLANG. Change-Id: I5ff8e16fcdcb4ffd9ab6fffd16eb57a092c8439e Reviewed-by: Marc Mutz <marc.mutz@qt.io>
* QStyle: Fix cases when logicalValue is outside rangeRobert Löhning2022-03-101-0/+3
| | | | | | Change-Id: I410c40425d6677612dbe3a40cbaa1debba998064 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
* QStyle: Fix overflows and crash when converting slider positionsRobert Löhning2022-03-091-0/+105
| | | | | | | | | Qt Creator crashes when max is INT_MAX and min is -1, see bugreport. Change-Id: I441e76c0ff87052083ed3d77e6085b186402e5d8 Fixes: QTBUG-101581 Pick-to: 6.2 6.3 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* CMake: Add BUILTIN_TESTDATA option to qt_internal_add_testAlexey Edelev2022-02-112-19/+11
| | | | | | | | | | | Multiple tests use qt_internal_add_resource that copies the functionality that is already implemented inside the qt_internal_add_test function. Simplify these test by replacing the qt_internal_add_resource call with the new BUILTIN_TESTDATA option. Change-Id: I18475b817d6f87264f0de53817d6c26c5ccab4e2 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Stylesheet: Fix tab layout when tab has a font and iconsVolker Hilsheimer2022-02-021-14/+43
| | | | | | | | | | | | | | | | | | | | | | | Amends e3b2b12a912361af309302a4b1fc27c2206322af, which made the style sheet calculate the font-dependent text size, but didn't add the space needed for the close button or a tab icon. QTabBar's layout code already adds the space needed for icons and margins to the size; so instead of overwriting that size, subtract the size needed by the normal font, and then add the size needed for the font form the style rule, considering both vertical and horizontal tab bars. Fix the test case to style only one tab rather than the entire tab bar, otherwise the font is applied to the entire tab bar, and not just to a specific tab, which is the style sheet style code in question. Pick-to: 6.2 6.3 Task-number: QTBUG-6905 Change-Id: Ieed0ba146a32e81229419adecaf41f467cfd5959 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* QCSS: Support Qt 5-style integer property selectorsVolker Hilsheimer2022-01-151-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In Qt 5 style sheets, objects could be selected by an enum-type property using the integer value of the enum value, e.g QToolButton[popupMode="1"] { ... } In Qt 6, the the new meta type system and QVariant implementation enabled QVariant::toString to return the string representation of the enum value instead for a property containing an enum. Since QStyleSheetStyle's attribute matching is string based, this breaks the Qt 5 style selector, and QCSS code instead needs to use e.g. QToolButton[popupMode=MenuButtonPopup] { ... } While the new syntax is arguably preferable, this is an unintentional change that silently breaks style sheet code (no error or warning at compile- or run-time). To support Qt 5-style selectors, we have to change the StyleSelector interface of the QCssParser API so that we can pass through what type of value the attribute extractor should return; if an integer string "1" is provided, then we need to compare the enum integer value; if the string provided does not represent a number, then we need to compare the name of the enum value. Since the pure virtual attribute() method that needs to be implemented to extract the attribute value of the node is implemented in modules outside qtbase, add a second virtual method that takes the entire QCss::AttributeSelector, which includes the value to match. Extractor implementations can use it to evaluate which type of data to return for an exact match. The default implementation calls the old attribute() method so that existing StyleSelector implementations continue to work. Make the respective change in the QStyleSheetStyleSelector, and simplify the surrounding code. Adjust other StyleSelector implemnentations in qtbase. As a drive-by, remove the superfluous virtual declaration from those overrides. Once submodules are adjusted to override this virtual function instead of the (now no longer pure) virtual attribute() method, that method can be removed. Pick-to: 6.3 6.2 Fixes: QTBUG-99642 Change-Id: I9a2b3498f77bf7cab5e90980b7dab2f621d3d859 Reviewed-by: Oliver Eftevaag <oliver.eftevaag@qt.io> Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Add test case for style sheet selectors for enum propertiesVolker Hilsheimer2022-01-151-0/+38
| | | | | | | | | | | | | | | | | | | In Qt 5, such selectors have to use the integer value of the enum value. Using the enum value name does not work. In Qt 6, such selectors must use the enum value by name, using the integer does not work. It's not clear yet what changed, possible a side effect of the changes and improvements in the meta object system and QVariant in Qt 6. So for now, document the difference in behavior in a test. Pick-to: 6.2 6.3 5.15 Task-number: QTBUG-99642 Change-Id: I96e0280b191b8ca06b16a97ab3ed367e9a8f43a0 Reviewed-by: Oliver Eftevaag <oliver.eftevaag@qt.io> Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
* macOS: make the slider knob big enough for BigSur and MontereyVolker Hilsheimer2021-11-151-2/+6
| | | | | | | | | | | The slider is very touch friendly from macOS 11 on, and the knob is quite large. Give it some extra pixels, and adjust the test accordingly. Pick-to: 6.2 Task-number: QTBUG-98093 Change-Id: Iedf6db1081cdd4013ca29ce760aea1e0361b1123 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* Implement missing support for 'em' and 'ex' lengths in style sheetVolker Hilsheimer2021-08-101-0/+28
| | | | | | | | | | | | | | | | | | | | | | | | The Qt style sheet reference claimed that Length properties can be specified in 'em' or 'ex' units, but that was never implemented. Add the missing implementation. Since the sizes depend on the size of the font of the current element, we cannot convert the units in the CSS parser, but have to do so in the QRenderRule constructor, where we can make a decision about which font to use if the style sheet itself doesn't specify a font. Fall back to the widget font if possible; otherwise it will be the application default font. The implementation translates em into QFontMetrics.height, identical to what is already done in the QCssParser. This is in line with the CSS specification, but contradicts our previous documentation which stated that 'em' means "width of M". Fix the documentation. Fixes: QTBUG-8096 Pick-to: 6.2 Change-Id: I145e2504ae3b19101a0d0dd63653466b6c2cec1d Done-with: Cristian Maureira-Fredes <Cristian.Maureira-Fredes@qt.io> Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* Support pt units for sizes, as documentedVolker Hilsheimer2021-07-201-0/+35
| | | | | | | | | | | | | | | | | | | | | | | | | Declaration::lengthValue only supported 'px' sizes, but one can transform any 'pt' value into 'px' by multiplying with 1.33. Notes: this ignores display DPI, and instead follows the W3C definition of 'pt' and 'px' as absolute lengths [1]. [1] https://www.w3.org/TR/css3-values/#absolute-lengths 1pt = 1/72th of 1 inch 1px = 1/96th of 1 inch so the conversion is px = pt * (72/96). Add unit test that verifies this using QPushButton's icon-sizes property, also with changed font in preparation of adding support for 'em' and 'ex' units in a follow up commit. Task-number: QTBUG-8096 Pick-to: 6.2 Done-with: Cristian Maureira-Fredes <Cristian.Maureira-Fredes@qt.io> Change-Id: I58782e7ad0e2ff9d89ed695f8a23b1e584cfed64 Reviewed-by: Andy Shaw <andy.shaw@qt.io>
* Repolish child widgets when parent style sheet changesVolker Hilsheimer2021-07-051-0/+14
| | | | | | | | | | | | | | | | | | | If a child widget that is affected by the parent's style sheet is polished (because it's been shown explicitly, for instance by a layout), then it must be repolished when the parent's style sheet changes, even if the parent itself has not been polished yet. Since the style sheet is set on the parent widget, we must repolish the parent (which will repolish the entire widget tree), not just the individual children and grand children. Fixes: QTBUG-76945 Task-number: QTBUG-39427 Task-number: QTBUG-18958 Change-Id: I7bca9ee1badc07202fa05dc97f440f4ca6c9517d Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Andy Shaw <andy.shaw@qt.io>
* Fix recursion crash when calling setStyleSheet with `qproperty-styleSheet`Zhang Yu2021-06-181-0/+18
| | | | | | | | | | | When calling `setStyleSheet` with property `qproperty-styleSheet`, `QStyleSheetStyle::polish` will call`QStyleSheetStyle::setProperties`, and then`QStyleSheetStyle::setProperties` goes on to call `setProperty`.Because there is property `qproperty-styleSheet`, it will update stylesheet by calling QStyleSheetStyle::polish`. This causes the recursive call to crash. Fixes: QTBUG-94448 Pick-to: 5.15 6.2 Change-Id: I79c51192a939b0b62e5b1d0dcc90d38f79e28222 Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
* QTabBar: take a style sheet's font into account when laying out tabsVolker Hilsheimer2021-05-061-0/+67
| | | | | | | | | | | | | | If a tab has a font assigned to it through a style sheet, then take the font size into account when calculating the contents rectangle. Add a test, which hardcodes the windows style to avoid flaky behavior when e.g. macOS lays tabs out in the center. Fixes: QTBUG-92988 Pick-to: 6.1 Change-Id: Ifb0ac97db7647cc25367972737be8878e50f6040 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* Set the PlaceholderText color in the palette from the stylesheet as wellAndy Shaw2021-01-121-0/+16
| | | | | | | | | | The color should be used across the board, so the PlaceholderText color should also be respecting the one passed for Text and so on. Fixes: QTBUG-89815 Pick-to: 6.0 5.15 Change-Id: I2accb3db35488f95a1c8ebacf2316a08ee416fac Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* tst_qstylesheetstyle: blacklist tests for QEMU ARMv7Samuli Piippo2021-01-071-0/+6
| | | | | | | | QEMU ARMv7 uses different font, which doesn't pass the tests. Task-number: QTQAINFRA-3836 Change-Id: I8454c35d99045adfd28d3bcbbaf791b0a668978f Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
* Remove the qmake project filesJoerg Bornemann2021-01-075-39/+0
| | | | | | | | | | | | | | | | Remove the qmake project files for most of Qt. Leave the qmake project files for examples, because we still test those in the CI to ensure qmake does not regress. Also leave the qmake project files for utils and other minor parts that lack CMake project files. Task-number: QTBUG-88742 Change-Id: I6cdf059e6204816f617f9624f3ea9822703f73cc Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* Replace QtTest headers with QTestDavid Skoland2020-12-224-4/+4
| | | | | | | | | | | Complete search and replace of QtTest and QtTest/QtTest with QTest, as QtTest includes the whole module. Replace all such instances with correct header includes. See Jira task for more discussion. Fixes: QTBUG-88831 Change-Id: I981cfae18a1cabcabcabee376016b086d9d01f44 Pick-to: 6.0 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* 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-234-5/+5
| | | | | | | | | | | 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>
* Deprecate and remove uses of AA_DisableHighDpiScalingTor Arne Vestbø2020-08-311-9/+2
| | | | | | Change-Id: Ibadce68775858c524b998aacad310905ba2c2e8e Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* Mark some Qt namespace enum members properly as deprecatedEdward Welbourne2020-08-271-1/+0
| | | | | | | | | | | | | | | | A comment is not good enough, Some of the enum members were even still in use, or mentioned in documentation. WA_ContentsPropagated, WA_WState_DND and WA_ForceAcceptDrops have been deprecated since 4.5.1; and at least the last has been an \omitvalue in the docs for even longer. (WA_ShowModal and WA_GroupLeader have been similarly marked, but are in use, see QTBUG-85816.) Push back to 5.15.1 in order to be able to remove these at Qt 6. Pick-to: 5.15.1 Change-Id: I6ea3839767e5f5158b0fed508f65798470191908 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* macOS: rename 'macintosh' style to 'macos'Richard Moe Gustavsen2020-08-261-2/+2
| | | | | | | | | | | | | | Change the name/key of the style to 'macos'. Besides the name 'macintosh' being archaic, we also need this change to avoid creating 'macintosh' style folders in QtQuickControls, now that we plan to use QPlatformTheme also there to resolve the style. [ChangeLog][Widgets][QStyle] The 'macintosh' style has been renamed to 'macos'. Change-Id: I14b8a8b4dbd369e7a7d16b94e4ad27e501e7e8d0 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* Rename confusingly named QFont/QPalette::resolve overloadsVolker Hilsheimer2020-08-251-4/+4
| | | | | | | | | | | | | | | Having three methods with the same name doing different things is unnecessarily confusing, so follow the standard naming convention in Qt and call the getter of the resolve mask resolveMask, and the setter setResolveMask. These methods were all documented as internal. The publicly documented resolve() method that merges two fonts and palettes based on the respective masks remains as it is, even though 'merge' would perhaps be a better name. Change-Id: If90b1ad800834baccd1dbc38fc6b861540d6df6e Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* Add missing enumeration case in tst_QMacStyle::setSizeTor Arne Vestbø2020-07-291-0/+2
| | | | | Change-Id: Iade36b03c6f8bdaa8feb82ef89744a399f92e21d Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Fix warnings about unused variables and functions in testsTor Arne Vestbø2020-07-261-11/+0
| | | | | Change-Id: Ia758a91384083c13fb4d743f500fef7a6629dfd5 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* CMake: Regenerate subdir test projectsAlexandru Croitor2020-07-091-5/+3
| | | | | | | | And generate a few more test projects that were missing. Change-Id: I5df51106549aa5ae09bc3c42360e14b143719547 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
* CMake: Regenerate tests with new qt_ prefixed APIsAlexandru Croitor2020-07-094-5/+5
| | | | | | | | 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 widgets testsJarek Kobus2020-06-252-4/+4
| | | | | | Task-number: QTBUG-84469 Change-Id: I490fdb237afad2d8a15954fe34d6b549a83fa4aa Reviewed-by: Lars Knoll <lars.knoll@qt.io>