aboutsummaryrefslogtreecommitdiffstats
path: root/examples
Commit message (Collapse)AuthorAgeFilesLines
* Generate registrations for all examplesUlf Hermann2020-01-1394-443/+658
| | | | | | | | Now that we can generate all QML type information at build time, we should also use it. Change-Id: I647c72bbe38fdb2deb565b75c86a696af3d15b61 Reviewed-by: Simon Hausmann <[email protected]>
* Binding example: Fix type registrationFabian Kosmale2020-01-131-0/+2
| | | | | | Fixes: QTBUG-81335 Change-Id: Ie93c9b7ad49703bce245592e659ccdb6ea2b7ed9 Reviewed-by: Ulf Hermann <[email protected]>
* Make draganddrop example less confusingUlf Hermann2020-01-103-44/+109
| | | | | | | | | | | | Use required properties, rather than context, use direct binding rather than Binding elements, clarify that we're using the drag passed as parameter, not the drag property of DropArea, move Icon to a different file so that we get a distinct type for it. Give the icon a defined color while it is being dragged. Change-Id: I0e8b77abaedb9fc52660dfd4ddef1a4161f1323a Reviewed-by: Simon Hausmann <[email protected]> Reviewed-by: Shawn Rutledge <[email protected]>
* Minimal documentation for new examplePaul Olav Tvete2019-12-122-0/+48
| | | | | | Task-number: QTBUG-80500 Change-Id: Ifdd13bc404dd3ee34d14b339e24a72d647b6796f Reviewed-by: Laszlo Agocs <[email protected]>
* Add vulkantextureimport examplePaul Olav Tvete2019-12-129-1/+1126
| | | | | | | | | | This is essentially the rendering code from vulkanunderqml put into the structure of metaltextureimport with some added memory barriers. Task-number: QTBUG-80500 Change-Id: If38301c039b38e3798ff482625daa5f63e8d6fb2 Reviewed-by: Laszlo Agocs <[email protected]>
* examples/quick/shared/FlickrRssModel.qml: Do proper error handlingMaximilian Goldstein2019-11-291-0/+6
| | | | | Change-Id: Ieaed0706965bbb259934fb83151856f3d5805331 Reviewed-by: Ulf Hermann <[email protected]>
* examples/touchinteraction/multipointtouch: Fix broken score displayMaximilian Goldstein2019-11-292-8/+13
| | | | | | | Fixes the broken score display in "Bearwhack". Change-Id: I43581947f71e4c6dd3cca43068f6d220a058cc46 Reviewed-by: Ulf Hermann <[email protected]>
* examples/quick/views/pathview: utilize required propertiesMaximilian Goldstein2019-11-291-3/+7
| | | | | Change-Id: I07c5068de9330236b2e593d9995fdfda3e019006 Reviewed-by: Ulf Hermann <[email protected]>
* examples/quick/localstorage: Fix some linter warningsMaximilian Goldstein2019-11-282-7/+7
| | | | | | | | Also fixes MouseArea using anchors within a Layout and relying on properties that might be null. Change-Id: I9078ded60870019c8ac9f8ff5d52d9924b51c49c Reviewed-by: Ulf Hermann <[email protected]>
* examples/quick/animation/layouts: Avoid unqualified accessMaximilian Goldstein2019-11-281-3/+10
| | | | | Change-Id: I75f67b54d75840c215c2dfe592ff95c5cb962ff2 Reviewed-by: Ulf Hermann <[email protected]>
* examples/quick/animation/easing: Fix some linter warningsMaximilian Goldstein2019-11-281-4/+25
| | | | | | | | Now explicitly importing QtQml and QtQml.Models. The example also utilizes required properties now. Change-Id: I819b03c0a0dc892683e680fee47a632f1e5b543a Reviewed-by: Ulf Hermann <[email protected]>
* Fix Metal usage on iOSLaszlo Agocs2019-11-274-6/+11
| | | | | | | | Also enable the two Metal-specific scenegraph examples on iOS. Change-Id: I0e1e6d527544ea4a5bfb0d08ca2d32c762d3c699 Reviewed-by: Andy Nichols <[email protected]> Reviewed-by: Tor Arne Vestbø <[email protected]>
* Avoid initializing QFlags with 0 or nullptr in further casesFriedemann Kleint2019-11-251-1/+1
| | | | | | | Amends 744e77b841878fb017c0f2d60607090008f28180. Change-Id: I16e37aaf503eb62f67fca0e48be4c92c4a72ae46 Reviewed-by: Ulf Hermann <[email protected]>
* Merge remote-tracking branch 'origin/5.14' into 5.15Liang Qi2019-11-222-1/+5
|\ | | | | | | | | | | | | | | Conflicts: src/qml/qml/qqmlextensionplugin.cpp tests/auto/quick/qquicktableview/tst_qquicktableview.cpp Change-Id: Ic58d36a8532015bae30f2690063db9829b3bf372
| * fix rendernode example buildLorn Potter2019-11-121-0/+4
| | | | | | | | | | | | | | | | | | | | When not building developer mode, the install does not copy the files on other platforms Fixes: QTBUG-79781 Change-Id: Ibc8352c59d16b69618d53750511d5b5650ed5290 Reviewed-by: Qt CI Bot <[email protected]> Reviewed-by: Laszlo Agocs <[email protected]>
| * Doc: Fix documentation warningsTopi Reinio2019-11-111-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There were a lot of documentation warnings introduced by the separation of QtQml.Models and QtQml.WorkerScript modules from the QtQml documentation project into their own sub-projects. Fix the above, and also ensure that the experimental Qt.labs.qmlmodels QML types are listed in the documentation, and add them also on the QML module page for QtQml.Models. A few warnings remain, they may be indicative of issues not in the scope of this commit. Fixes: QTBUG-79812 Change-Id: Idc25c976e4c96feab4aae893519d6c9245f57a64 Reviewed-by: Paul Wicking <[email protected]>
* | examples: Drop bogus referenceUlf Hermann2019-11-181-1/+0
| | | | | | | | | | | | | | Canvas doesn't have an "alpha" property. Change-Id: I7cedff568ec062d7586b6b7333e32a8e52d2e8a9 Reviewed-by: Fabian Kosmale <[email protected]>
* | examples: Add type safety to animation/behaviors exampleUlf Hermann2019-11-155-42/+126
| | | | | | | | | | | | | | | | | | As SideRect wants to access focusItem's "text" property, we should expose the fact that it exists. Therefore, move focusRect into a separate file that declares the property and reference that. Change-Id: Id9b1d1e7868ee5abb9de124bab8fad45ee1449a9 Reviewed-by: Simon Hausmann <[email protected]>
* | Remove binding to nirvana in accessibility exampleUlf Hermann2019-11-151-1/+0
| | | | | | | | | | | | | | | | parent.description doesn't exist, and the text is always overwritten via the alias anyway. Change-Id: If80c4b9b1afaaa488b8ac5c6917b413a462476ef Reviewed-by: Simon Hausmann <[email protected]>
* | examples: Fix SimpleLauncherDelegate.qmlUlf Hermann2019-11-151-2/+2
| | | | | | | | | | | | | | | | | | Since the button is a simple Item, and the MouseArea is gone, the "pressed" property we're interested in is actually the TapHandler's "pressed". Change-Id: Idc7262325c9e2db761041b1ae1151e62702e3eb8 Reviewed-by: Shawn Rutledge <[email protected]>
* | Make QQuickFbo work with the OpenGL backend of QRhiLaszlo Agocs2019-11-145-14/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | So no matter if Quick goes directly to OpenGL, or via QRhi, QQuickFramebufferObject will still work. Also fix up the fboitem example to use a ShaderEffect that works with both rendering paths. With graphics APIs other than OpenGL the item will be empty, as QQuickFbo is not something we can support there. Task-number: QTBUG-79222 Change-Id: I52177d3a75f619f7075a2fc829573c17031eded1 Reviewed-by: Andy Nichols <[email protected]>
* | Fix xmlhttprequest exampleUlf Hermann2019-11-141-1/+1
| | | | | | | | | | | | | | | | The "pressed" property belongs to mouseArea, not button. Change-Id: Ib35c520b75e30c2cb9a3a7dee0b482a2209040c8 Reviewed-by: Fabian Kosmale <[email protected]> Reviewed-by: Simon Hausmann <[email protected]>
* | Add API to get more information for each line in a QML Text elementTimur Kristóf2019-11-041-0/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously there was no way to know what area is occupied by each line in a QML Text element. This commit adds new API to expose implicitWidth and isLast on QQuickTextLine for use in the lineLaidOut signal. It also adds improved documentation to the lineLaidOut signal and an example usage of the new API to the text layout example. An example use case of the new API is eg. to allow embedding timestamps and indicators within a text paragraph, to enable creating more efficient layouts. [ChangeLog][QtQuick][Text] Added new API that exposes implicitWidth, and isLast on the QQuickTextLine for use in the lineLaidOut signal. This allows the user to layout other items relative to the lines of text. Fixes: QTBUG-78277 Change-Id: Ibc754db17c78efb01468106aba32e30d70d2f4df Reviewed-by: Shawn Rutledge <[email protected]>
* | Merge remote-tracking branch 'origin/5.14' into 5.15Qt Forward Merge Bot2019-10-161-8/+8
|\| | | | | | | Change-Id: I6e69a235f50472b8f7ac19e133a3c071ea8c4d7a
| * Merge remote-tracking branch 'origin/5.13' into 5.14Qt Forward Merge Bot2019-10-151-8/+8
| |\ | | | | | | | | | Change-Id: I7759f6b60f8fda6525b239c7ee2e034194d4ab85
| | * Doc: Add "Using" to other sections for consistencyNico Vertriest2019-10-111-7/+7
| | | | | | | | | | | | | | | | | | | | | Task-number: QTBUG-79061 Change-Id: I5d359d9a8ba48131a3aec5487604e30d3b0370ed Reviewed-by: Paul Wicking <[email protected]> Reviewed-by: Mitch Curtis <[email protected]>
| | * Doc: Rename section ObjectModel in Qt Quick Views exampleNico Vertriest2019-10-101-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - a section should not have the name of a QML type - caused links to ObjectModel to refer to the wrong page Task-number: QTBUG-79061 Change-Id: I92bbd00e02252d3eca2ad50deca7d573f53f549a Reviewed-by: Paul Wicking <[email protected]> Reviewed-by: Mitch Curtis <[email protected]>
* | | Make twotextureproviders work on the rhi rendering pathLaszlo Agocs2019-10-1412-73/+274
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Involves porting away from the ill-fated QSGSimpleMaterial. This marks the first appearance of QSGMaterialRhiShader in any of the examples. Task-number: QTBUG-79086 Change-Id: I464e2bd06a6b5b19775b1b35265bb843979ec4b4 Reviewed-by: Paul Olav Tvete <[email protected]>
* | | Merge remote-tracking branch 'origin/5.14' into 5.15Qt Forward Merge Bot2019-10-115-1/+9
|\| | | | | | | | | | | Change-Id: I1359574c7d89aaf3328958e2f667ba1e599ff7f1
| * | Merge "Merge remote-tracking branch 'origin/5.13' into 5.14"Liang Qi2019-10-101-1/+1
| |\ \
| | * | Merge remote-tracking branch 'origin/5.13' into 5.14Liang Qi2019-10-101-1/+1
| | |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/plugins/scenegraph/openvg/qsgopenvgcontext.cpp tests/auto/quick/qquickpathview/tst_qquickpathview.cpp Change-Id: I117c8d62b21800329d1035021d312d9924f83a1b
| | | * Doc: Correct link error Package typeNico Vertriest2019-10-011-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Task-number: QTBUG-78803 Change-Id: Ideff1b3974dcb9ef833e5847e5a2df344105f241 Reviewed-by: Topi Reiniö <[email protected]> Reviewed-by: Paul Wicking <[email protected]>
| * | | Add guards in .pro of platform/api-specific scenegraph examplesLaszlo Agocs2019-10-104-0/+8
| |/ / | | | | | | | | | | | | | | | Task-number: QTBUG-78783 Change-Id: Icda60d4358c35de311552fd7562c3cf0c3425b7b Reviewed-by: Paul Olav Tvete <[email protected]>
* | | Merge remote-tracking branch 'origin/5.14' into 5.15Qt Forward Merge Bot2019-10-102-2/+5
|\| | | | | | | | | | | Change-Id: I2835748c27616103f275849141fbe5a93e3dfd8c
| * | Make rendernode example compile on iOSLaszlo Agocs2019-10-092-2/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Without Metal support for now. The ifdef pattern is the same as in QRhi in qtbase. It is to be revised once Metal support is introduced for iOS. Task-number: QTBUG-78854 Change-Id: I10f37ddcb42c27958270bd3ca8bf9b8457a4bea3 Reviewed-by: Paul Olav Tvete <[email protected]>
* | | Merge remote-tracking branch 'origin/5.14' into 5.15Qt Forward Merge Bot2019-10-0416-79/+115
|\| | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/imports/qtquick2/plugins.qmltypes src/quick/items/qquickitemsmodule.cpp Change-Id: I841c65c9c131354788b4f3fcfe3d7ed27be316d5
| * | Examples: Avoid Qt.createQmlObject()Ulf Hermann2019-10-021-27/+86
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We don't want to encourage Qt.createQmlObject(). It's the equivalent of eval() in JavaScript. This has the added benefit that the shapes actually react to changes in the parameters now. Before, once a shape was drawn, it didn't get updated when you manipulated the line width or fill controls. Change-Id: I8d5b7598799b52043f86fd1f617e31de09331891 Reviewed-by: Simon Hausmann <[email protected]> Reviewed-by: Fabian Kosmale <[email protected]>
| * | Clean up GraphicsStateInfo after API reviewLaszlo Agocs2019-09-184-16/+16
| | | | | | | | | | | | | | | Change-Id: I715ad71153151a0e6521bc182227d9fa2dc0a3ea Reviewed-by: Christian Strømme <[email protected]>
| * | Rename textureinsgnode example to a more fitting nameLaszlo Agocs2019-09-129-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It shows QQuickFramebufferObject. "Texture in QSGNode" is ambiguous as it suggests another type of use case (where an existing texture is imported and used with the QQ scene - without rendering to it). This would conflict with upcoming future examples, so rename to fboitem, which is what this example is about. The link from examples.qdoc is already using the fitting title so that will just work. Change-Id: Ide7a563398a4b464c55f14e10fa9386432b3d06d Reviewed-by: Andy Nichols <[email protected]>
| * | Merge remote-tracking branch 'origin/5.13' into 5.14Liang Qi2019-09-122-25/+2
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/qml/jsruntime/qv4engine.cpp src/quick/handlers/qquicktaphandler.cpp src/quick/items/qquicktableview.cpp Done-With: Richard Moe Gustavsen <[email protected]> Done-With: Ulf Hermann <[email protected]> Done-With: Shawn Rutledge <[email protected]> Change-Id: If9558a33f01693ce96420c094e0b57dfff0626cd
| | * Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-08-281-23/+0
| | |\ | | | | | | | | | | | | Change-Id: I0ae0a162e133cffd8fb1a2c6b70826e50f06facd
| | | * Remove HACKING fileEskil Abrahamsen Blomfeldt2019-08-231-23/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This file ends up in release packages and contains some outdated documentation about where to put different types of examples, which should probably not be documented by random files in the source repository. Change-Id: If35ee6cd2b4084fc5763a0cab39b9ff3e44fa133 Reviewed-by: Lars Knoll <[email protected]>
| | * | Doc: minor language issue in image elements documentationNico Vertriest2019-08-271-2/+2
| | |/ | | | | | | | | | | | | Change-Id: I5f3774ec4650dcc7eb316b4a15740e4a67504365 Reviewed-by: Paul Wicking <[email protected]>
| * | Fix gcc warnings in vulkanunderqml exampleLaszlo Agocs2019-09-111-4/+4
| | | | | | | | | | | | | | | Change-Id: Iea81662f39d2a128cea0e83a766395e0fb1e9896 Reviewed-by: Christian Strømme <[email protected]>
* | | Specify parameters of type registration in class declarationsUlf Hermann2019-09-2674-85/+129
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Using this technique we can automatically register all necessary revisions and minor versions of a type, using the metaobject system. This greatly reduces the potential for mistakes and resulting incompatibilities between versions of imports. We assume that for each type we need to register all revisions of its super types and its attached type, and that the revisions match. That is, if you import version X of type A, you will also get version X of its attached type and of any super types. As we previously didn't take these dependencies into account when manually registering the types, a number of extra revisions are now registered for some types. Potentially, we can now generate the qmltypes files at compile time, using moc. Change-Id: I7abb8a5c39f5e63ad1a0cb41a783f2c91909491b Reviewed-by: Fabian Kosmale <[email protected]> Reviewed-by: Simon Hausmann <[email protected]>
* | | Merge remote-tracking branch 'origin/5.14' into 5.15Qt Forward Merge Bot2019-09-1134-91/+1963
|\| | | | | | | | | | | Change-Id: Ic70e93d08aa91c00c9dec4e4557b871d3e8a2cae
| * | Clarify docs and comments regarding under and overlaysLaszlo Agocs2019-09-082-0/+10
| | | | | | | | | | | | | | | Change-Id: I8973798996b6c775f425819af1d6a09f1773a9dc Reviewed-by: Andy Nichols <[email protected]>
| * | Add metaltextureimport exampleLaszlo Agocs2019-09-0811-1/+878
| | | | | | | | | | | | | | | Change-Id: I499c21083faf6096a0dc3b8ee5682dd5cbcd3ce7 Reviewed-by: Andy Nichols <[email protected]>
| * | rendernode example: Prevent gui-render thread data raceLaszlo Agocs2019-09-089-81/+114
| | | | | | | | | | | | | | | | | | | | | | | | By taking things like the item width and height in updatePaintNode() (while gui is locked). Change-Id: I840c6c858a0478eb6ceb09653fd1e033cb54372d Reviewed-by: Andy Nichols <[email protected]>
| * | Make vulkanunderqml work and update docsLaszlo Agocs2019-09-081-5/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | What we are doing for now is setting ExternalContentsInPass always. This way vulkanunderqml works as expected. For applications that do not integrate external rendering this means that there is now an additional secondary command buffer per render pass, but we can live with this for now. Later (Qt 6) there should be a way to declare this (that the application will want to issue native rendering stuff) up front in QQuickWindow or somewhere. Change-Id: I736741f9b0eee2f8295b046bacdce862e6a546f5 Reviewed-by: Andy Nichols <[email protected]>