| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
| |
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>
|
|
|
|
|
|
|
|
|
|
|
|
| |
When a TextArea is placed inside a Flickable (using the TextArea.flickable
property), the background is reparented to the Flickable. For this to
look good, the background should have the same size as the Flicable as
well, so it doesn't end up with the size of the TextArea, which can
be many pages tall.
Pick-to: 5.15
Change-Id: I75ead02c712f337c7e743f17aa8810a040519173
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Change f761ad3cd9ad1252f24b76ae413298dc7bed8af3 in qtbase exposes
a pre-existing difference in measuring the height of QTextLayouts
versus QTextDocuments when the leading is large enough to impact
the font height. See QTBUG-82954 for details on this.
Note that this is equivalent to the fix for the same issue
in the QLabel test: c4ef0b92d5fb2c621e880347bd48d01b6f31eb24
Task-number: QTBUG-82954
Change-Id: Idee81dcceefe594059a06bd1f090650acd738f79
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When the x/y position of background depends on the height/width of
background and these values are not constant, the if statement in
the method resizeBackground() will always pass. And since
`resizingBackground` guard wasn't checked, any geometry change
will always call resizeBackground() and then call
themself recursively (via the change listener),
that means the height/width of background will
always be reset, no matter what value you set.
Another part of the issue was in determining the extra bits too late:
in case the background gets parented by the flickable, the new child
caused the flickable to re-calculate its metrics and thus resize
the background *prior* to remembering if it has w/h set.
As a side effect, this fix also brings the possibility to reset
previously set w/h to get the default background sizing behavior.
Inspired by da06da57002b64cf4bcde0ca708b3275a5f919ae
[ChangeLog][QtQuick][QQuickTextArea] prevent changing size
of background recursively in construction
Fixes: QTBUG-76369
Change-Id: Ide51ec1ebab63605ae3bfcc10a76a28be960ef36
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This change makes all Qt Quick Controls 2 imports match the current
Qt minor version, which is 12 as of this patch.
It also updates all other Qt Quick imports to match.
This will also make future version bumps easier as all version numbers
in existing code/docs will match.
The following commands were used to verify that no old versions remain:
for i in `seq 0 11`; do git grep "import QtGraphicalEffects.*1.$i$"; done
for i in `seq 0 11`; do git grep "import QtQuick 2.$i$"; done
for i in `seq 0 11`; do git grep "import QtQuick.Layouts 1.$i$"; done
for i in `seq 0 5`; do git grep "import QtQuick.Controls.*2.$i$"; done
for i in `seq 0 11`; do git grep "import QtQuick.Templates 2.$i as T$"; done
[ChangeLog] From Qt 5.12 onwards, all import versions in
Qt Quick Controls 2 follow the same minor version as Qt's
minor version number. For example, the import version for Qt 5.12 is:
"import QtQuick.Controls 2.12".
Change-Id: I6d87573f20912e041d9c3b7c773cc7bf7b152ec3
Fixes: QTBUG-71095
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
|
|
|
|
|
|
|
|
|
|
|
| |
Same as 5adce042 for QQuickControl.
[ChangeLog][Controls][TextArea] Added topInset, bottomInset, leftInset,
and rightInset properties to control the geometry of the background
similarly to how paddings control the geometry of the contentItem.
Change-Id: I1e1b3a79a9f477ec7b64ec4c6cc8021bbf48adc0
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Same as 5bd9d44b for QQuickControl.
[ChangeLog][Controls][Label] Added implicitBackgroundWidth and
implicitBackgroundHeight properties that can be used to simplify
complex implicit size bindings.
[ChangeLog][Controls][TextArea] Added implicitBackgroundWidth and
implicitBackgroundHeight properties that can be used to simplify
complex implicit size bindings.
[ChangeLog][Controls][TextField] Added implicitBackgroundWidth and
implicitBackgroundHeight properties that can be used to simplify
complex implicit size bindings.
Change-Id: Idcc2d9af8df086b41c15f352506fd8afdbb2e3e7
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
|\
| |
| |
| | |
Change-Id: I509cd2e02874d9a2fe0febf8cc667833b7072b23
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
QQuickTextAreaPrivate::attachFlickable() reparents the background from
Flickable::contentItem to the Flickable itself. This avoids that the
background scrolls together with the content. However, when deferred
execution was enabled, attachFlickable() ended up being called before
the background had been executed. If the TextArea has already been
attached to a Flickable when the background gets exeuted, set the
appropriate parent in setBackground().
Task-number: QTBUG-67334
Change-Id: I0847fca5861fdddeac7d47d47316b74bb31500cb
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
|/
|
|
|
|
|
|
|
|
|
| |
Add placeholderTextColor property for user convenience to customize the
placeholderText color to fit the backgrounds.
[ChangeLog][TextArea] Added placeholderTextColor property for user
convenience to customize the placeholderText color to fit the backgrounds.
Change-Id: Iea0233f909ca9cfe19d88f9bc24691aa35b5ab35
Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
|
|
|
|
|
|
|
|
|
| |
TextArea was not cleaning up its geometry change listener on the
Flickable it was attached to.
Task-number: QTBUG-62292
Change-Id: I31223d4fcf0b46235b18e8eb05bab686a32f5481
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
|
|
|
|
|
|
|
|
|
| |
Sync with the qtbase/header.XXX. The license headers were matching
qtbase/header.XXX-OLD, which makes qtqa/tst_license flood warnings:
Old license being used for foo.qdoc
Change-Id: I199bf303a2d648e0d5f7bc01cb0814a5f945eeff
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
|
|
|
|
| |
Change-Id: I104bc44c361351719449cab94dcb14c96e91e32f
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
|\
| |
| |
| | |
Change-Id: If797ac58344b20e8de4379343131c097247ba2f2
|
| |
| |
| |
| |
| | |
Change-Id: If68cff4efacc7dc5719c8b8e61937e85e9076870
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The internal QQuickPlaceholderText creates an "implicit binding"
to the editor's horizontalAlignment, meaning that the placeholder
respects the editor's horizontal alignment when explicitly set,
and otherwise determines the alignment from the placeholder text's
visual direction.
[ChangeLog][Controls][TextField] Fixed the horizontal alignment
of the placeholder text in right-to-left UIs.
[ChangeLog][Controls][TextArea] Fixed the horizontal alignment
of the placeholder text in right-to-left UIs.
Task-number: QTBUG-55999
Change-Id: If1a8596c35c1920874996277520f1c54430c5f69
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
|/
|
|
|
|
|
|
| |
This ensures that the appropriate objects are destroyed at the end of
each test function, even if the test fails.
Change-Id: I58b1796152d72cf5f16ac4aa80eeeb133fde4c75
Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Also update expected line numbers in tst_swipedelegate.
Conflicts:
.qmake.conf
src/quicktemplates2/qquicktextarea.cpp
src/quicktemplates2/qquicktextarea_p.h
tests/auto/controls/data/tst_swipedelegate.qml
Change-Id: I36323e3a633c1c750d23014e56a7c881963a1a30
|
| |
| |
| |
| |
| |
| | |
Task-number: QTBUG-54897
Change-Id: I4e5cd0e175fa5dc2399bb80150ac538912a5b542
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
|\|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Conflicts:
src/quicktemplates2/qquickswipedelegate.cpp
tests/auto/controls/data/tst_swipedelegate.qml
tests/auto/controls/data/tst_textarea.qml
tests/auto/controls/data/tst_textfield.qml
Change-Id: I244f4ead4d14238c41db0bd965d7a2938f2ea8fc
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The delayed/intercepted mouse press event must be passed first,
before letting the base class handle the double-click event.
Change-Id: I029d06b0b619f34bb7be13ae12b8904f2efe6b5b
Task-number: QTBUG-54615
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
An empty TextArea has an implicit height of 0. Give it some textual
content so it gains a valid height, which is needed for testing mouse
event delivery.
Change-Id: I8e93b5fef08e4ac714233adad9493f70d4a0150b
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Users need these to e.g. open context menus when editors are
right-clicked.
[ChangeLog][TextArea][TextField] Added pressed() and released()
signals.
Change-Id: I32b79a8de0120a4f9115fa1c3cb832aff0134a15
Task-number: QTBUG-51009
Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
|
|/
|
|
|
|
| |
Task-number: QTBUG-50003
Change-Id: Ie101ba8840fba2a7503da8de77d9cf2a3c91d562
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
|
|
|
|
|
|
|
|
| |
In the same way that QQuickImplicitSizeItem does.
Task-number: QTBUG-49371
Change-Id: I1a8315c41e49139a9375f66a5714493331d22318
Reviewed-by: Liang Qi <liang.qi@qt.io>
Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
It is not always possible to let TextArea grow infinitely, but in
some cases it should be scrollable on its own. Even though it is not
a built-in feature of TextArea like in Qt Quick Controls 1, this change
makes it straight-forward to attach TextArea to a Flickable. This makes
TextArea behave like a standalone scrollable editor.
Change-Id: I8181e8ebe0edbcdfef2c30c9e102db7cbe4ff705
Task-number: QTBUG-51677
Task-number: QTBUG-52169
Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
|
|
|
|
|
|
|
|
|
| |
Docs, resources, .metainfo and plugins.qmltypes will be updated in
follow up commits.
Change-Id: I4438c5bfb8802bff0fa15c56431cfd288f179861
Task-number: QTBUG-52549
Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When inheritance of explicitly set font attributes is involved, it is
important to compare the resolve mask in addition to comparing the
attribute values to avoid losing the information whether a specific
attribute is set explicitly.
For example, QFont::operator==() returns true for two fonts that
are both bold regardless of whether only one of them has explicit
weight set. Therefore, setFont() must not ignore fonts resolve mask.
Furthermore, the fontChanged() notifier must be emitted only if the
actual attribute values change, not if only the resolve mask changes.
Change-Id: I2eb7a071c0eaecd2f8d2f6074c4ce6ed6764a6e9
Task-number: QTBUG-50984
Task-number: QTBUG-51696
Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We can't rely on timers in auto tests. They are not fired accurately
under heavy CPU load => random CI failures. This change make the press
and hold tests independent of timeouts.
The idea in a nutshell: the test creates two control instances, and
sends press events to both of them. Both controls run their timers and
emit pressAndHold() - unless canceled. The test waits as long as it
takes for the second control to emit pressAndHold(). At that point we
can reliably assume that the first control would have already emitted
the signal, if it was not canceled as appropriate.
Change-Id: I96aaf4d204db368171209271a4a0fa2ff15cc323
Task-number: QTBUG-47963
Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
|
|
|
|
|
|
|
|
|
|
| |
Better not expose the extra Text item in the API. Ideally it should
be implemented as a scenegraph node. We might even want to promote
the placeholderText property (and add placeholderColor) to TextInput
and TextEdit in Qt Quick core.
Change-Id: I4f443c77d1c696b87a50ee184f868713dd50316f
Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
|
|
|
|
|
|
|
|
| |
Placeholder text should follow the alignment of the control itself,
so that text input appears in the same place where a placeholder was.
Change-Id: I1dfa6c2aece10eb92e62a14f347c7e1ec5e610ea
Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
|
|
|
|
|
|
|
| |
Same as 0cb0962 for TextField.
Change-Id: I1538df1b31a8b7254a219923623c5dd586d65059
Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
|
|
|
|
|
| |
Change-Id: I142622dd85e95ef70b11132e77ccf48701f2cabc
Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This concerns TextField and TextArea.
It is an almost universal UX pattern on touch platforms where
the user long presses to pop the context menu up. In many
cases the context menu is used for copy and cut operations,
which means that poping it up should keep the selection.
The implementation works by not forwarding the initial mouse
press event to the parent class until we're sure it's not going
to be a long press. If the long press timer is cancelled for any
reason, we will then send the delayed mouse press event to the
parent class followed by whichever event triggered the cancellation.
Auto-tests refactored and updated.
Change-Id: If3aa8075f07a80929f4bd723895d9599bf8d169e
Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
|
|
|
|
|
|
|
|
|
|
|
| |
We just extend the wait interval. This is to make sure
the control's press-and-hold timer will timeout before
the wait. Since we're probably not using the most accurate
timers, adding 20% to something that's around one second
remains acceptable.
Change-Id: I1d10c88a168e882c9069f9345e896c1aab2f2bda
Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
|
|
|
|
|
|
|
|
| |
We factorize the feature code identical to TextField's
into a helper class.
Change-Id: I4496f2d192a023f6a6c03ed81d81bca4c08a59d0
Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
|
|
Not so much to test there, but test that at least creation succeeds.
Change-Id: I81aa3e43602b511d12ca9bb017e8df7452f9eaf3
Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
|