summaryrefslogtreecommitdiffstats
path: root/src/concurrent/doc
Commit message (Collapse)AuthorAgeFilesLines
* Correct doc snippet licenseLucie Gérard2024-02-281-1/+1
| | | | | | | | | | | | | | All file under doc/snippet should be license as Documentation snippets and according to QUIP-18 [1] this is LicenseRef-Qt-Commercial OR BSD-3-Clause [1]: https://contribute.qt-project.org/quips/18 Pick-to: 6.7 Task-number: QTBUG-121787 Change-Id: I76eedfb6b15c4091f726a5652e3530001d7cdaf7 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Doc: Fix warnings and linking issuesTopi Reinio2023-10-091-0/+3
| | | | | | | | | | | | | | | | | | | | Remove or replace links to examples that were removed or moved under manual tests. Replace code snippets that were quoting the now-missing examples. Fix documentation of QSet::removeIf(). Fix typo in documentation macro: Unknown command '\examplecateogry'. Add qtopengl, qtshadertools dependencies to Qt Widgets documentation project to enable correct linking to those topics. Mark all documentation sets in qtbase as free of warnings. Pick-to: 6.6 6.5 Change-Id: I058cd5f2063aa933ea310bceff906f05422a7cb2 Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
* Use a global value for warning limit when testing documentation in CITopi Reinio2023-06-271-3/+0
| | | | | | | | | | | | | | | | | | | The most common limit for the maximum number of allowed documentation warnings is zero. Use a global value for 'warninglimit', adopted by all Qt module documentation projects that include the configuration from qtbase/doc/global. This allows for a temporary increase of the limit across all modules as needed - for example, when updating the QDoc binary that the CI provisions to a version that introduces new types of documentation warnings. Increase this base limit temporarily to 10 to help re-enable documentation testing in CI as it's currently disabled. Task-number: QTBUG-113326 Change-Id: I8b66951ca9324bcfaec3b5a7ec2cff544c62feb0 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* QVariant::value/qvariant_cast: add rvalue optimizationFabian Kosmale2023-06-121-1/+1
| | | | | | | | | | | | | | If we have a rvalue reference to an unshared QVariant, we can avoid potentially expensive copies, and use move semantics instead. [ChangeLog][QtCore][QVariant] Added rvalue QVariant overloads of qvariant_cast<T>() and QVariant::value<T>(). [ChangeLog][Potentially Source-Incompatible Changes][QVariant] It is no longer possible to take the address of a specialization of qvariant_cast; consider using a lambda function instead. Change-Id: Ifc74991eadcc31387b755c45484224a3200bb0ba Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Clarify module changes in Qt6Jaishree Vyas2023-05-091-1/+1
| | | | | | | | | Changed Briefs for better understanding Fixes: QTBUG-109324 Pick-to: 6.5 Change-Id: I15b0c0dc12b1bf96626fb8ea4ad16d04b2b118ca Reviewed-by: Kai Köhne <kai.koehne@qt.io>
* Rework imagescaling example to avoid potential crashesIvan Solovev2023-04-261-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | Creating a continuation with QtFuture::Launch::Async policy does not work well with the example, because it still needs to update the UI once the async continuation is finished. If the user decides to close the application while the async continuation is executed, the next continuation will be accessing data from the destroyed Images object. Fix it by using QtConcurrent::run() to do the "heavy" work in a separate thread, and use a QFutureWatcher to handle the results of the async execution. Update the example documentation accordingly. After this patch the example still shows the usage of continuations and onCanceled()/onFailed() handlers. However, it now does not illustrate the usage of different launch policies and continuation contexts. It might not be a big issue, because the QFuture documentation describes these topics rather extensively. Fixes: QTBUG-103514 Pick-to: 6.5 Change-Id: I8142535064ff7a4e8007a5c0a8fe7709d6d942ec Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io> Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
* Add QtConcurrent Examples pageIvan Solovev2023-02-243-1/+24
| | | | | | | | | | | | | The QtConcurrent examples were only discoverable from the "All Qt Examples" page, which was very inconvenient. This patch adds a separate page for all Qt Concurrent examples, and links to it from the module's main page. Pick-to: 6.5 Change-Id: Iecabd9e21033605c1ec74232ce4f3d68b0c78d82 Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io> Reviewed-by: Jaishree Vyas <jaishree.vyas@qt.io>
* Change the license of all CMakeLists.txt and *.cmake files to BSDLucie Gérard2022-08-231-1/+1
| | | | | | | Task-number: QTBUG-105718 Change-Id: I5d3ef70a31235868b9be6cb479b7621bf2a8ba39 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
* Add license headers to cmake filesLucie Gérard2022-08-031-0/+3
| | | | | | | | | | | | CMakeLists.txt and .cmake files of significant size (more than 2 lines according to our check in tst_license.pl) now have the copyright and license header. Existing copyright statements remain intact Task-number: QTBUG-88621 Change-Id: I3b98cdc55ead806ec81ce09af9271f9b95af97fa Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
* Use SPDX license identifiersLucie Gérard2022-05-167-274/+14
| | | | | | | | | | | | | Replace the current license disclaimer in files by a SPDX-License-Identifier. Files that have to be modified by hand are modified. License files are organized under LICENSES directory. Task-number: QTBUG-67283 Change-Id: Id880c92784c40f3bbde861c0d93f58151c18b9f1 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
* Do not highlight the Image Scaling Example anymore in Qt CreatorKai Köhne2022-02-171-2/+0
| | | | | | | | Pick-to: 6.3 Fixes: QTBUG-100645 Change-Id: I9f2e2c022a00a024917327028b403d36ca2a4b48 Reviewed-by: Kimmo Leppälä <kimmo.leppala@qt.io> Reviewed-by: Sona Kurazyan <sona.kurazyan@qt.io>
* Doc: Use find_package(Qt6 REQUIRED COMPONENTS ...) idiomKai Köhne2021-12-091-1/+1
| | | | | | | | | | Using REQUIRED as a prefix instead of suffix works better with OPTIONAL_COMPONENTS, and is also the order in the CMake manual. Task-number: QTBUG-98867 Pick-to: 6.2 Change-Id: I1ab68408b95d8edf06272a3b9fceccd8d8e597fc Reviewed-by: Alexey Edelev <alexey.edelev@qt.io>
* Doc: Enable qdoc warning count limitVenugopal Shivashankar2021-10-211-0/+3
| | | | | | | | This should restrict changes that introduce new warnings. Change-Id: I7e4b5d9d5d84b7c336509c380bc7e6d86e360f4a Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
* concurrent: Fix typo in documentationJonas Kvinge2021-10-121-1/+1
| | | | | | Pick-to: 6.2 Change-Id: Ibe3715de704f420ba3796d19c9e78cd6204eb4e5 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Doc: Remove unsupported customFiltersKai Köhne2021-09-031-4/+0
| | | | | | | | | | | customFilters defined in .qdocconf are not supported anymore by Qt Assistant since Qt 5.13. Therefore remove them from all .qdocconf files, also to avoid cargo-culting them to new help modules. Task-number: QTBUG-95987 Change-Id: I664391460637d2e859348da0338e1a4a3ee9f570 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* QtConcurrent: fix examples of overloaded methods in docsSona Kurazyan2021-08-182-6/+10
| | | | | | | | | | | | Wrap the overloaded methods in qOverload(), to make the examples compile. Also remove the extra whitespaces when declaring nested templates. Pick-to: 6.1 6.2 Change-Id: If438caa6d705d9036dae45278fb26e080918da89 Reviewed-by: Karsten Heimrich <karsten.heimrich@qt.io> Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
* Update QtConcurrent docs and examples for reductor object usageSona Kurazyan2021-07-262-11/+7
| | | | | | | | | After 6ebe3d0f0806069f906522dfe9b81baa3f3478de users don't have to specify the result type when using functors for as a reductor. Task-number: QTBUG-88448 Change-Id: I065fed11c1a66833ba0aac3d18e7ff0545247be1 Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
* Revert "Remove the qmake project files" for snippetsNico Vertriest2021-02-121-0/+3
| | | | | | | | | | | This reverts a limited part of commit ad2da2d27a590333fc89a56fc58700a09c3017b3 that deleted .pro files for snippets compilation. Some .pro files which contain snippets used in the documentation itself should be restored. Task-number: QTBUG-90483 Change-Id: I1b03833c8ff17b5fca43a5b6c5417e8545b1711b Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
* Remove the qmake project filesJoerg Bornemann2021-01-071-3/+0
| | | | | | | | | | | | | | | | Remove the qmake project files for most of Qt. Leave the qmake project files for examples, because we still test those in the CI to ensure qmake does not regress. Also leave the qmake project files for utils and other minor parts that lack CMake project files. Task-number: QTBUG-88742 Change-Id: I6cdf059e6204816f617f9624f3ea9822703f73cc Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* Document that QtConcurrent::run doesn't support overloaded functionsSona Kurazyan2020-12-232-0/+23
| | | | | | | | | | | | After improving QtConcurrent::run() to use parameter packs for the arguments (see c977e74afd18afff8729070f631e6b7a3f2887f5), calling overloaded functions is ambiguous. Updated the porting guide and the documentation to mention this and describe possible workarounds. Task-number: QTBUG-89648 Pick-to: 6.0 Change-Id: I4c1f996ae67bce8c13cc1f99f54240295db6ae1d Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
* Clean up qtconcurrent.qdocconf fileKai Koehne2020-12-101-2/+1
| | | | | | | | Remove unused parent directory for exampledirs. Also fix content of excludedirs. Change-Id: Iac15ec3eb12121c0384e36c31299034624257db4 Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
* Doc: Use explicit linkage with target_link_librariesKai Koehne2020-11-301-1/+1
| | | | | | | | | | | | | | The Professional CMake book suggests always using explicit linkage with target_link_libraries, so let's use that. Whether to use PUBLIC or PRIVATE depends on the context. But let's be conservative and advise on using PRIVATE by default. Task-number: QTBUG-88935 Pick-to: 6.0 Change-Id: I12b80ee85be9f6916f1e4dea6b1c9cb29e03c20f Reviewed-by: Craig Scott <craig.scott@qt.io> Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Update landing pages and module pages in qtbaseJerome Pasion2020-11-172-28/+29
| | | | | | | | | | -Qt SQL, Qt D-BUS, Qt GUI, Qt OpenGL, Qt Widgets, Qt Test, Qt Concurrent, Qt XML, Qt Network, Qt Core -language edits for consistency, add links Task-number: QTBUG-87155 Change-Id: Ic61350c9fa15090c802a42d8e9116219591eba73 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Don't highlight the QtConcurrent progress dialog exampleSona Kurazyan2020-11-121-2/+1
| | | | | Change-Id: Iaccfc5b8d30f6903c5d27b5ed379d1ca364f7c69 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Improve QtConcurrent ImageScaling example to demo new featuresSona Kurazyan2020-11-121-1/+2
| | | | | | | | | | | | | In order to demonstrate the new functionality, changed the example to download the images from the network, scale and show them by attaching different continuations to QFuture. Because QtConcurrent::map is not used anymore, removed the suspension functionality (supporting suspension of download would complicate the logic). Task-number: QTBUG-87205 Change-Id: I5a48b63195d28025ae8c5de28bc6d6178dad03db Reviewed-by: Paul Wicking <paul.wicking@qt.io> Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
* Rename "Porting" pages to "Changes"Jerome Pasion2020-11-092-3/+3
| | | | | | | | | | | | | | The content in the porting guides are closer to a changelog than a porting guide. At this point, it is easier for maintainers and contributors to write in a changelog than a guide. This change should help with readability and is closer to the usage of "Changes" in documentation. Part of a rename in other submodules. Task-number: QTBUG-87156 Change-Id: Ib59de7976fae19e7b39962e80161df6628e4070b Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Doc: Prefer versioned CMake library targetsv6.0.0-beta3Kai Koehne2020-11-011-1/+1
| | | | | | | | The non-versioned one's do miss some properties. It's therefore best to not advocate using them. Change-Id: I53645e65ed4de4e0100e59905c024cdfe40be0c5 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Doc: Fix links to the CMake manualTopi Reinio2020-10-301-1/+1
| | | | | | Task-number: QTBUG-86295 Change-Id: I7b2208284d65ec9182352490bd4c92458c5e5e37 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Move porting guide for QtConcurrent to its designated pageSona Kurazyan2020-10-291-1/+31
| | | | | | | | | Also move the porting section for QFuture and related classes after the section for view classes, to make the order more natural for reading. Change-Id: I5ea816d7bb3dfdda2b74112418bf07954c9ec94c Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io> Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
* QtConcurrent: Handle running with promise inside QTaskBuilderJarek Kobus2020-10-281-0/+9
| | | | | | | | | | | Please note, that in case of run with promise it doesn't make sense to provide the overload taking the FutureResult, as if we are going to ignore the returned QFuture object, we can't communicate with the passed QPromise. Fixes: QTBUG-87083 Change-Id: I4066506736c2bbeea3e42030b9495f13e06cb27e Reviewed-by: Sona Kurazyan <sona.kurazyan@qt.io>
* QtConcurrent: Integrate runWithPromise into runJarek Kobus2020-10-282-13/+8
| | | | | | Change-Id: I6eb95aa66ff847e8bb9aac348fded3a5d55015b6 Reviewed-by: Paul Wicking <paul.wicking@qt.io> Reviewed-by: Sona Kurazyan <sona.kurazyan@qt.io>
* Fix some qdoc warnings: QtConcurrent functors and exceptionsVolker Hilsheimer2020-09-221-14/+0
| | | | | Change-Id: I32e45c85cedb74a6dcbd99930910b730f1160fae Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Doc: Correct link errors qtbaseNico Vertriest2020-09-211-1/+1
| | | | | | Task-number: QTBUG-86295 Change-Id: I27f6bbdadffb08a8794520a14dfe0e2334979575 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Doc: Add links to Qt 6 changes files from module indexPaul Wicking2020-09-181-0/+4
| | | | | | Task-number: QTBUG-84051 Change-Id: Iac25df135c9d73a990b41243e08cd38ea78296a4 Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* Doc: Add porting guide documentsPaul Wicking2020-09-161-0/+46
| | | | | | | | Also add existing such docs to the new document group Task-number: QTBUG-84051 Change-Id: I76f033f0846e09943f249d2beeb1606869eef382 Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
* Mention QPromise on QtConcurrent pageJarek Kobus2020-09-011-0/+4
| | | | | | | Change-Id: I82d3ddd4a9129694d6dedcc742165cb2af135527 Reviewed-by: Andrei Golubev <andrei.golubev@qt.io> Reviewed-by: Sona Kurazyan <sona.kurazyan@qt.io> Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* QtConcurrent: Add documentation for runWithPromise()Jarek Kobus2020-08-262-1/+92
| | | | | | Task-number: QTBUG-84702 Change-Id: Ic8233aeffbdbd1420bdbde7ad7d03f25cd438ea8 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Fix the doc exampleJarek Kobus2020-08-191-1/+1
| | | | | | | | The intention is to return list containing two items, not just one. Change-Id: I96f3ce939f2ef6db6bdac5d9165bb7814ebfa91a Reviewed-by: Andrei Golubev <andrei.golubev@qt.io> Reviewed-by: Sona Kurazyan <sona.kurazyan@qt.io>
* Use QList instead of QVector in qtbaseJarek Kobus2020-07-073-18/+18
| | | | | | | | Fixes all other QVector occurrences Task-number: QTBUG-84469 Change-Id: I5f9311298d341a9a3061a6a640539583d1618939 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Doc: Update docs with cmake package informationNico Vertriest2020-06-301-0/+1
| | | | | | Task-number: QTBUG-85179 Change-Id: I70dda9b906ecd0b8d8f4d88b0562af8e6c428143 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Document how to use CMake for Qt ConcurrentKai Koehne2020-05-264-4/+20
| | | | | | Task-number: QTBUG-73058 Change-Id: I11398c5837b45ccacb9232609317213133ef20ea Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* Licenses: Remove reference to change in Qt 5.4Kai Koehne2020-05-221-3/+2
| | | | | | | Qt 5.4 is not documented anymore since quite some time. Change-Id: I6811ead502178f7acbed8cf450e42d7fd33ae29b Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* Improve Map|Map-Reduce and Filter|Filter-Reduce implementationKarsten Heimrich2020-04-142-3/+90
| | | | | | | | | | | | | * support lambda expressions * remove the need to specify result_type * use std::invoke to apply map|filter function * remove usage of FunctionWrapper* and createFunctionWrapper Task-number: QTBUG-33735 Task-number: QTBUG-82646 Change-Id: Ibcbe4278f0742c29182bd506081db0abb516f85f Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io> Reviewed-by: Sona Kurazyan <sona.kurazyan@qt.io>
* QTaskBuilder::spawn: add an overload that doesn't return a future objectVitaly Fanaskov2020-04-141-0/+4
| | | | | | Fixes: QTBUG-83175 Change-Id: Idf85e47a2732742884272200d5c753805eaa640b Reviewed-by: Sona Kurazyan <sona.kurazyan@qt.io>
* QtConcurrent: add fluent interface to configure a task before runVitaly Fanaskov2020-03-292-0/+134
| | | | | | | | Task-number: QTBUG-82950 Change-Id: I449da938b6b501a7646b3425edde5c880d6ca87e Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Paul Wicking <paul.wicking@qt.io> Reviewed-by: Mikhail Svetkin <mikhail.svetkin@gmail.com>
* QtConcurrent::run: accept more then five function's argumentsVitaly Fanaskov2020-03-111-3/+33
| | | | | | | | | | | | | | [ChangeLog][Potentially Source-Incompatible Changes] QtConcurrent::run has the following signatures: run(Function &&f, Args &&...args) and run(QThreadPool *pool, Function &&f, Args &&...args). If f is a member pointer, the first argument of args should be an object for which that member is defined (or a reference, or a pointer to it). See the documentation for more details. Fixes: QTBUG-82383 Change-Id: I18f7fcfb2adbdd9f75b29c346bd3516304e32d31 Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io> Reviewed-by: Sona Kurazyan <sona.kurazyan@qt.io>
* Remove QLinkedListSona Kurazyan2020-02-191-1/+1
| | | | | | | | | | | | | QLinkedList has been moved to Qt5Compat. Remove and stop mentioning it in docs, examples (the docs & examples for QLinkedList itself will be moved to Qt5Compat) and remove the corresponding tests. Also remove QT_NO_LINKED_LIST, since it's not needed anymore. Task-number: QTBUG-81630 Task-number: QTBUG-80312 Change-Id: I4a8f1105cb60aa87e7fd67e901ec1a27c489aa31 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Doc: Replace example file lists with links to code.qt.ioTopi Reinio2019-05-031-0/+1
| | | | | | | | | | | | | | Instead of generating .html page for each file in an example project, generate links to code.qt.io, under the correct path and branch, where the user can browse the example source. Store all URLs under QT_INSTALL_DOCS/config where other qt5 submodules can access them. The repository name appears in the URL, so we cannot define a single URL for all modules. Task-number: QTBUG-74391 Change-Id: I63d4d6d2c352877797b1ee8e057d48c0cd789bff Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Doc: Fix typo and grammar issuesPaul Wicking2018-07-091-9/+9
| | | | | | | | | Fixed typo in code snippet (s/string/strings/). Capitalized start of sentence in comments and added missing dots. Task-number: QTBUG-69331 Change-Id: I397d4f2082c859c014f776ff8e169b6a6cbe4e79 Reviewed-by: Nico Vertriest <nico.vertriest@qt.io>
* Doc: Add missing full stops in briefsPaul Wicking2018-06-211-1/+1
| | | | | | Task-number: QTBUG-68933 Change-Id: I3f2a9f8c562f9a44bb32bddd31d75abbfe6de04d Reviewed-by: Topi Reiniö <topi.reinio@qt.io>