summaryrefslogtreecommitdiffstats
path: root/src/corelib/doc
Commit message (Collapse)AuthorAgeFilesLines
* 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>
* Clean up QCollator's documentation and tell fewer liesEdward Welbourne2020-11-271-0/+58
| | | | | | | | | | | | | | | | | | | | Its collation strategy can't be passed to the constructor, so describing it as initialized with a strategy was misleading. The "Linux without ICU" disclaimer was poorly phrased and only mentioned on one of the options; it actually applies to all. The operator() was marked internal, but the class doc's claim that QCollator can be used with std::sort() relies on it being callable. Moved option descriptions to the getters and filled in the missing ones. Mention the default in all cases. Added a minimal illustration of how to use a QCollator. Fixes: QTBUG-72233 Change-Id: Ifa846eca05e8e42aaa08c4947a59a82d8a8a79bc Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Doc: Improve *_CAST_FROM_ASCII documentationKai Koehne2020-11-271-6/+0
| | | | | | Pick-to: 5.15 6.0 Change-Id: Iba73c0a38e2c4add740aab20036aa39c56eb4d98 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Fix broken \endcode marker in Qt 6 porting docsFlorian Bruhin2020-11-271-1/+1
| | | | | | | Change-Id: I8dfd72f6a00a6c91a38bb201b14524b0bc7cf100 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> (cherry picked from commit e723f0aceb7de3b52fb40de3ef1fe0259fce47a8) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Remove deprecated algorithms from documentationMarcel Krems2020-11-261-300/+3
| | | | | Change-Id: Ie1eff48696c62ed23fedda1a9e711aeb8264432f Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
* Remove some examples from highlighted listVolker Hilsheimer2020-11-251-3/+0
| | | | | | | | | | The Local Fortune examples and the JSON Save Game don't need to be highlighted in Qt Creator. Pick-to: 6.0 6.0.0 Change-Id: I7c7c9997e9a1cfb61f94309f16be65c810b42e14 Reviewed-by: Tuukka Turunen <tuukka.turunen@qt.io> Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* Document removal of QEvent copyingVolker Hilsheimer2020-11-251-0/+39
| | | | | | Pick-to: 6.0 6.0.0 Change-Id: Ia4681fe5c5ae0953ba75f4ab24da4eec7461c719 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Update container overview documentation - section on growth strategiesAndreas Buhr2020-11-241-30/+14
| | | | | | | | | | | | The Qt container overview documentation contained outdated information on container growth strategies. This patch updates the documentation to reflect the current implementation. Task-number: QTBUG-86584 Pick-to: 6.0 Change-Id: I8fd014138f9a2e73925dafaa270d4c98ab672d96 Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Andrei Golubev <andrei.golubev@qt.io>
* Do not advise using AUTORCC anymoreKai Koehne2020-11-231-3/+0
| | | | | | | Task-number: QTBUG-87643 Pick-to: 6.0 6.0.0 Change-Id: Ib07586cc4206312044c0f0c154fa2ab2aada2c19 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Doc: Update CMake functions in Qt Core for Qt 6Kai Koehne2020-11-237-494/+115
| | | | | | Pick-to: 6.0 6.0.0 Change-Id: Ica6141f183c75f60e5b1031c0972f79de7821841 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Update landing pages and module pages in qtbaseJerome Pasion2020-11-172-3/+4
| | | | | | | | | | -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>
* Doc: Update/scrub QString documentationKarsten Heimrich2020-11-112-13/+13
| | | | | | | Fixes: QTBUG-86554 Change-Id: I3d40295115207c430ec30bbac6fb241bf897e5fa Reviewed-by: Andrei Golubev <andrei.golubev@qt.io> Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* Do not shrink on remove()Lars Knoll2020-11-091-4/+3
| | | | | | | | | | This is in line with Qt 5 behavior, how std::vector works and also how QString and QByteArray behave. If you need the shrink allocated storage, call squeeze() manually. Change-Id: I16cadd4f2a89bb2ec5de02fe69186f5da321cd06 Reviewed-by: Paul Wicking <paul.wicking@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* 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: mention that disconnecting all signals can be dangerousMitch Curtis2020-11-091-0/+34
| | | | | | | | Task-number: QTBUG-83387 Change-Id: I55c0a267e5490ba0226fd6858c18fd88cc3b8d59 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io> Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com> Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
* Doc: Fix mentioning of Qt5Core in overview pageKai Koehne2020-11-041-1/+1
| | | | | Change-Id: If6ae12117c95a6c843dfd93735590e17b8d2d2a3 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Update the porting guide for QFutureSona Kurazyan2020-11-021-4/+40
| | | | | | | | | | Document the source compatibility breaks introduced by the recent changes (ff0ba7e2d7b91fd5809cb314935a1ca1a436f6c9 and 30a1683f65fa0d01eceb7e1293abc84108d76e7f) in the porting guide. Task-number: QTBUG-87096 Change-Id: I5b725c863b1077d59074d4bd17a4456e3d87918c Reviewed-by: Allan Sandfeld Jensen <allan.jensen@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>
* Move porting guide for QtConcurrent to its designated pageSona Kurazyan2020-10-291-71/+38
| | | | | | | | | 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>
* Doc: Fix link issues for QtCoreTopi Reinio2020-10-293-16/+7
| | | | | | | | | - Fix linking to CMake manual. - Remove references to the state machine framework. Task-number: QTBUG-86295 Change-Id: I01a61088da8eb36760949f39be5e71d92de956f2 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Doc: Fix code snippet that abruptly ends the documentTopi Reinio2020-10-291-3/+3
| | | | | | | | | | Having the string '*/' appear in a quoted snippet ends the entire documentation comment. Use a parameter to the \code command to work around that. Task-number: QTBUG-86295 Change-Id: Ifcb21a4a0958724ebdb1c9e0eafdc767020d3a7b Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Remove documentation for removed qHash overloadVolker Hilsheimer2020-10-291-4/+0
| | | | | | | | QPair is an alias to std::pair in Qt 6, so no need for two qHash functions. Also remove note and snippet from std::pair overload documentation. Change-Id: Ica8f6961af1eac493e909ad06fe46f8f68542bc5 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Doc: Scrub QByteArray/QByteArrayView documentationKarsten Heimrich2020-10-291-7/+7
| | | | | | Fixes: QTBUG-86555 Change-Id: I3221e0de10e692ca767eeb69daa82da55b93e395 Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
* Add QVariant/meta-type system migration guideFabian Kosmale2020-10-281-0/+47
| | | | | | | Fixes: QTBUG-87100 Change-Id: Ib87b8d566f11bf226345101f665c675489a06d6a Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* Fix QList snippets to use qsizetype instead of intAndrei Golubev2020-10-281-3/+3
| | | | | | Task-number: QTBUG-86553 Change-Id: I37e9607e014deaeebfa9fddf2e49a04ee2194cce Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Fix copy and past error, add minor doc updateKarsten Heimrich2020-10-271-4/+6
| | | | | | Change-Id: I50d58086bf20d96993ab7c5e4790f07bbfdb8089 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io> Reviewed-by: Sona Kurazyan <sona.kurazyan@qt.io>
* Doc: Add notes on how to use View classes in Qt6Karsten Heimrich2020-10-271-0/+130
| | | | | | | Task-number: QTBUG-87168 Change-Id: I631937ebaf7cfa3ed54c6c8a3641693fda910b36 Reviewed-by: Sona Kurazyan <sona.kurazyan@qt.io> Reviewed-by: Andrei Golubev <andrei.golubev@qt.io>
* Store std::exception_ptr in QUnhandledExceptionSona Kurazyan2020-10-261-0/+16
| | | | | | | | | | | | | | | | For historical reasons Qt Concurrent reports QUnhandledException in case if an exception that is not derived from QException is thrown from a worker thread. Changing this behavior may not be a good idea, since the existing user code may rely on it. Changed QUnhandledException to wrap the std::exception_ptr to the actual exception, so that the users can obtain the information about the thrown exception if needed. [ChangeLog][QtCore][QUnhandledException] Improved QUnhandledException to store the std::exception_ptr to the actual exception thrown from a QtCocnurrent worker thread. Change-Id: I30e7c1d3e01aff6e1ed9938c421da0a888f12066 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Make STL iterators the preferred styleOle-Morten Duesund2020-10-252-178/+212
| | | | | | | | | | | Emphasize STL iterators over Java style iterators. Details about Java style iterators moved to it's own page and only briefly mentioned on the containers page. Task-number: QTBUG-86584 Change-Id: Id54863f79f90214aaae87e60cee1a66f53a044ab Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* doc: fix description in doc_src_containers.cppHiweed Mandriva2020-10-251-1/+1
| | | | | | Change-Id: Iade0a8ea7fc51df1ee624c4059f93d470abb9b08 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> Reviewed-by: <hiweedmandriva@163.com>
* Doc: Add porting Guide for QRegExpKarsten Heimrich2020-10-231-0/+251
| | | | | | Fixes: QTBUG-87101 Change-Id: I370c79e295489f4eaf8418bbd53b326f0a8e5123 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* Deprecate QVariant::TypeLars Knoll2020-10-231-1/+1
| | | | | | | | | It's been obsolete for a long time already. Make sure the compiler now warns about it and remove all remaining uses in qtbase. Change-Id: I0ff80311184dba52d2ba5f4e2fabe0d47fdc59d7 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* QList docs: remove some QVector->QList leftoversGiuseppe D'Angelo2020-10-191-17/+0
| | | | | Change-Id: I2a7b5ef07ddb07a261110914088b9942801a3c25 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Generalize the winmain/qtmain entry-point libraryTor Arne Vestbø2020-10-171-1/+1
| | | | | | | | | | The use-case is relevant for other platforms as well. Now that Qt has a module system we can also replace a lot of the hand crafted logic for linking with simpler constructs. Change-Id: Ib6853aaf81bfea79c31f2de741d65b4b56f23ef6 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Document noteworthy change in QProcessVolker Hilsheimer2020-10-161-0/+31
| | | | | Change-Id: I4d9769901aef8255fc111f33eb141e05398f0ee3 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Doc: Migration Guide for QString related changesKarsten Heimrich2020-10-151-0/+84
| | | | | | Task-number: QTBUG-87097 Change-Id: Idcdeaea5a65e91b99a08c2af03c7e76bbe5913bb Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* Add porting section for QtConcurrent and related classesSona Kurazyan2020-10-091-0/+70
| | | | | | | | Task-number: QTBUG-87096 Change-Id: Ie143db6c0d1e81f7a089799996d468360c44e2ca Reviewed-by: Andrei Golubev <andrei.golubev@qt.io> Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io> Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
* CMake: Do not use versionless targets in examples (Qt Core)Kai Koehne2020-10-092-6/+6
| | | | | | | | This is confusing, especially because it's not used in the whole snippet. Pick-to: 5.15 Change-Id: Ibd59646da2c77ac19a38441021c5e99f52015c95 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Another round of replacing 0 with nullptrAllan Sandfeld Jensen2020-10-076-7/+7
| | | | | | | | | This time based on grepping to also include documentation, tests and examples previously missed by the automatic tool. Change-Id: Ied1703f4bcc470fbc275f759ed5b7c588a5c4e9f Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Add porting section for QVector/QListAndrei Golubev2020-10-071-0/+89
| | | | | | | Fixes: QTBUG-87099 Change-Id: If8ace4f77a4d9fa3dbb24204696e2f7602a76692 Reviewed-by: Paul Wicking <paul.wicking@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* QREMatchIterator: add support for range-based forGiuseppe D'Angelo2020-09-301-0/+9
| | | | | | | | | | | | | Add begin()/end() on QRegularExpressionMatchIterator, making iterators over an iterator (like directory_iterator). [ChangeLog][QtCore][QRegularExpression] The iterator object (QRegularExpressionMatchIterator) returned by a global match is now usable in a range-based for loop. Change-Id: If3d31bd2e84e7d1fb626a0b3d2745914dff03e39 Reviewed-by: Andrei Golubev <andrei.golubev@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Doc: Fix incorrectly placed closing bracket in Q_PROPERTY codeKai Koehne2020-09-301-2/+2
| | | | | | | | Amends cb3152086c61e7c Pick-to: 5.15 Change-Id: I1615a686a53da7ca5ae454565283c9e83399d947 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* doc: Make QtCore depend on all modulesMartin Smith2020-09-291-1/+3
| | | | | | | | | | | | | | | Class QObject is the most widely used base class in Qt. It is inherited by a great many Qt classes.This update sets the depends variable in qtcore.qdocconf to '*' so that QDoc will load all the index files for all of Qt, when it generates the documentation for QtCore. In particular, this will ensure that the "Inherited By" list for class QObject will show all the Qt classes that inherit QObject. Pick-to: 5.15 Task-number: QTBUG-77126 Change-Id: I5f38400ccc798ec34e2ee80472f1fe9bb7b1877d Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Remove traces of QObject::trUtf8 from documentationVolker Hilsheimer2020-09-252-3/+1
| | | | | | | | ... and from the duplicated Q_DECLARE_TR_FUNCTION macro for QXmlStream. We expect source code to be utf8 encoded in Qt 6, so the function is gone. Change-Id: Ie25329a54e709dc92a22893ad5ab023852300d81 Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* Doc: Update CMake snippets to Qt 6Kai Koehne2020-09-251-2/+2
| | | | | | | Change-Id: I53021781a25c141db5d5fc6771192cd8d6ed732a Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Fix some qdoc warnings from QByteArrayVolker Hilsheimer2020-09-231-1/+1
| | | | | | | | A snippet bug, and removed overloads. Change-Id: I82aee3627ba1a4e75e392b28d8ec72d470c395db Reviewed-by: Andrei Golubev <andrei.golubev@qt.io> Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Documentation: purge QSet and QHash members that no longer existVolker Hilsheimer2020-09-231-9/+0
| | | | | | | | | | | | QMutableSet/HashIterator can not walk backwards, neither can the STL iterator. When function documentation was shared with other iterator types, move it into separate section to avoid linking to incorrect see-alsos. Remove or fix other member function documentation that had errors, e.g. in parameter types after move to qsizetype. Change-Id: Ic7f97a295eff63ee748998b10f08a160706fa650 Reviewed-by: Lars Knoll <lars.knoll@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>
* Q(Any|Utf8)StringView: move array size deduction feature to fromArrayMårten Nordheim2020-09-183-11/+2
| | | | | | | | | | | | | The constructor taking an array literal will now stop at the first null-terminator encountered. And fromArray is introduced which only supports array literals. Constructs a view of the full size. Explicit so it shouldn't be surprising. Change-Id: I1497c33a5c12453a95e87c990abe6335b2817081 Reviewed-by: Andrei Golubev <andrei.golubev@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* QByteArrayView: move array size deduction feature to fromArrayMårten Nordheim2020-09-181-7/+0
| | | | | | | | | | | | | | | | 1. Make the ctor unable to construct a QByteArrayView from array literals other than 'char'. With the new behavior it would either be (very likely) unintended to pass e.g. a std::byte array to the ctor. And it would be confusing because you would get different sizes based on signed-ness. 2. Introduce fromArray Only supports array literals. Constructs a view of the full size. Explicit so it shouldn't be surprising. Change-Id: Ifdb55eb21057dfe7053b2561bd81e2c9825e9bc6 Reviewed-by: Andrei Golubev <andrei.golubev@qt.io> Reviewed-by: Sona Kurazyan <sona.kurazyan@qt.io> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>