| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
| |
So that it shows up on http://doc.qt.io/qt-5/best-practices.html
Change-Id: I0968362dc055adb6b882c1b7dc6a4a4d7f8b6351
Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
|
|
|
|
|
|
|
|
|
|
| |
QQuickPointerTouchEvent::m_event is 0 when calling
QQuickPointerTouchEvent::isPressEvent(). Add a convenience function
with a check returning the Qt::TouchPointStates.
Task-number: QTBUG-44976
Change-Id: I2433ec3c56adeda2de190ca46aed8413a1357c55
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
|
|
|
|
|
|
|
| |
Change-Id: I472f61241d1875daf0de0a597bf27c019314f48f
Task-number: QTBUG-50119
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
If lists had spacing, snapping would have gaps where snapItemAt would
return nullptr eventhough there were items above and below in the list.
I.e. if we have a list with items of size 100, and a spacing of 100, and
scroll to 110 (right below the first item), then the first item would fail
because this is false:
itemTop+itemSize()/2 >= pos (50 >= 110)
And the next item (the one we should have snapped to), would fail because
this is false:
itemTop-prevItemSize/2 < pos (200-100/2 < 110)
The meaning of first part was probably to see if the middle of the current
item is inside the view.
The meaning of the second part was probably to see if the middle of the
previous item is outside the view.
This patch refactors the code so it's more visible what's happening and
fixes the bug by taking the spacing into account when computing the position of
the halfway positions.
Task-number: QTBUG-59852
Change-Id: I60eec0d16e91d2f22d70b97d11bcde5d88ac2997
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch partially reverts 098ba086530ccd555369a9ea88f3c6668726ab81.
Only QtWebGL will use separate buffers for indices and vertices. This
patch gives a performance boost.
Task-number: QTBUG-66191
Task-number: QTBUG-67147
Change-Id: I58b4db2bdf44cd954390e85e079de82031caf9e5
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
|
|
|
|
|
|
|
|
|
| |
Since commit 214fbaa57b73296a0 the latest minor version of the
import is automatically the Qt minor version, so let's also document
this.
Change-Id: Ie2fe1d172898bd0d51f0841c078abd1f8ab8d744
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
|
| |
Since commit 214fbaa57b73296a0 the latest minor version of the
import is automatically the Qt minor version, so let's also document
this.
Change-Id: I4131a399cca7c66b0e9df549f14be43eeaa94af3
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
|
| |
Since commit 214fbaa57b73296a0 the latest minor version of the
import is automatically the Qt minor version, so let's also document
this.
Change-Id: I9443be62da5cc9fc281e167f38fa299c73115eda
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
| |
Task-number: QTBUG-67786
Change-Id: Ie371d4c931ce31f728cdd960ad454e26c40cc4ed
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
| |
Mention licenses in the remaining landing pages.
Change-Id: I3754d959db9d9e4914e50d670f159eba1afa7596
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Consider the following example:
Item {
width: 100
height: 30
Text {
width: parent ? parent.width : 0
height: parent ? parent.height : 0
elide: Text.ElideRight
text: "wot"
}
}
When setting the Text item's parent to null, its explicit width and
height are set to 0. When restoring its parent (the Item), its
explicit width and height are set to 100 and 30 again, but the text
itself is still not rendered.
The cause can be seen here:
if (!(widthChanged || widthMaximum) && !d->isLineLaidOutConnected()) {
// only height has changed
if (newGeometry.height() > oldGeometry.height()) {
if (!d->heightExceeded) // Height is adequate and growing.
goto geomChangeDone;
heightExceeded was false, because 30 > 12 (or whatever the implicit
height happened to be), so the text was not laid out again, even though
it went from having an explicit height of 0 to an explicit height of
30.
Fix the issue by only executing the goto if the old explicit height
wasn't 0.
Task-number: QTBUG-60328
Task-number: QTBUG-67145
Change-Id: I7f4d2f95bc95c850133ba91ac2d1a02c7ee159b6
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
|
|
|
|
|
|
|
|
| |
Add user documentation of the compressed texture file support and the
file extension auto detection.
Change-Id: Icfae8574dd3acba30e8275ccd6ff3438fa037868
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fix three separate issues:
1. It was possible that the QSGSoftwarePixmapRenderer's
background image's rectangle was set to a non-normalized
rectangle. That would have led to the damage area detection
creating an empty QRegion for the damage area and
QQuickItem::grabToImage would grab an empty image.
2. The QSGSoftwarePixmapRenderer was rendering the image vertically
mirrored compared to what its equivalent in the OpenGL backend
was doing. Therefore QSGLayer::grab was vertically mirrored, too,
so QQuickItem::grabToImage would grab a mirrored image, too.
Additionally QSGSoftwareInternalImageNode (used by
QQuickShaderEffectSource) now has to mirror its internal texture
if that one is a QSGSoftwareLayer.
3. QSGSoftwareInternalImageNode (used by QQuickShaderEffectSource)
was not updating correctly when mirroring (with the fix for 2
also in case of a QSGSoftwareLayer as texture).
Related to QTBUG-63185 and QTBUG-65975.
Change-Id: I0d0ead7fb1c839a8ff427ff7881d8a881e538409
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
|
|
|
|
|
|
|
|
|
|
|
| |
This prevents bindings in children being evaluated and removes
spurious qml errors on the command line.
Amends 2eb2d6386da304cd1164264ae0bff685c796d89c.
Task-number: QTBUG-63729
Change-Id: I88b85ed40c6b8c5fbb422831055942cc0f4ee424
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
|
| |
It can return a null image. An "empty" image is confusing, as there's
no function in QImage with that name, requiring the user to consult the
docs.
Change-Id: Iaa805510804162fe3a7df00394b4a9ad61ac1d20
Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Since eeb320bbd8763f3e72f79369cc3908e999a0da3c the GL context only
deletes textures when all windows with pending updates have finished
rendering.
renderWindow will not process any window that is not visible. This
leaves a logic bug that we can have the updatePending flag set but
never cleared.
If we have two windows, this leaves the other window still updating
normally, but lastDirtyWindow will always be false and we never call
endSync.
This results in an effective memory leak of all textures.
This patch resets the flag on hide() a move that can be considered safe
given the show() method will reset this flag anyway.
Change-Id: Iab0171716e27e31077a66b5e36a00bf28a2e7a8c
Reviewed-by: Kai Uwe Broulik <kde@privat.broulik.de>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Dominik Holland <dominik.holland@pelagicore.com>
Reviewed-by: Aleix Pol
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
|
|
|
|
|
| |
Change-Id: I8930314179514d091a39640551f2816a23cbebc8
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
On macOS a special movementEnding timer was added to the wheelEvent
handling to fix QTBUG-63026.
This has introduced a regression with wrong vData/hData.moving flags:
When the timer fires before the Qt::ScrollEnd phase is reached,
movementEnding is invoked early (can be reproduced with very slow scrolling
using the Magic Mouse). In this case movementEnding sets
vData.moving = false but not vMoved = false because scrollingPhase is
still true.
This will prevent any further invocation of movementStarting from inside
the drag method (it expects a change in vMoved) so once this situation
has occurred the "moving" flags will be out of sync.
Visible effect: If a ListView has a currentItem set with
setCurrentIndex, its viewportMoved method will no longer correctly set
the moveReason to "Mouse" because the check depends on "moving" flag as
an indicator for mouse interaction. This results in the view permanently
jumping back to the current item on any scroll operation because the
moveReason will be stuck at "SetIndex".
The fix is to ignore the timer event if scrollingPhase is still true.
Task-number: QTBUG-67460
Change-Id: I7cf02b8c625b7baf249ad26c4e0c3df874a18eae
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
|
|
|
|
|
|
|
| |
Otherwise, all links to the Qt Quick Layouts module page will lead here.
Change-Id: I04c14ca9a28ebf0e19e489229352ba4d11f24859
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
|
|
|
|
|
| |
Task-number: QTBUG-58641
Change-Id: Ib339746d459328bdac8fa0eeff80300df99ff482
Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io>
|
|
|
|
|
|
|
|
| |
Also fixed a grammar issue and a few broken links.
Change-Id: I807da06536d6a9101e67fd73858cbbfe90d00663
Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
| |
This caused build issues in certain configurations. We don't actually
need it, as we can rely on the base Qt include path instead.
Also move the custom header under src/quick/doc and rename it.
Task-number: QTBUG-67342
Change-Id: Id75e140f9d286f6a47c2ecc039bfb52b13a92608
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Reviewed-by: Martin Smith <martin.smith@qt.io>
|
|
|
|
|
|
|
|
|
| |
They are public in QQmlParserStatus but don't need to be public here.
Also de-inline the default implementations, because this class will
be public C++ API eventually.
Change-Id: Ic7dfbec853e3d20f45b361401f710dedb5eae416
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
|
|
|
|
|
|
|
|
|
|
| |
Fix warnings like
designer/qquickdesignersupportitems.cpp:112:63: warning: 'QString::QString(const char*)' is deprecated: Use fromUtf8, QStringLiteral, or QLatin1String [-Wdeprecated-declarations]
Amends 01a40e1f920b58f00d52ff4542f6ef9c606a9b03.
Change-Id: I0e8167f8eacc0d901f79fb5dd8b2772ab29c55a8
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
|
|
|
|
|
|
|
|
|
|
| |
A fake module header is added for qtquick named QtQuick_pch.h,
and qtquick.qdocconf is modified to use this fake module header
instead of using QtQuick. The fake module header includes QtQuick
and QtQuickWidgets.
Change-Id: I2a3bd4ad32bdad878f8e7049cf71c393517547a0
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
|
|
|
|
|
|
|
|
| |
The conversion from nanoseconds to milliseconds wrongly divided the
swap time by 10 million instead of 1 million.
Change-Id: Id2b1594fbf7abafabfeae790c7083ad1cf4064a0
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
|
|
|
|
|
| |
Change-Id: Ia24767b33a20bd70096bbb8b4f27729c788eb331
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
|
|
|
|
|
|
|
|
|
|
|
| |
If a property is a deferred property then skip it if
searching for qobjects.
This is not enough to avoid all asserts, but not reading
deferred properties does make sense in any case.
Task-number: QTBUG-67152
Change-Id: I495051745a5daf458909ff6c4cb5210597774ded
Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
|
|
|
|
|
| |
Change-Id: Ib65bb9edbcbd1172cc620243b078c9691d961828
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
| |
This syntax allows creating distinct .qrc files without having to
create them manually.
Change-Id: Iab7c76fd162bb7f39b42fb983f85d74fce3036d4
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
|
|
|
| |
Qt Quick is most often used via its QML types, and since some of the
tips on this page are not specific to Qt Quick but apply to QML in
general, it makes sense to list them both on the same page for
convenience and completeness.
Change-Id: I6d61b98ffd7e52dc28b33ef00a78dd745f39820a
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
| |
This page doesn't offer much on its own, and qtquick-bestpractices.qdoc
is already starting to gather useful guidelines, so move its contents
there. Having everything related to best practices/guidelines on one
page means less clicking between these "overview" pages, which I think
is a bit of a problem currently.
Change-Id: I18316dc177a6a7eb5a031e178cd0aed31dfa63ae
Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
| |
Change-Id: I0d36e009b4551e45e5e7fda6c95fc3fbfabfe1a5
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
| |
We don't need to mention specific challenges in the introduction.
Change-Id: I03eec5fe543fbf0b1859850424eba8cfa9f134a5
Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
|
|
| |
Start off with the "direct" syntax, as that's the most
straight-forward. Then, explain why it can be inefficient and introduce
the concept of separate .qrc files.
Change-Id: I63c2c3e188db04ed58e816f7e69ab98a42196ff1
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
| |
Change-Id: I3ba63110a3674675f44feca51ba98128844e1904
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In 2eb2d6386da304cd1164264ae0bff685c796d89c, deactivating/clearing the
loader would now prevent any subsequent bindings from being evaluated.
The problem there was that the item created by the loader wouldn't have
a parent item (among things) anymore, so references to it in the
bindings would result in errors.
The way to prevent it was done by invalidating the context of the item,
which in turn would detach it from the root context. This is a problem
if objects in the root context are referenced after
deactivating/clearing the loader:
onSomethingChanged: {
loader.source = ""
objectInRootContext.doIt()
}
This would result in a ReferenceError when resolving objectInRootContext
and break the behavior present before the fix mentioned above. The
correct way is to recursively clear the context set on all bindings, but
leave everything in place. This way, no subsequent bindings will be
evaluated, but the currently "running" scripts will still be able to
reach the root context.
Task-number: QTBUG-66822
Change-Id: Ic9c2ab0a752093a26967da4783cb4c29cf83d2ca
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Reviewed-by: Michael Brasser <michael.brasser@live.com>
|
|
|
|
|
|
| |
Change-Id: Icc86afe67fd5a432798ce3173da51275bed1bf64
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io>
|
|
|
|
|
| |
Change-Id: I7e9e09ba3b6c0ec3c0b4bed75b24ed87fbe9660f
Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
A trackpad is primarily a mouse-emulating device, which can also
recognize gestures, and furthermore can send raw touches iff it
is asked to. So, every touch event from a trackpad is likely to be
followed by a mouse or gesture event (especially when the
MouseEmulation capability confirms that it is able to do that).
Therefore mouse event synthesis is redundant.
In this bug scenario, MultiPointTouchArea enables touch events within
its rectangular bounds. A Flickable is on top. As you flick with
two fingers on the trackpad, macOS sends touch events with two
touch points (because MPTA enabled touch events) and also a series
of QWheelEvents as it recognizes the flick gesture. The Flickable
receives mouse events sythesized from one touch point, and reacts
as if you were dragging with one finger on a touchscreen, while it
simultaneously also reacts to the QWheelEvents. Meanwhile the
remaining touchpoint falls through to the MPTA underneath; so the
user ends up interacting with both at the same time and making
the Flickable jump around besides. This patch just fixes the
jumpiness in Flickable: it will no longer receive the synth-mouse
events, so it will not be dragged, and will react only to the
wheel events. But MPTA still gets the touches.
Task-number: QTBUG-66329
Change-Id: I6f535a2c9e47bcb284eaf9ae1fdaa39f8b510af9
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Since SVG images can be scaled up without any loss of quality then we
should allow this to happen even though it is not done for other image
formats. This restores the 5.9.x behavior for SVG images.
Additionally the manual test is updated to showcase an embedded image
inside a SVG one to indicate this is continuing to work as before too.
Task-number: QTBUG-67019
Change-Id: Ia719899937f8146e8fab50aa85adf18e2f79aa98
Reviewed-by: Evangelos Foutras <evangelos@foutrelis.com>
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
|
|
|
|
|
|
| |
Task-number: QTBUG-15757
Change-Id: I9193ed459ced63cceb819a66f5a8c76042f455b6
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
|
|
|
|
| |
Change-Id: Ie3c24958e96c54cd91cd4a752638c11764338028
Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io>
|
|
|
|
|
|
| |
Task-number: QTBUG-67007
Change-Id: Id32cc14ea1bc258cfc139a859ccae014f5893563
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
|
|
|
|
|
| |
Change-Id: I81aa96641d9bef35e003b67e691607a926c087d7
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
| |
It was a bug that we made a local QQuickPointerDevice::Capabilities
instance and didn't pass it to the QQuickPointerDevice constructor.
Further, we've now reserved the entire lower byte for storing
QTouchDevice::capabilities, and the upper byte for storing QtQuick-
specific capabilities, so we can copy the whole lower byte instead
of just the lower nybble.
Change-Id: Ia21b6a1503ea870a1e16cebe70a20f4e21903054
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is for convenience. It's nicer not to need to test tapCount
in JavaScript if you know you want to react on double-click:
onTapped: if (tapCount === 2) doSomething() becomes
onDoubleTapped: doSomething() Neither of these are
guaranteed to be exclusive though: singleTapped occurs first,
then doubleTapped if you tap again quickly, then tapCount
keeps increasing as long as you keep tapping.
Change-Id: I6fff10880831d5be0848b9957141311db8c2c0f0
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The creation of module QtQmlTest remains incomplete, but this
update improves the situation a bit. In qtqmltest.qdocconf,
all instances of QtQuickTest are changed to QtQmlTest. In
qtquick.qdocconf, qtqmltest is added as a dependency. This
remains incomplete, because the module header is still called
QtQuickTest, but the number of qdoc warnings in qtdeclarative
is reduced.
Change-Id: Id545f9b5ecb2165d3f0972a059a8a4a4cfd52f2f
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
|
|
|
|
|
|
|
| |
Added the word OpenGL, which was missing.
Change-Id: Ie09ba1ec59615d2f139ef72e0743f67b6c8ff33d
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
|
|
|
|
|
|
|
| |
Removed the word Overview, which had been deleted from the title.
Change-Id: I1af6cc48b0f3c38e2fabe11346b023de317b1fd7
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
|