aboutsummaryrefslogtreecommitdiffstats
path: root/tests/manual/quickcontrols
Commit message (Collapse)AuthorAgeFilesLines
* testbench: add transparent icon to relevant controlsMitch Curtis8 days13-10/+48
| | | | | | | | This allows us to test icons with their original colors. Pick-to: 6.8 6.10 Change-Id: I794be82b286d71d3b037209624169bf18c57e62b Reviewed-by: Oliver Eftevaag <oliver.eftevaag@qt.io>
* testbench: add icons to more controlsMitch Curtis8 days6-0/+35
| | | | | | | | | Not all styles display icons for all controls, but it's good to have complete coverage in testbench anyway. Pick-to: 6.8 6.10 Change-Id: Ic347c408ababca4c8deb9acea83c26fa36c7ea75 Reviewed-by: Oliver Eftevaag <oliver.eftevaag@qt.io>
* testbench: fix build on macOSMitch Curtis14 days1-13/+16
| | | | | | | | | | | | | | The error was: ld: open() failed, errno=21 Use similar CMake commands as e.g. the textrendering manual test. Amends dd31db74a3e8d741fce5b64e5f9223d162534b1a. Pick-to: 6.8 6.10 Change-Id: I7dac1567fd2e4269516f7d6c7db5812be3646e6d Reviewed-by: Oliver Eftevaag <oliver.eftevaag@qt.io>
* testbench: add icon states for delegate controlsMitch Curtis2025-11-115-5/+40
| | | | | | Pick-to: 6.8 6.10 Change-Id: Ia9a58cfe033b4243bb75c1250b75c8080ad7042d Reviewed-by: Oliver Eftevaag <oliver.eftevaag@qt.io>
* testbench: replace check icon with heartMitch Curtis2025-11-114-1/+19
| | | | | | | | This allows us to test setting icon.color to "transparent". Pick-to: 6.8 6.10 Change-Id: I5b4523a8c4d45de3455302cf582dd33a23399ae3 Reviewed-by: Oliver Eftevaag <oliver.eftevaag@qt.io>
* testbench: move context property into Utils singletonMitch Curtis2025-11-115-2/+42
| | | | | | Pick-to: 6.8 6.10 Change-Id: Iabfea6ceddb85a58b24180e09c20980b383e5fb5 Reviewed-by: Oliver Eftevaag <oliver.eftevaag@qt.io>
* testbench: convert to declarative type registrationMitch Curtis2025-11-1118-227/+102
| | | | | | | | Also remove unused qmake files. Pick-to: 6.8 6.10 Change-Id: I3a29e1b40361d852b4a87c748e8838b99fbd8805 Reviewed-by: Oliver Eftevaag <oliver.eftevaag@qt.io>
* Tests: gifs - include missing headerTim Blechmann2025-09-241-0/+1
| | | | | | | | | QSignalSpy is used, but the header is not included. This patch fixes a compile error when building manual tests. Pick-to: 6.8 6.10 Change-Id: I8e6fc644aa73ff3d926a61687122fa210bcf5cd9 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* manual tests: compile fix for namespaced qtTim Blechmann2025-08-131-0/+2
| | | | | | | | QT_USE_NAMESPACE was missing, so they didn't compile with namespaced qt. Pick-to: 6.10 Change-Id: Ic4b1126cfab7780c714a737e81f0947664bade02 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* testbench: add SearchFieldMitch Curtis2025-07-012-0/+72
| | | | | | | Pick-to: 6.10 Change-Id: Ieafa5b40a3c43646ec89649afec80d0748ccfa2f Reviewed-by: Dilek Akcay <dilek.akcay@qt.io> Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Improve builds for non-threaded qtTim Blechmann2025-05-201-1/+1
| | | | | | | | | | A top-level configuration with FEATURE_thread=OFF fails when autotests are enabled. Most tools can be built without threads nowadays, so we enable them and only exclude the qquickworkerscript and gifs tests. Pick-to: 6.8 6.9 Change-Id: I809b021b4bdc4031d6c3335bea3aee414f5ce863 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* CMake: Don't enable ASM languageJoerg Bornemann2025-05-0212-12/+12
| | | | | | | | Remove the ASM language where no assembler files are used. Pick-to: 6.5 6.8 6.9 Change-Id: I3c94f798803b054a432fc2c8d6d65c665572a202 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Tests: include QTest, not QtTestGiuseppe D'Angelo2025-04-152-2/+2
| | | | | | | | | | | | | Never use module-wide inclusions. They blow up build times. For QtTest this is usually just a typo (QTest was meant instead). Add missing includes as needed. In the diffs I've spotted other huge inclusions (QtQuick, QtQml), but those need more attention. Task-number: QTQAINFRA-7110 Pick-to: 6.9 6.8 Change-Id: I74bf3fe212f50a7a3a6af2b1c80bbcaabc2516d7 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Material: Fix FloatingPlaceholderText X positionBartlomiej Moskal2025-02-282-0/+40
| | | | | | | | | | | | | | | | | | | In cb7eb152204e206539f307a9556eea43c589f026, we stopped using the leftPadding value for FloatingPlaceholderText. As a result, the text is now misaligned with the placeholder. This commit restores the FloatingPlaceholderText X position to leftPadding. If leftPadding is not set, it defaults to Material.textFieldHorizontalPadding. To prevent regressions (such as QTBUG-120149), a new X position animation has been added to FloatingPlaceholderText. Fixes: QTBUG-133492 Pick-to: 6.9 6.8 Change-Id: I5c80dcedd7c2beec0891b524fc55388fa5456f2a Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* ContextMenu: add to text editing controlsMitch Curtis2025-02-281-29/+0
| | | | | | | | | | | [ChangeLog][Controls] TextField and TextArea now provide a ContextMenu by default. If you already have a custom context menu for these types, ContextMenu will not open its own on e.g. right click. Fixes: QTBUG-35598 Pick-to: 6.9 Change-Id: I0897a7ba5e1b5b6d5425c80cbc6f2550c904605b Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Add ContextMenuMitch Curtis2024-12-241-6/+1
| | | | | | | | | | | | | | | This is an attached type that provides a way to open a context menu in a platform-appropriate manner. [ChangeLog][Controls] Added ContextMenu. ContextMenu can be attached to any item in order to show a context menu upon a platform-specific event, such as a right click or the context menu key. Fixes: QTBUG-67331 Pick-to: 6.9 Change-Id: I225a8f498cc5bc18d36c3dc4cf481ef5ef95cd88 Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* testbench: default Material and Universal to System themeMitch Curtis2024-09-182-0/+6
| | | | | | | | | This helps test out the runtime system theme switching. Pick-to: 6.8 Change-Id: I02a40f2625a1afce634c7676bd94a78a052dced0 Reviewed-by: Santhosh Kumar <santhosh.kumar.selvaraj@qt.io> Reviewed-by: Doris Verria <doris.verria@qt.io>
* Fix warnings in ListView delegate width bindings in manual testsMitch Curtis2024-08-126-6/+6
| | | | | | | | Bind width to the ListView's width, not the parent, which may be null. Pick-to: 6.5 6.7 6.8 Change-Id: I020d23bb0c98b3da00db9ffd3400a89cfdeb1810 Reviewed-by: Doris Verria <doris.verria@qt.io>
* Fix assertion failure in screenshots manual testMitch Curtis2024-08-121-1/+1
| | | | | | | | | SNIPPETS_DIR needs to be updated after the merge of qtquickcontrols2 into qtdeclarative. Pick-to: 6.5 6.7 6.8 Change-Id: Ic2ceabd34b35a64868e6b7e261dca19b46c7f195 Reviewed-by: Doris Verria <doris.verria@qt.io>
* FluentWinUI3 Style: Add documentationDoris Verria2024-08-091-0/+3
| | | | | | | Task-number: QTBUG-125748 Pick-to: 6.8 Change-Id: Iaeedd4044c686d1dce4ef611a4cf9a7ea8060f83 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* testbench: don't use native menus or menubarsRichard Moe Gustavsen2024-07-042-0/+6
| | | | | | | | | | | | The purpose of the tool is to show the styled controls. So don't use native menus or menubars. Also, since the menubar will warn (since Qt 6.8) if you add a MenuBarItem to a MenuBar without a Menu, give each MenuBarItem a dummy menu. Pick-to: 6.8 Change-Id: I51972deea0308e7c994460ab4c6cca4fa9b5a9ab Reviewed-by: Doris Verria <doris.verria@qt.io>
* QQuickMenu: respect Qt::AA_DontUseNativeMenuWindowsRichard Moe Gustavsen2024-07-033-0/+29
| | | | | | | | | | Now that we enable native menus by default for the macOS style, we also need to make sure that we actually respect the Qt::AA_DontUseNativeMenuWindows. Pick-to: 6.8 Change-Id: I2a02b5528110a4e0514fb53c0673653f0086dfe8 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Correct license for tests fileLucie Gérard2024-06-273-3/+3
| | | | | | | | | | | | 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.8 Task-number: QTBUG-121787 Change-Id: I50964da74d6360bb88fc468765f6362ad39d20d1 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* menus manual test: add SubSub menusRichard Moe Gustavsen2024-06-211-0/+10
| | | | | | | | | | Its nice to be able to test that you can still e.g hover the root menu, even when a subsub menu is the active popup. Pick-to: 6.8 Change-Id: Ibf76770a13c41f4712187daeb793439c83730db9 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Menus manual test: update popupType comboboxRichard Moe Gustavsen2024-06-191-6/+15
| | | | | | | | | | | Update the manual test to reflect that we no longer have a Popup.Default option. Also, after seeing some warnings, add a popupType() function, to improve type safety. Pick-to: 6.8 Change-Id: I70c4a52d776522541251bb0b2ab260b735d49171 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Fix a couple of issues in the testbench manual testMitch Curtis2024-06-142-1/+8
| | | | | | | | | - Ensure lastSearchText is serialized when clearing text. - Ensure that MenuItems are actually checkable. Pick-to: 6.5 6.7 6.8 Change-Id: I51eed8b89777f79b1d86427adbd7952812f6883a Reviewed-by: Santhosh Kumar <santhosh.kumar.selvaraj@qt.io>
* testbench: add checkable ToolButtonMitch Curtis2024-06-121-0/+2
| | | | | Change-Id: I7e2ff1eda5884d1322636f29f428cd6a33559495 Reviewed-by: Doris Verria <doris.verria@qt.io>
* Replace AA_DontUsePopupWindows with Popup::popupTypeOliver Eftevaag2024-05-301-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The application attribute approach has some weaknesses which makes it less suitable, than simply having a property which can be set per instance of Popup. In addition, given just how many of our own tests that are failing, when changing the default behavior of popup, it`s a much safer approach to introduce this feature as an opt-in, in the beginning. We can instead potentially modify the behavior of PopupType::Default in the future, when we feel that it's less risky to do so. To give more context to why the AA approach is bad: - The AA is too grandiose of a solution, which adds an arbitrary limitation of not allowing mixing of in-scene popups and popup windows. This also affects 3rd party libraries. - It causes inconveniences when styling the various popup types. Dialog, for instance, has a title property, which should be shown in the window title, and not inside the popup window. - It also makes it less flexible for potential future changes. We've learned that this change is riskier, than initially expected, since the qobject and visual hierarchy of popup objects are different when using popup windows, and tests that simulate events, will need to send the events to a different window. The introduction of the PopupType::Default value, allows us to, for instance, add a property later in ApplicationWindow, or somewhere else, to change the behavior of PopupType::Default. Meaning that we can still add a more grandiose API, that affects the behavior of multiple popup instances, if we think it's too cumbersome for developers to add `popupType: Popup.Window` to all popup instances. Task-number: QTBUG-121363 Change-Id: I544da820261607621a9b9ad5c4c9679e676e44a0 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* manual test, menus: use Popup.popupTypeRichard Moe Gustavsen2024-05-303-27/+32
| | | | | | | | Now that Popup has a popupType API, use it in favor of AA_DontUseNativeMenuWindows. Change-Id: I6b666e9c36f5d8b95701ac6a94c29ac3d7a6d206 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Menus test: inform when a restart is neededRichard Moe Gustavsen2024-05-291-1/+11
| | | | | | | | | | | Changing whether or not to use a native menu bar requires setting AA_DontUseNativeMenuBar. But this will only take effect the next time the app is started. So inform about this, since it can otherwise be quite confusing for the "tester". Change-Id: Ie37b9ec0cc66660548ea13cb383440536e6fd707 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* menus: fix quitting with Cmd+Q on macOSMitch Curtis2024-05-201-1/+5
| | | | | | | | It seems the Quit menu bar item steals the shortcut, so we have to do something with it. Change-Id: I3831c8bc99728773e22284232d7ab54ba6eb117f Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* Menus manual test: open context menu on mouse press or touch long-pressShawn Rutledge2024-05-161-4/+14
| | | | | | | This enables testing the drag-press-release gesture. Change-Id: I953fee1f891b2ac907a5a69ca98f720496e7ed91 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* manual test, menus: add support for more test casesRichard Moe Gustavsen2024-05-101-0/+34
| | | | | | | | | | | Add more logic to the manual test to test: 1. changing the delegate 2. changing the title of a menu in the menu bar 3. using sub menus 3. using checkable menu items in the menu bar menus Change-Id: I6a7256fb368a3557837c0448a6ddc895bb24924d Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Add support for icons to native menusMitch Curtis2024-05-064-0/+21
| | | | | | Task-number: QTBUG-69558 Change-Id: I9486f474dd386061636c326b508c20848ebab807 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* menus: add shortcutsMitch Curtis2024-04-231-3/+21
| | | | | | Task-number: QTBUG-69558 Change-Id: I440fb7caff125d2417fb648df667219e42b375bc Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* Menu, MenuBar: remove requestNative and rely solely on app attributesMitch Curtis2024-04-177-94/+136
| | | | | | | | | | | | | | | | | | | | | | | | It was decided that we'll have two attributes: - AA_DontUseNativeMenuBar - AA_DontUseNativeMenuWindows Setting AA_DontUseNativeMenuWindows only affects windows we create (context menus, combobox menus, menus of non-native menu bars). So, setting AA_DontUseNativeMenuWindows restores Qt to today's behavior. But we can't control the windows of native menu bars, so if you don't want those to be native, you have to set AA_DontUseNativeMenuBar just like today. By removing requestNative, we also effectively default to native menus and menu bars, as the attributes are not set by default. [ChangeLog][Controls][Important Behavior Changes] Menu and MenuBar now use native menus by default on platforms where they're supported. Task-number: QTBUG-69558 Change-Id: Ia917c2f820634def0cf815aa8ca8895ca79db75d Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* Merge remote-tracking branch 'origin/dev' into nativemenusRichard Moe Gustavsen2024-03-12173-206/+338
|\ | | | | | | Change-Id: Id09a36871013f65e5f9185fed0e3658a43bc934e
| * Material: fix floating placeholder text x positionMitch Curtis2024-03-072-0/+64
| | | | | | | | | | | | | | | | | | | | Don't set it to control.leftPadding, because we don't want it to change if the user changes leftPadding. Fixes: QTBUG-120149 Pick-to: 6.5 6.6 6.7 Change-Id: I67bbc22192fef386fe088398b67d3eb0a10421ba Reviewed-by: Oliver Eftevaag <oliver.eftevaag@qt.io>
| * Fix spelling of FFmpeg in (end-)user-visible stringsVolker Hilsheimer2024-03-011-2/+2
| | | | | | | | | | | | | | | | | | It's two capital "FF", lowercase "mpeg". Pick-to: 6.7 6.6 6.5 Change-Id: Icc379d0a680612b612ee306be7749697906bf4c3 Reviewed-by: Artem Dyomin <artem.dyomin@qt.io> Reviewed-by: Kai Köhne <kai.koehne@qt.io>
| * Correct license for test filesLucie Gérard2024-02-27173-173/+173
| | | | | | | | | | | | | | | | | | | | | | | | | | | | According to QUIP-18 [1], all test files 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: I26d72e8de04d4c7c57b3b7838af5d033265de5ba Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io> Reviewed-by: Kai Köhne <kai.koehne@qt.io> Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
| * Update manual tests and examples for change in default size policySanthosh Kumar2024-02-2113-31/+99
| | | | | | | | | | | | | | | | | | | | | | The size policy of item updated as part of task QTBUG-117597. This patch update existing examples and manual tests that depends on quick layout to embrace size policy change. Task-number: QTBUG-117597 Pick-to: 6.7 Change-Id: I68469a3bba3c4d3e5ed4b6eae0fd765b5206efc0 Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
* | Manual test, menus: add support for testing menubarRichard Moe Gustavsen2024-02-231-35/+123
| | | | | | | | | | Change-Id: Id8e55e3f3b05aab0ab02452452e08783181a7be8 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | QQuickMenuBar: respect AA_DontUseNativeMenuBarRichard Moe Gustavsen2024-02-221-0/+1
| | | | | | | | | | | | | | | | If the application sets AA_DontUseNativeMenuBar, it should override the requestNative property. Change-Id: Id69c09310d61e9a59746e32435a97742e28c80d3 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Menu: fix native checkable MenuItems (without an Action) not checkingMitch Curtis2024-02-121-1/+1
| | | | | | | | | | | | | | | | | | | | | | Not only do we need to ensure that the checked state changes so that syncing the MenuItem to the native menu item works, but we should also emit the same signals that would be emitted if the user had actually interacted with the MenuItem. Task-number: QTBUG-69558 Change-Id: I0ac1d16c0f84da1d9f6639b724ba47ea124da59a Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* | Menu: support adding MenuItem to native menuMitch Curtis2024-02-121-3/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | Originally the plan was to revert to a non-native menu when MenuItem was used, but now that we always create the non-native items regardless, we shouldn't need to do that. Checkable MenuItems do not currently work. This will be implemented in a follow-up commit. Task-number: QTBUG-69558 Change-Id: I7238dad89e478f7cc664738fb6036787e0193dab Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* | Menu: allow setting (but not always respecting) requestNativeMitch Curtis2024-02-121-0/+5
| | | | | | | | | | | | | | | | | | | | We can allow this to be set while the menu is a sub-menu and/or visible, and instead wait until it is re-opened to take the change into effect. Task-number: QTBUG-69558 Change-Id: Ie79819609950c2f6432e55c09d21dce7e8d9b220 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* | Menu: respect requestNative changesMitch Curtis2024-02-121-9/+15
| | | | | | | | | | | | | | | | | | | | This patch ensures that a native menu is created (or destroyed) when requestNative is set, if possible. Task-number: QTBUG-69558 Change-Id: Ic7f8826bf4def66e66932618767a81ad19e114f0 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io> Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Implement native menu separatorMitch Curtis2024-02-121-1/+4
| | | | | | | | | | | | Task-number: QTBUG-69558 Change-Id: I3da4509a722ec5ee4620111fc9482e6d688fdd9d Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* | Merge "Merge remote-tracking branch 'origin/dev' into nativemenus"Richard Moe Gustavsen2024-01-222-6/+10
|\ \
| * | Merge remote-tracking branch 'origin/dev' into nativemenusRichard Moe Gustavsen2024-01-222-6/+10
| |\| | | | | | | | | | Change-Id: I54bfced2ff9d5d897027dc81e6d5234d317b9b48