| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
| |
Change-Id: I3042ad7543eefa3153db0e9eee1ae9186f7011d1
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
8b534487044dfb3b464431ecb91ef4e0864af4ed made it so that the most
appropriate built-in style is chosen by default is no style is
specified. This breaks tests that assume the old behavior is still in
place.
Fix those tests to explicitly set the Basic style.
Task-number: QTBUG-86403
Change-Id: I6a51611741e2d0cb9109bb0221c2214a5c5179df
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
|
|
|
|
|
|
|
|
| |
Modify special case locations to use the new API as well.
Task-number: QTBUG-86815
Change-Id: I4a690095fcd4b1141550de86b6820ae2dd579429
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The previous commit changes the how the default style is set, and since
the tests all assumed that Basic was the default, we now need to
ensure it is explicitly set.
If we want to, we can revert this patch (or file-by-file) later and
ensure that these tests work with all styles. For now, just keep things
working as they used to.
Tests that use QTEST_QUICKCONTROLS_MAIN are not changed, as they
already run with all built-in styles.
Tests that don't use types that will cause issues,
like tst_qquickcolor, do not need to be changed.
tst_snippets can be run manually to produce screenshots, so we specify its
style in a qtquickcontrols2.conf file to allow it to be overridden by e.g.
application arguments (QQuickStyle::setStyle() takes precedence over all
other approaches of setting a style).
Change-Id: Ifae7e959f89a41a757c170272038fad139bba04f
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
[ChangeLog][Styles] An appropriate built-in style is now used as the
default style if one is available for the target platform. For example,
when running a Qt Quick Controls application on macOS, the macOS style
will be used. On Android, the Material style will be used. When running
on e.g. an embedded device, where no native style is available, use the
Basic (formerly "Default") style.
Change-Id: Ie61d1a8a1a83fbeba63387c7ca3671084f47bc04
Fixes: QTBUG-86403
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
|
|
|
|
|
|
| |
Use the actual type name instead of "type".
Change-Id: I081e226a2a6cda1dd5e5cf976629ceb63a9b8db1
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
|
|
|
|
|
|
|
| |
This passes for me locally on both macOS and Linux.
Task-number: QTBUG-87018
Change-Id: I2d5f27f3f18e8c419485beb1714515b86723bb08
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
|
|
|
|
|
|
|
|
| |
cd669f1f216e54fa59eee77459d608a41f5df290 fixed these tests,
but I forgot to unblacklist them in that patch.
Task-number: QTBUG-87018
Change-Id: I50b4f571eb9b231449e320ad90da3a9d4ae59a88
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
|
|
|
|
|
|
|
|
|
| |
Unlike the other functions, the x and y parameters do not currently
default to the center of the control if unspecified.
Change-Id: Ie6c5945c0b43f1ef0d79e76a96da18ea102a50e2
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
|
|
|
|
|
|
|
|
|
| |
So that we can unblock CI.
The failures need more time to be looked into.
Task-number: QTBUG-87018
Change-Id: I350a4100011127588077edecb73ae11078100940
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
|
|
|
|
|
|
|
|
| |
Amends 6115585477bea66d90acbbd8a25b898d121bd50e
Task-number: QTBUG-87018
Change-Id: I3c742bd8fc593f4d3a4f33104e708344fdafe3ec
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
|
|
|
|
|
|
| |
Task-number: QTBUG-86815
Change-Id: Ie0688d13b1787da3c1fc241a7d864aa014ca1d70
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
By allowing importing styles without first importing QtQuick.Controls,
which does runtime style selection.
[ChangeLog][Styles] It's now possible to select a style at compile-time
by importing that style explicitly instead of QtQuick.Controls. This
avoids the need to do run-time style selection and hence deploy the
QtQuick.Controls plugin with the application.
Change-Id: I666d6dc7727fffd2c7b05743855f2086f076465a
Fixes: QTBUG-86284
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
| |
[ChangeLog][Styles] The Default style was renamed to Basic to account
for the introduction of the platform styles (macOS, Windows), which
will be used by default (where possible) when no style is specified.
Fixes: QTBUG-85984
Task-number: QTBUG-68814
Task-number: QTBUG-86403
Change-Id: I22b3199c8662e4ee5d55a1be1a51c9856ac62376
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In Qt 5, QtQuickControls2Plugin::registerTypes() was responsible for
calling initializeTheme() on each style plugin. Now that we delegate
more work to the QML engine, each style plugin calls initializeTheme()
via registerTypes().
To avoid fallback styles overwriting font and palette data set by the
current style, we need to check if the theme has been intialized before
calling initializeTheme(). To do this, we add a static
"themeInitialized" bool that QQuickStylePlugin sets to true after
calling intializeTheme() for the first time. It checks this value and
avoids calling intializeTheme() if it's true.
We also need to make QQuickStylePlugin ensure that the theme it's
initializing belongs to the current style.
Fixes: QTBUG-86303
Change-Id: Ie65e646677c78622829f4949c41cb79204cf5786
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
|
|
|
|
|
|
|
|
|
| |
Also cleanup documentation, with the exception of the "High-DPI
Support in Qt Quick Controls" page, which needs to be either
removed or rewritten after some fact checking.
Change-Id: I3cdf1f8554f8f26627a9a5f17c2ee0038c933468
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
|
|
|
|
|
|
|
|
|
|
| |
AA_DisableHighDpiScaling and AA_UseHighDpiPixmaps have been deprecated.
As of 90358f6042d1fe2db849e17e1b0c875fb0560b20
and 2dc46c09026362cc267b1183faf09fb29479ef93 in qtbase, respectively,
these settings are deprecated and have no effect.
Change-Id: I1eb1f77a64893dd077bd08216d26633d43e1e0e3
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This amends 1a5a0a591c35dcf498a232a802087683f2244ecb so that it only sets
the hadActiveFocusBeforeExitTransition variable if it is false, ensuring
that it is correctly handled later on if it is true from before. This
handles a case of closing, opening and then closing again in one function
call.
Pick-to: 5.15
Task-number: QTBUG-85884
Change-Id: Ied4ca33045b005f5f666e63d85fb603e9350d982
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When the inputted value is out of range but it would be fixed to the
previous value then it would not update the text correctly to show the
corrected value. This ensures that it is updated as appropriate.
Before it would check if the value had actually changed after it had
been fixed to the corrected value. So if it was corrected to the
original value then it would not see it as having changed. Additionally
the displayText also has the original text before the change, so we
have to force through an update to ensure the contentItem's text is
updated too.
Change-Id: Ic38787d0803ab59cd998f4e2871c613f1642e764
Pick-to: 5.15
Fixes: QTBUG-85719
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
|
|
|
|
|
|
|
| |
This ensures that we received the warning we expect in
tst_StyleImports::importStyleWithoutControls when run with native styles.
Change-Id: I290f4e72222688e68ae36ace36f1d8be4bedaf31
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
|
|
|
|
|
|
|
| |
Not all styles will have a specific version, so don't specify it.
Change-Id: I92f020314d76934f286ca2946e994e2d1c5d37e5
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
|
|
|
|
|
|
|
|
|
|
| |
Set the default width of an empty TextField to 90px (which
is a number found by creating an NSTextField in XCode
and measuring it with pixeltool). This should also make
tst_QQuickPopup::macOS::cursorShape() pass.
Change-Id: Ia2a059668c2e1eaea3eef20015a8ea99468dd8ad
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
|\ |
|
| |\
| | |
| | |
| | | |
Change-Id: I18a4fd46cf13c65fe6f4c3981b7c61ab52109b8d
|
| | |\
| | | |
| | | |
| | | | |
Change-Id: I9999194551f71abec3731355cd746e69e2e0b187
|
| | |\ \
| | | | |
| | | | |
| | | | | |
Change-Id: I5375ecd1dcbc058806e34fce757df2bf30dac16e
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
This is how the macOS platform behaves. This will cause a slight
behavior change for all Qt Quick Controls 2 styles on macOS, as
reflected by the change in autotests.
Change-Id: I9ea744737d0d157ee8c83955f718c1cd889a8c1d
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
|/ / / /
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
I don't know why this is necessary, but without it, the mouse area
doesn't get any mouse events on subsequent runs (tested with
QT_LOGGING_RULES=qt.quick.mouse=true).
Change-Id: I69fa13ad282789f522542e52a945973fee66f44d
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
The problem is that QtQuick.Controls.macos is only
available with revision 6.0. And when importing e.g
QtQuick.Controls 2.15, we try to load a style with the
same revision. But it simply doesn't exist. So remove
all versioning from the tests to also support testing
newer styles.
Change-Id: I666a93ab03ec4c5dcf2055a363547f8cdac8d25e
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
The included test fails every now and then for Imagine, Fusion
and Mac style. By using QTRY_VERIFY to wait a bit before we check
if the menu is highlighted, it seems to pass each time.
Change-Id: Ib8b207e1b5f81b3086595bb8ad7dc6881272def1
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| | | |
| | | |
| | | |
| | | |
| | | | |
Change-Id: I1cb364046a35eac277ad08268b22851a6147d8c8
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Before this patch, the documentation stated the following for e.g.
accept():
"Closes the dialog and emits the accepted() signal."
In practice, styles that have enter and/or exit transitions for Dialog
result in closed() being emitted after accepted() (and rejected()).
As there is no way to guarantee this particular order, we should be
consistent and swap it around so that accepted()/rejected() are emitted
first.
[ChangeLog][Important Behavior Changes] Dialog's accepted() and
rejected() signals are now emitted before closed() when calling done(),
accept() and reject().
Fixes: QTBUG-85748
Change-Id: I706dda8de28c350d65e3188787af8f66a2c5f07d
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
The old sequence of events was:
1. setVisible(true) (enter transition begins)
2. startTimeout()
3. opened() (enter transition ends)
4. time out elapses (exit transition begins)
5. closed() (exit transition ends)
In most cases, a timeout would be longer than an enter transition,
so the only (barely) noticeable issue would be a slightly quicker
timeout than what was set. However, if the timeout was shorter than the
enter transition, then the sequence would be:
1. setVisible(true) (enter transition begins)
2. startTimeout()
3. time out elapses (exit transition begins)
4. closed() (exit transition ends)
This can result in the enter transition being interrupted and
the tooltip never being properly visible.
Avoid this by only starting the timeout when opened() has been
emitted. This also brings the behavior in line with what would
be expected when reading the documentation.
[ChangeLog][Important Behavior Changes] ToolTip's timeout now begins
only after opened() has been emitted. This bug fix results in tooltips
with enter transitions being visible for the entire duration of the
timeout property. This means that they are visible slightly longer than
they were before, so it may be worthwhile to visually check tooltips in
your application and adjust timeouts if necessary.
Fixes: QTBUG-82257
Change-Id: Iebad64a8cca1f328f9ce85aa78ea0f12918dadf1
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Otherwise &mnemonic shortcut in the active menu would be stolen by one
of the ambiguous items shadowed by the active menu.
Fixes: QTBUG-86276
Pick-to: 5.15
Change-Id: I5a1caea60da937fef409720f1ca11b99045ed4b8
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Otherwise tst_qquickmenubar of Material style would fail as follows:
1. Type Alt+E to open Edit menu
2. Type Alt+H to switch to Help menu
Since the key events of (2) are generated really quick, (2) wouldn't
open the Help menu. The Edit menu still exists in the popup stack and
blocks the MenuBar shortcuts.
I originally thought the closing popup shouldn't block the parent
shortcuts.
for (QQuickPopup *popup : popups) {
if (qobject_cast<QQuickToolTip *>(popup))
continue; // ignore tooltips (QTBUG-60492)
+ if (!popup->isOpened())
+ continue; // closing, or not yet fully open
However, the shortcuts in the closing popup are enabled until the popup
gets invisible. So changing the resolution of ambiguous shortcuts would
introduce another inconsistency. For example, unambiguous shortcut in
the closing popup could be triggered, whereas ambiguous one wouldn't win
because of the registration order.
Task-number: QTBUG-86276
Pick-to: 5.15
Change-Id: I3510cc7a06294e1d1d3512297fc9389bddc4da3b
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
This is close to what the widget QMenu (and Windows native menu) do.
Before, the active menu was left open and Alt+<key> shortcut would be
delivered to one of the matching items, which might be an item shadowed
by the active menu popup.
With this patch, the active menu is closed on Alt key pressed so the
subsequent shortcut event will (likely) be delivered to the matching
MenuBar item. Since I'm going to fix the issue of &mnemonic key conflict
resolution, I need to first change the way of delivering a shortcut
event to the parent MenuBar.
The test cases use the undocumented function to simulate low-level
behavior of Alt itself and Alt+<key> events. Apparently, there's no
public QTest function to send multiple key events without releasing Alt
modifier.
Task-number: QTBUG-86276
Pick-to: 5.15
Change-Id: I0ed6ea94f0fee7983a5cb6352d388036d3a1f8df
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
The following code
import QtQuick
import QtQuick.Controls.Material
ApplicationWindow {
width: 200
height: 200
visible: true
}
produced an error in Qt 5:
QQmlApplicationEngine failed to load component
qrc:/main.qml:4 ApplicationWindow is not a type
In Qt 6, the types are provided by the qmldir, so the import will work,
but as QtQuickControls2Plugin has not been loaded, there is no
QQuickTheme object yet, and so the style will not work as expected
(any colors, fonts, etc. from the theme will not be used by the
style).
Produce a warning for this scenario, and test each style to make sure
that we don't crash.
Fixes: QTBUG-86280
Change-Id: I99f940255f56da0522ad192ae5da4c9110ea308e
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
| |_|/
|/| |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
The paletteChanged signal was used as the change signal for a lot of
properties. The problem with this was this binding, for example:
Material.foreground: Material.toolTextColor
results in foreground being set, which emits paletteChanged.
toolTextColor has paletteChanged as its change signal, so that is
triggered and then the foreground binding is re-evaluated in the middle
of already being evaluated.
I haven't found a way to fix this for toolTextColor yet, so we
temporarily skip emission of toolTextColorChanged when foreground
changes. This means that some text will be the wrong color when
foreground is changed after startup.
For other properties, using more specific change handlers is enough
to solve any binding loops.
Task-number: QTBUG-85699
Pick-to: 5.15
Change-Id: Ied52d4c38914765ed5c75e234954f4baabaaa9af
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | | |
Task-number: QTBUG-82922
Change-Id: I75f4a553a6bb260f77bfa791f12fa42e80131e09
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
This patch completes the cumulative work done in previous patches.
- Uses qmlRegisterModuleImport() to register styles. This has some
added requirements:
- Each style must now be a QML module -- that is, it must have a
qmldir file.
- As a result of the above, the module must be available within the
QML import path in order to be found.
- The various forms of accepted style names have been reduced down to
one ("Material", "MyStyle", etc). See below for an explanation of
why.
- The following API in QQuickStyle is removed:
addStylePath(), availableStyles(), path(), stylePathList(). These
no longer make sense now that we reuse the existing QML import
system.
- Adds the tst_qquickstyleselector auto test back as "styleimports".
qmlRegisterModuleImport() vs resolvedUrl()
Previously we would use QQuickStyleSelector to select individual
QML files based on which style was set. We'd do this once when
QtQuick.Controls was first imported.
With Qt 6, and the requirement that each style be a proper QML
module, qmlRegisterModuleImport() was introduced. This allows us
to "link" one import with another. For an example of what this
looks like in practice, suppose the style was set to "MyStyle",
and the fallback to "Material". The "QtQuick.Controls" import
will be linked to "MyStyle", "MyStyle" to
"QtQuick.Controls.Material", and as a final fallback (for controls
like Action which only the Default style implements),
"QtQuick.Controls.Material" to "QtQuick.Controls.Default".
This is the same behavior as in Qt 5 (see qquickstyleselector.cpp):
// 1) requested style (e.g. "MyStyle", included in d->selectors)
// 2) fallback style (e.g. "Material", included in d->selectors)
// 3) default style (empty selector, not in d->selectors)
This is a necessary step to enable compilation of QML to C++.
Reducing the set of accepted style names
The problem
In QtQuickControls2Plugin() we need to call
QQuickStylePrivate::init(baseUrl()) in order to detect if the style
is a custom style in QQuickStyleSpec::resolve() (by checking if the
style path starts with the base URL). In Qt 5, init() is called in
QtQuickControls2Plugin::registerTypes(), but in Qt 6 that's too
late, because we need to call qmlRegisterModuleImport() in the
constructor. qmlRegisterModuleImport() itself requires the style to
have already been set in order to create the correct import URI
("QtQuick.Controls.X" for built-in styles, "MyCustomStyle" for
custom styles).
The solution
By reducing the valid forms for style names down to one:
./myapp -style MyStyle
we solve the problem of needing baseUrl() to determine if the
style is a custom style or not, but needing to call it too early
(since we now call qmlRegisterModuleImport() in
QtQuickControls2Plugin(), which itself requires the style to have
already been set). baseUrl() can't have been set before the
constructor is finished.
All of the various forms for _setting_ a style are still valid;
environment variables, qtquickcontrols2.conf, etc.
[ChangeLog][Important Behavior Changes] Custom styles must now have
a qmldir that lists the files that the style implements. For example,
for a style that only implements Button:
---
module MyStyle
Button 1.0 Button.qml
---
In addition, there is now only one valid, case-sensitive form for style
names: "Material", "MyStyle", etc.
These changes are done to help enable the compilation of QML code to
C++, as well as improve tooling capabilities.
[ChangeLog][Important Behavior Changes] The following API was removed:
- QQuickStyle::addStylePath()
- QQuickStyle::availableStyles()
- QQuickStyle::path()
- QQuickStyle::stylePathList()
- QT_QUICK_CONTROLS_STYLE_PATH
This API is no longer necessary and/or able to be provided now that
styles are treated as regular QML modules.
Task-number: QTBUG-82922
Change-Id: I3b281131903c7c3c1cf0616eb7486a872dccd730
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
As of Qt 6, the latest version will be used by default. This saves us a
lot of effort in terms of version bumps.
Task-number: QTBUG-82922
Change-Id: I74eba8185ec3ccc75bc293d4b2ea87d59e2d9928
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Qt Quick Controls 1 will be removed in Qt 6, so now we can have the
simplified path for ourselves.
Having the .2 in the path causes issues for importing now that the
version is being bumped to 6.
Task-number: QTBUG-82922
Change-Id: I0b92cdd44c42c19b1c82e7b9a7959b86ac26c6e2
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Adapt to the new way of registering C++ types. The types need to be
seen at compile time so that code can be generated that invokes them.
This patch:
- Adds QML_* macros where applicable.
- Adapts the build system files to the new way of registering modules.
- Splits up the QtQuick.Controls[.*].impl files into their own plugins,
as we can only register one QML module per .pro file.
- Removes C++ type registration calls in every plugin.
- Moves private types from src/quickcontrols2/quickcontrols2.pro
to src/quickcontrols2/impl/quickcontrols2-impl.pro. Some of these
types need to be exposed to QML, but quickcontrols2.pro is already in
use to declare the QtQuick.Controls import (and also provides the
public C++ QQuickStyle API), and the new QML_IMPORT_NAME/VERSION
syntax only allows one module per project. As some of the types that
need to be exposed to QML are also referenced by some C++ code (e.g.
tests, etc.), we just move all of the private types to the new
library.
Follow-up patches will register the QML types declaratively.
Task-number: QTBUG-82922
Change-Id: Iaf9ee106237d61701d57a8896f3822304c8151a6
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
In upcoming patches, we start registering C++ types declaratively.
A condition of doing so requires that each .pro corresponds to one
QML module. This conflicts with the QtQuick.Controls import, which
currently does quite a lot:
- Registers (and selects) QML files for the style that was set
- Registers private C++ utility types (such as IconLabel) that are
useful for all styles under the QtQuick.Controls.impl import
- Registers private C++ types that are only useful for the Default
style (such as BusyIndicatorImpl).
The reason it does so much can probably be explained by the
intended usage of Qt Quick Controls 2; when you do
import QtQuick.Controls 2.0
you get access to the QML types (e.g. Button) that the style
you're using provides. So if you're using the Material style,
you'll get a Material style button. API-wise, the button is
identical to any other button, because the types in
QtQuick.Templates are what we advertise as the public API.
If we didn't have this functionality, users would need to
import specific style imports to use controls, and the
convenience of being able to simply start the application
with a different style by e.g. passing an application argument
would be lost.
To support declarative registration of types while also supporting
the existing use cases, we split out the Default-style-specific
stuff into a QtQuick.Controls.Default import.
Task-number: QTBUG-82922
Change-Id: Ib4f1620cae78d7acdc13d9ac0752a020bc22f3ea
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
This is necessary to move away from imperative type registration of QML
files (i.e. qmlRegisterType()).
A later patch will use qmlRegisterModuleImport() to register the
QtQuick.Controls import with the style set by the user, which will
require each style to have a qmldir listing the files that it provides.
Note that some plugins still register QML files, but these registrations
will have to stay for now until we can split out "impl" plugins
in later patches where those files can be registered.
tst_qquickstyleselector will be added back in some other form in a
follow-up patch.
Task-number: QTBUG-82922
Change-Id: I8182533d9912ed493efda6eb91c69fc064af07ee
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Use the fix from 1d06eb3f8215b67c5061ee3a076df405724ff7ee.
Fixes: QTBUG-86212
Change-Id: I407c56741806340235da81cca943b50cc6e92dd2
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
This amends d5fbbddd7794265f24d392d33c4874ac756cb9c9 by also fixing
valueFromText().
Task-number: QTBUG-64151
Pick-to: 5.15
Change-Id: I02b053bb4d4579e86eaaa2279826f3b103800fdf
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
This conflicts with the behavior of SwipeDelegate. The released() or
clicked() signals should be used instead.
Fixes: QTBUG-85804
Pick-to: 5.15
Change-Id: I06111b63941f54c06f0e1b828d17264f37d765d5
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
If the mouse is released while our position is 0, it means we were
clicked, and we don't need to begin any transitions to close.
Fixes: QTBUG-85806
Pick-to: 5.15
Change-Id: Ic521f48e2977c1a99dbecaa585792a7798b9d749
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
When a popup is hidden, then it will trigger a prepareExitTransition
which can cause the active focus to be lost. If the popup's visibility
is tied to that fact then it can retrigger the transition which means
the active focus does not go back to where it should.
Therefore, we check if hadActiveFocusBeforeExitTransition is false before
going through that process as then it will only be called the first time
the popup is hidden.
Pick-to: 5.15
Fixes: QTBUG-85884
Change-Id: I68054aeb48447617b4235ce6467514a17f1073ba
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
|