summaryrefslogtreecommitdiffstats
path: root/src/corelib/global
Commit message (Collapse)AuthorAgeFilesLines
* Properly deprecate Qt::MidButton in favor of Qt::MiddleButtonEdward Welbourne2020-08-222-3/+5
| | | | | | | | | | | | MidButton had its // ### Qt 5: remove me upgraded to Qt 6 at 5.0; but it dates back to 4.7.0 Replace the many remaining uses of MidButton with MiddleButton in the process. Pick-to: 5.15 Change-Id: Idc1b1b1816673dfdb344d703d101febc823a76ff Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* QIODevice: implement a "zero-copy" strategy for buffered writesAlex Trotsenko2020-08-201-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | It works as follows: - user calls write(const QByteArray &); - this function keeps a pointer to the chunk and calls a regular write(data, len); - write(data, len) calls a virtual writeData(); - subclass calls a new QIODevicePrivate::write(); - QIODevicePrivate::write() makes a shallow copy of the byte array. Proposed solution is fully compatible with existing subclasses. By replacing a call to d->writeBuffer.append() with d->write(), subclasses can improve their performance. Bump the TypeInformationVersion field in qtHookData, to notify the Qt Creator developers that the offset of QFilePrivate::fileName was changed and dumpers should be adapted. Change-Id: I24713386cc74a9f37e5223c617e4b1ba97f968dc Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@gmx.de> Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
* Tidy up qnamespace.qdoc's enums' \omitvalue entriesEdward Welbourne2020-08-201-39/+36
| | | | | | | | | Moved \omitvalue entries to the end (unless there was only one, at the start). Sorted Qt::WidgetAttribute's to match their order in the declaration, as there were many and their order was haphazard. Change-Id: I41d27df0fc293f642f931177b0d8884fbbcb9b77 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Fix a number of qdoc warningsFriedemann Kleint2020-08-201-0/+1
| | | | | | | | | | | - Remove obsolete functions and enumeration values - Remove QObject * parameter from QMetaProperty accessors - Fix renamed enumerations in QSsl - Fix list items to be \li - Fix function signatures and variable names Change-Id: I37c7e6bf2c8ff92bc7b82620bae0a27796f866ab Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Use [[nodiscard]] with clang in C++17 modeAllan Sandfeld Jensen2020-08-181-2/+2
| | | | | | | | | | It is only broken in C++11/c++14 mode. We do need to fix the order of visibility-attributes and this C++ attribute. Change-Id: I41e4367f1aaa9241fec4e336c39e58b798336b2c Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Follow through on ### Qt6 comments in qglobal.hEdward Welbourne2020-08-181-20/+0
| | | | | | | | | | Left the translation NOOP for later, pending advice on how to fix QIODevice, which doesn't compile without them. Task-number: QTBUG-85700 Change-Id: Icc423ecabb43714d98b5d9b0f9a96c5bb6ef1d78 Reviewed-by: Martin Storsjö <martin@martin.st> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Introduce QWidget::setScreenVolker Hilsheimer2020-08-171-1/+1
| | | | | | | | | | | | | | | | | | Follows the QWindow semantics, and is a replacement for creating a QWidget with a QDesktopScreenWidget as the parent. We can now remove much of the special handling of QDesktopWidget and the Qt::Desktop window type, and get rid of QDesktopScreenWidget. Add a manual test that allows local testing. Our CI environments only have a single screen, and no multi-head display server setup which is the primary case where QWidget::setScreen is interesting. For the more common case of a virtual desktop, QWidget::setScreen has no real impact (just as QWindow::setScreen doesn't). Change-Id: Id0099e069d316741bacd8c795c396ccad37be297 Fixes: QTBUG-85483 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* Remove dead code in qrandomVolker Hilsheimer2020-08-171-25/+0
| | | | | | | | | After 9ee554ac1d1af97e7ad5b4bf78e2779f7d1c405f, the various static inline versions of randTLS are no longer used, which clang warns about. Change-Id: I6dc21c0aab35fb6a8ca9e8d43ee4960ee844ef47 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Remove friend declarations that aren't requiredLars Knoll2020-08-151-2/+0
| | | | | | | | | | | | Those are problematic as they are also interpreted as forward declarations of methods that are defined inline in qdatastream.h and might never get instantiated. This can lead to problems if template code checks for the existence of the method. Change-Id: I4550a6bc70ebd7edc57fe0420b89b453195971d0 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Constrain the data stream operators for containersLars Knoll2020-08-151-0/+11
| | | | | | | | | | | Check that we can successfully instantiate the data stream operator for a container before we actually try. This is required so we can automate registration of debug stream operators with QMetaType. Change-Id: Ib100a5242470d7fc8067058cc4d81af2fa9354b0 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Constrain the debug stream operators for containersLars Knoll2020-08-151-0/+19
| | | | | | | | | | | Check that we can successfully instantiate the debug stream operator for a container before we actually try. This is required so we can automate registration of debug stream operators with QMetaType. Change-Id: I3943e7a443751d250c33b2ca1b9cf29207cfe6c4 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Replace Qt CONSTEXPR defines with constexprAllan Sandfeld Jensen2020-08-149-116/+116
| | | | | | | | Both normal and relaxed constexpr are required by our new minimum of C++17. Change-Id: Ic028b88a2e7a6cb7d5925f3133b9d54859a81744 Reviewed-by: Sona Kurazyan <sona.kurazyan@qt.io>
* qglobal.h: remove deprecated global functionsEdward Welbourne2020-08-144-106/+1
| | | | | | | | Since 5.0 - qMalloc(), qFree(), qRealloc(), qMemCopy(), qMemSet() Since 5.15 - qsrand(), qrand() Change-Id: I74fa3d17b05521271c3dc563fc85a5b133289ce3 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* CMake: Allow specifying a sysconfdir that's outside the prefixAlexandru Croitor2020-08-131-1/+1
| | | | | | | | | Also use the value to actually write it into qconfig.cpp so that qmake reports the right information. Change-Id: Icc4bf36b0dc6ad75d93ac16f39e5b361c0ce52b4 Fixes: QTBUG-81289 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Avoid UB in moc generated codeLars Knoll2020-08-072-0/+16
| | | | | | | | | | | | | | Introduce a Q_OFFSETOF() macro that uses the optional support of offsetof() for non standard layout types and disables the corresponding compiler warnings. All our supported compilers support offsetof() on non standard layout types. Use the macro to do the offset calculations required in moc generated code to replace a manual offset calculation that was dereferencing a null pointer. Change-Id: I4aab3af3c8bbaa90372f2234aa1cf8399d023c22 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Remove deprecated binary json featureEdward Welbourne2020-07-311-1/+0
| | | | | | | | | Deprecated in 5.15 in favor of CBOR. Fixes: QTBUG-81239 Change-Id: I711d4bd7dd1247f58e77ac9fa53304cbe5028918 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Add float->qfloat16 rounding and fix the testsAllan Sandfeld Jensen2020-07-311-2/+14
| | | | | | | | | | | | Our hardware optimized conversions of float to qfloat16 rounds to even where our table based conversion truncated to zero. The rounding is not in this patch exactly round to even like the hardware implementation but much closer. Change-Id: I4c5e72c15fef9079d3660680b2727ff7ba4e768a Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Document run-time acceleration of using the conversions functionsAllan Sandfeld Jensen2020-07-301-0/+10
| | | | | | Pick-to: 5.15 Change-Id: I985b93135b9d8fdfdd64e9183b23cbf8a7b4e3eb Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Add QOperatingSystemVersion support for macOS Big SurTor Arne Vestbø2020-07-293-0/+32
| | | | | | | | | Pick-to: 5.15 Pick-to: 5.12 Change-Id: Ide57f675b20b08210f301da5177df45d008423c4 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
* Make qfloat16 helper functions consistent with float/double versionsAllan Sandfeld Jensen2020-07-281-5/+5
| | | | | | | | | | Infinite is only when the mantissa is 0, everything else is NaN. std::isnormal returns false on zero. Pick-to: 5.15 Change-Id: I897fc0dc3b8a9c557bb1922ea7ca8df501e91859 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Avoid claiming F16C support on non-x86 platformsTor Arne Vestbø2020-07-261-0/+1
| | | | | | | | | | | | | | The configuration tests might indicate the compiler supports F16C, due to building the tests as x86. But in a multi arch situation, such as when doing universal builds for x86_64 and arm64, we must also verify that the current complication unit is building for x86. Instead of adding Q_PROCESSOR_X86 checks to each call site that checks for F16C, we sanitize the F16C support define as we do for other CPU feature defines. Change-Id: I9ef53c9d47690dddb0b1b82f77b0ebf74f3295bb Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Remove non-Qt6 compile time switches from QtCoreAllan Sandfeld Jensen2020-07-243-9/+2
| | | | | | | | We already manage to compile without this code, and none of it are full classes or separate functions suitable for qt5compat. Change-Id: I47facac7ec621cfc4b0b26214b7de37897443519 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Fix a number of qdoc warnings related to deprecationFriedemann Kleint2020-07-242-16/+0
| | | | | | | Remove obsolete documentation. Change-Id: Iaf4b6f9852a883dea0f256c5c89e74f6ebbe85f3 Reviewed-by: Sona Kurazyan <sona.kurazyan@qt.io>
* QLogging: purge deprecated qInstallMsgHandler(QtMsgHandler)Edward Welbourne2020-07-232-31/+1
| | | | | | | | Deprecated since 5.0. Renamed a function in a manual test that no longer needs to say it's Qt5-specific. Change-Id: I6f2159c702f389d378a0e4d86bd4fe633298b100 Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* Deal with macOS not enabling AVX512 state in XCR0Thiago Macieira2020-07-221-18/+50
| | | | | | | | | | | | | | | | | | | | | | | All Mac Pros launched since 2019 have AVX512 support (CLX processor) but the Darwin kernel does not enable the state bits in the XCR0 register for all processes by default. Instead, it traps the #UD exception and decodes the instruction to find out if it was an AVX512 instruction. If so, it adds memory to the thread's context switch space. See [1]. Good solution, but forces us to have OS-specific code to determine if the OS really supports AVX512. No other OS appears to require this. For future features (namely, Intel Advanced Matrix Extensions), there's an official way of implementing this, via the eXtended Feature Disable register. Qt has no AVX512 code yet, so this is just being future-proof. Apple has yet to announce when or if their Mac Pros will switch from Intel Xeon to ARM. [1] https://github.com/apple/darwin-xnu/blob/xnu-4903.221.2/osfmk/i386/fpu.c#L174 Change-Id: Ieffc3453b88c4517a1dbfffd162175ead343e622 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* QSysInfo: remove deprecated windowsVersion() and macVersion()Edward Welbourne2020-07-223-378/+0
| | | | | | | | | Remove their associated enums, too. All deprecated since 5.9. Change-Id: Ieefba1a08c221ea7b62500f219baea8a3ccfb7db Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* Update documentation of Qt::TextDateEdward Welbourne2020-07-151-1/+1
| | | | | | | | | This follows up on commit 5ba66c5622e9e0da87a5037399b375d7e8cee554, which removed all locale-dependence from QDateTime; I neglected the doc of the DateFormat enum. Change-Id: I244db9c6e1ab47892162c7f441c2b4202662e6e4 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* qtypeinfo: Improve container checkFabian Kosmale2020-07-141-6/+13
| | | | | | | | | | | | | Smart pointers like QSharedPointer<T> do have a value_type, but their equality does not depend on T being comparable. Therefore, instead of simply checking for T::value_type, test for a few other container requirements. This also required to add an additional check for std::optional, as that one has an unconstrained operator== on MSVC. Change-Id: Iefd048f7aa360f4713ecd79f80acd7dae72ee18c Reviewed-by: Ulf Hermann <ulf.hermann@qt.io> Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Clarify relation between Qt::Keys and Unicode rangesTor Arne Vestbø2020-07-101-101/+114
| | | | | | | | | | | | | | The Qt::Keys have been re-ordered and comments added to reflect the layout of the enum values in relation to the Unicode ranges. Bits 0x00200000, 0x00400000, and 0x00800000 have been reserved in case we want to use them for Qt::ModifierKey later on. Doing so would require changing Qt::Key_unknown to not overlap with these bits, or to accept that Modifier + Qt::Key_unknown is not a supported usecase. Change-Id: I580a01b0a47a28948a0f0018c47931395933b8f2 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Refactor pointer event hierarchyShawn Rutledge2020-07-101-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some goals that have hopefully been achieved are: - make QPointerEvent and QEventPoint resemble their Qt Quick counterparts to such an extent that we can remove those wrappers and go back to delivering the original events in Qt Quick - make QEventPoint much smaller than QTouchEvent::TouchPoint, with no pimpl - remove most public setters - reduce the usage of complex constructors that take many arguments - don't repeat ourselves: move accessors and storage upwards rather than having redundant ones in subclasses - standardize the set of accessors in QPointerEvent - maintain source compatibility as much as possible: do not require modifying event-handling code in any QWidget subclass To avoid public setters we now introduce a few QMutable* subclasses. This is a bit like the Builder pattern except that it doesn't involve constructing a separate disposable object: the main event type can be cast to the mutable type at any time to enable modifications, iff the code is linked with gui-private. Therefore event classes can have less-"complete" constructors, because internal Qt code can use setters the same way it could use the ones in QTouchEvent before; and the event classes don't need many friends. Even some read-accessors can be kept private unless we are sure we want to expose them. Task-number: QTBUG-46266 Fixes: QTBUG-72173 Change-Id: I740e4e40165b7bc41223d38b200bbc2b403e07b6 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Rename local variable hiding global one with the same nameDimitrios Apostolou2020-07-101-4/+4
| | | | | | | As found by LGTM.com. Change-Id: Ic4c38c02529e7cc7eb7c79c3936b7d5f030fd84f Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Qt::Modifier: do some cleanupsGiuseppe D'Angelo2020-07-092-3/+1
| | | | | | | | | | | | | | | | | | Qt::UNICODE_ACCEL had no effect since at least Qt 4.0. We can drop it in Qt 6. The whole Qt::Modifier enumeration is still widely used, so we can't drop it yet, but we should aim at doing so in Qt 7. Add a note. [ChangeLog][QtCore][Qt::Modifier] The Qt::UNICODE_ACCEL enumerator has been removed. It had no effect since Qt 4.0. [ChangeLog][QtCore][Qt::Modifier] Usage of the enumerators in the Qt::Modifier enumeration is discouraged. The enumeration will likely get removed in the next major version of Qt. Change-Id: If25f30d920878d32903b91a38044f5da042c7eab Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io> Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* Constrain the comparison operators for our container classesLars Knoll2020-07-081-0/+5
| | | | | | | | | | | | This had already been in very few places, where we ran into issues with this before. More generic constraints here will significantly reduce the amount of error messages a user has to parse in case he tries to instantiate an operator by accident (or with a lacking comparison operator for one of it's template arguments). Change-Id: I1521d19c55d99732d9742402bd534c390a8e4242 Reviewed-by: Paul Wicking <paul.wicking@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Add type traits to safely determine the existence of comparison operatorsLars Knoll2020-07-081-0/+114
| | | | | | | | | | | | | | | | | | Containers often define an operator==() or operator<() which is very useful for generic code. But those operators can usually not be instantiated if the template argument doesn't implement the operator. This sometimes leads to the compiler trying all possible template expansions and implicit conversions for the type, giving extremely long error messages. The traits support can be used to safely constrain those operators. Being able to safely detect this will also allow us to fold the comparison support that is currently a large cludge for user types directly into QMetaType. Change-Id: Ib84afb5348c3eb0be5161d6ba9d5fe237709c65f Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Introduce QByteArrayViewSona Kurazyan2020-07-081-2/+0
| | | | | | | | | | | | | | | | | | | | Created a QByteArrayView in symmetry with QStringView. Added the basic tests symmetrical to QStringView tests. Moved the implementations of non-modifying methods of QByteArray to namespace QtPrivate, to be reused inline from both QByteArray and QByteArrayView. Changed QByteArray's counterparts of those methods to take QByteArrayView as argument instead of QByteArray. Removed QByteArray's operator QNoImplicitBoolCast(), because it was causing ambiguity when calling those methods with QByteArray argument (it was there to perevnt if(!ba)/if(ba) from compiling, but currently that would be ambiguous and won't compile anyway). [ChangeLog][QtCore][QByteArrayView] New class. Task-number: QTBUG-84321 Change-Id: I05f92e654cf65c95f2bb31b9c9018746ac110426 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Rewrite AA_MacDontSwapCtrlAndMeta documentationTor Arne Vestbø2020-07-071-7/+18
| | | | | Change-Id: Ifc41d0d341aed029e89baa3fc20f9535c1fb01d9 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Clarify warning message about PIC/PIEDaniel Kahn Gillmor2020-07-071-1/+1
| | | | | | | | | | | | As noted in discussion at https://dev.gnupg.org/T4982#135524, when there is a mismatch between position-independence of the Qt library and other compilations, the warning produced by Qt is confusing. It should say explicitly that -fPIE should not be passed. Change-Id: I66394f86230a6598ac383bfd7bb14ab8cbbf6245 Pick-to: 5.15 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Introduce platform API abstraction for QOpenGLContextTor Arne Vestbø2020-07-021-0/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The API is available by including qopenglcontext.h as usual, but scoped in the QPlatformInterface namespace. The namespace exposes platform specific type-safe interfaces that provide: a) Factory functions for adopting native contexts, e.g. QCocoaGLContext::fromNative(nsContext, shareContext); b) Access to underlying native handles, e.g. openGLContext->platformInterface<QCocoaGLContext>->nativeContext() c) Platform specific functionality, e.g. static QWGLContext::openGLModuleHandle() openGLContext->platformInterface<QEGLContext>->doSomething(); The platform interfaces live close to the classes they extend, removing the need for complex indirection and plumbing, and avoids kitchen-sink modules and APIs such as the extras modules, QPlatformFunctions, or QPlatformNativeInterface. In the case of QOpenGLContext these platform APIs are backed by the platform plugin, so dynamic_cast is used to ensure the platform plugin supports the requested interface, but this is and implementation detail. The interface APIs are agnostic to where the implementation lives, while still being available to the user as part of the APIs they extend/augment. The documentation will be restored when the dust settles. Task-number: QTBUG-80233 Change-Id: Iac612403383991c4b24064332542a6e4bcbb3293 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* CMake: Hard-code QT_CONFIGURE_CROSSBUILD to 0Joerg Bornemann2020-07-011-0/+1
| | | | | | | | The qmake we're building is always built for the target platform. Therefore, QT_CONFIGURE_CROSSBUILD can always be set to a falsy value. Change-Id: I0f03c4ce0c75d3b4e97be5141adf742276131dcb Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Fix warning about missing QT_BEGIN_NAMESPACE in qsimd.hTor Arne Vestbø2020-06-301-0/+3
| | | | | Change-Id: I80d5ec671b08e74856b27922b10e0b31007a62c2 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Use QList instead of QVector in corelib docsJarek Kobus2020-06-291-1/+1
| | | | | | | Task-number: QTBUG-84469 Task-number: QTBUG-85221 Change-Id: Ieb0ba7d82409e3c053a5788a01e92ea495505643 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Use QList instead of QVector in corelib implementationJarek Kobus2020-06-293-4/+3
| | | | | | | | Omitting state machine and docs for now. Task-number: QTBUG-84469 Change-Id: Ibfa5e7035515773461f6cdbff35299315ef65737 Reviewed-by: Sona Kurazyan <sona.kurazyan@qt.io>
* Remove some long-deprecated methods of QLibraryInfoEdward Welbourne2020-06-292-52/+0
| | | | | | Change-Id: If5e85f813921b44971ca8572858051b53e1127a8 Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Sune Vuorela <sune@vuorela.dk>
* Use QList instead of QVector in corelibJarek Kobus2020-06-251-1/+0
| | | | | | | | | | Applied to headers only. Source file to be changed separately. Omitted statemachine for now to avoid conflicts. Omitted qmetatype.h for now - to be handled later. Task-number: QTBUG-84469 Change-Id: I317376037a62467c313467d92955ad0b7473aa97 Reviewed-by: Sona Kurazyan <sona.kurazyan@qt.io>
* Improve castingAllan Sandfeld Jensen2020-06-251-5/+5
| | | | | | | Make a handful of narrowing casts explicit Change-Id: I318e9778840f2437963377b6b97f269d569909dc Reviewed-by: Sona Kurazyan <sona.kurazyan@qt.io>
* Allow qMin, qMax and qBound for types that can be losslessly convertedLars Knoll2020-06-251-0/+43
| | | | | | | | | | | | | | | | Add overloads for qMin and friends where the arguments are of different type, but one can be easily promoted to the other. Return the promoted type. Promotions are only allowed if both types are either signed, unsigned or floating point numbers. This should simplify writing code in many case (as for example qMin(myint64, 1)) and also help reduce source incompatibilities between Qt 5 and Qt 6, where the return types for sizes of our containers changes from int to qsizetype. Change-Id: Ia6bcf16bef0469ea568063e7c32f532da610d1cd Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QString: add char8_t overload of fromUtf8()Marc Mutz2020-06-231-0/+6
| | | | | | | | | | | | | Use the overload-with-template trick from P1423 to avoid ambiguities when existing callers pass 0 or nullptr. Add a qdoc-ignored macro to hide the fact that the overload is a template. [ChangeLog][QtCore][QString] Added char8_t overload of fromUtf8(). Change-Id: Iaa2d365bfa161ef36cc73fa3bad50aabf34d01db Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Move implementation of QVector/List back to qlist.hLars Knoll2020-06-201-1/+1
| | | | | | | | | | | | | And name the main class QList. That's also the one we document. This gives less porting pain for our users, and a lot less churn in our API, as we use QList in Qt 5 in 95% of our API. In addition, it gives more consistent naming with QStringList and QByteArrayList and disambiguates QList vs QVector(2|3|4)D. Fixes: QTBUG-84468 Change-Id: I3cba9d1d3179969d8bf9320b31be2230d021d1a9 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Remove deprecated roles BackgroundColorRole and TextColorRoleChristian Ehrlicher2020-06-201-4/+0
| | | | | Change-Id: I2729102d1efa9f3809ec22c29517961800e7dc6d Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Move QTextCodec support out of QtCoreKarsten Heimrich2020-06-201-3/+0
| | | | | | | | | | * Assume UTF-8 on all Unix like systems * Export some functions to be able to compile QTextCodec once moved to Qt5Compat. Task-number: QTBUG-75665 Change-Id: I52ec47a848bc0ba72e9c7689668b1bcc5d736c29 Reviewed-by: Lars Knoll <lars.knoll@qt.io>