| Commit message (Collapse) | Author | Age | Files | Lines |
| ... | |
| |
|
|
|
|
| |
Task-number: QTBUG-115165
Change-Id: Ie7e968ea45627d590f34d469e7ed567b4d13658d
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
This adds a QML-based implementation of Switch for the macOS style.
Switch doesn't exist in widgets, so there is no QStyle support for
this control.
__isDefaultDelegate was renamed to __focusFrameRadius and turned into
a qreal so that QML types can have control over the size of the focus
frame radius. No QML types were using __isDefaultDelegate.
Task-number: QTBUG-115165
Change-Id: I4f6c961ab809ba7c5c9bfccb3218d33316dd72c2
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
|
| |
|
|
|
|
| |
Task-number: QTBUG-115165
Change-Id: I5cdab9ba8560573a75b08d6b362dfe60b574a64a
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
There's no harm in customizing these, and especially the contentItem
and footer need to be customizable, as that's where the content and
any customized OK/Cancel/etc. buttons go.
This fixes warnings in the testbench manual test.
Currently only the macOS styles has implementations of these
controls.
Pick-to: 6.5 6.6
Change-Id: I09678c777088786961583724d68dc2c3f6d90895
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
If the content item of a ScrollArea is a height <-> width dependent
item, like a TextEdit, a change in the height of the content, may
trigger the vertical scrollbar to become visible, (if the content height
is bigger than the ScrollArea's height). This in turn causes the right
padding of the ScrollArea to change, to make place for the scrollbar,
causing in this way a content resize again, giving us a binding loop
on the Scrollbar's visible property and the ScrollView's
'implicitHeight'.
To get rid of the binding loop on the 'implicitHeight' property, check
if the TextEdit's updateSize() has already been called, and if so, don't
emit its contentSizeChanged() signal again.
In order to get rid of the binding loop on the Scrollbars' 'visible'
property, introduce two new properties: effectiveScrollBarWidth and
effectiveScrollBarHeight which represent the actual width/height of
the scrollbars. Set this property dependent on the scrollbar's policy,
visibility, and the scrollview's content size and make sure to update
whenever any of these changes. Also, follow the same pattern as above
and don't emit the signal twice if on a recursive call.
[ChangeLog][Controls][ScrollView] Added effectiveScrollBarWidth and
effectiveScrollBarHeight which hold the effective sizes of scrollbars.
Fixes: QTBUG-97974
Change-Id: I3d915eae53881d000769de1824c3908c7acd5c6b
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Reviewed-by: Doris Verria <doris.verria@qt.io>
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
|
| |
|
|
|
|
|
| |
Amends 0cd146b4b0.
Change-Id: I6aed2672e0ce1322bc045a8a931274a8bf2b97b8
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is a follow-up on 43eca45b06.
Which font a control should use should follow
normal font propagation. So setting a different
font explicitly in every control is not ideal.
The font is in practice the same for all controls
anyway.
This will also remove a warning that will be
printed if the application assigns a custom
background delegate to a Button.
Fixes: QTBUG-98098
Change-Id: I4f9304b391b4b9e398882fc532cbff5b09f53aff
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Amends e592a2ad31695695f0dd2069b17c6ab90ed1a739 to cover some cases
that were missed. They were missed because I incorrectly assumed that
the various test functions that I added in
0765c176e7b7ee73b1ac6d6efdabc93e4dec978f would catch warnings,
forgetting that the fact that we set
QT_QUICK_CONTROLS_IGNORE_CUSTOMIZATION_WARNINGS to 1 in tst_macos and
tst_windows meant that we'd never get the warnings.
Fixes: QTBUG-109438
Pick-to: 6.5
Change-Id: I527785a3adf3afb2a7ee4943300e87909f21562e
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
If the text in a SpinBox is larger than its text field, then
the text is drawn outside of the SpinBox covering the
spinbox buttons.
This patch will set a clip on the SpinBoxes, to ensure
that the text is not drawn outside the bounds of the
content item.
The SpinBox implementation differs a bit from one style
to the next, which means that some styles will only
need to set a clip, while others will need a bit more
change. Especially the Basic style will need to expand
the size of the content item to make room for the
focus rect (which the other styles don't have, or
implement differently).
There are also two versions of the SpinBox; One that
has the up and down indicators placed on each side
of the content item, and another that has them collected
on only one side. It seems like the latter implementations
has done a copy/paste of the padding from the former, and
thereby has set a too large padding. This has also
been fixed, as it's related to the clipping bug.
Fixes: QTBUG-98355
Pick-to: 6.5 6.4
Change-Id: I2c1ce6d477cf809e2187fd80aecbc9edeb8e0c2d
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Since Qt 6, the default style is no longer the Basic style, but instead
depends on the platform the application is run on. In addition, the
introduction of the native styles (which are not designed to be
customized) means that users customizing controls can run into visual
issues and not understand why.
This patch partially addresses this issue by warning when a native
control is customized (i.e. a delegate is overridden):
"qrc:/main.qml:11:22: QML QQuickItem: The current style does not
support customization of this control (property: "contentItem" item:
QQuickItem(0x1637375d210, parent=0x0, geometry=0,0 0x0)).
Please customize a non-native style (such as Basic, Fusion, Material,
etc). For more information, see:
https://doc.qt.io/qt-6/qtquickcontrols2-customize.html#customization-reference"
Ideally we'd also have qmllint integration in Creator so that users get
warnings from the IDE as they code, but that's not there yet.
The patch also updates the documentation by removing the code snippet
from the note and referring users to the existing
"Using Styles in Qt Quick Controls" section, which covers the topic in
greater detail. The snippet itself is also not considered a part of the
note, so the (online) styling looked a bit off.
[ChangeLog][Important Behavior Changes] Customization of native styles
will now result in warnings. Non-native styles (such as Basic) should
be used for customization purposes, or a custom style. If you are aware
of the risks and still want to customize these controls, you can ignore
the warnings by setting QT_QUICK_CONTROLS_IGNORE_CUSTOMIZATION_WARNINGS
to 1.
Fixes: QTBUG-108519
Task-number: QTBUG-96733
Change-Id: Ib6dff4639bad76b228e0f31285d20db4e3207224
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
|
|
|
Qt Quick Controls 2 was named that way because it was a follow-up to
Qt Quick Controls 1.x. Now that Qt Quick Controls 1 is no longer
supported, we don't need to have "2" in the name. Work on this was
already started for the documentation in
1abdfe5d5a052f2298b7bf657513dfa7e0c66a56.
By doing this renaming a few weeks before feature freeze, it won't
affect the release but still results in as little time possible spent
manually fixing conflicts in cherry-picks from non-LTS releases as a
result of the renaming.
This patch does the following:
- Renames directories.
- Adapts CMakeLists.txt and other files to account for the new paths.
A follow-up patch will handle documentation.
It does not touch library names or other user-facing stuff, as that
will have to be done in Qt 7.
Task-number: QTBUG-95413
Change-Id: I170d8db19033ee71e495ff0c5c1a517a41ed7634
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|