This way you can run cmake, go directly into src/widgets
and it will build moc and rcc before QtCore (because they are needed
there) and uic before QtWidgets but not before QtCore because
it's not used there.
Without this it would get stuck creating the mocs since cmake
is not expecting the moc executable to just not be there
Change-Id: Ibcb6057bfab7a4bf823544e8f7bd128ea93d1986
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
CMake's moc file scanning is rather primitive: It will run moc on any
file containing a line that starts with Q_OBJECT (and similar macros).
We have four files in QtBase that contain such a macro at the start
of the line in a qdoc comment. These four files were excluded from
automatic moc handling by cmake, which is not ideal, since this will
silently fail when somebody actually adds a Q_OBJECT macro in code.
This patch introduces a macro Q_OBJECT for qdoc. This macro will be
replaced with Q_OBJECT in the generated documentation. While not nice,
at least a failure to use \Q_OBJECT is noticeable: Moc will warn about
the file.
Change-Id: I829893c1166eee306fe30058d4ea0256affd45ea
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
This is less self-contained than what we have, but significantly speeds
up cmake configure/generate runs.
This patch also warns when a feature is already defined.
Change-Id: I8cab63e208ba98756b47d362a39b462f5ec55e20
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
This simplifies the handling of features a bit as it removes the special
code to store two sets of features in Qt::Core.
Change-Id: I536d41cfc76a02af054e3cfbad6bda50b1e9e49a
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Only import features once
* Move Core specific code into its CMakeLists.txt file
* More consistently use target names like "Core" to
refer to "Qt modules". We tend to require either "Core"
or "QtCore" in places, which I find confusing.
Change-Id: Id54161bc5468412750cb9eb7eeb15de3812e8a09
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
... and fix the fallout of this change. It results in more targets being
passed overall (instead of a strange mix of targets and module names),
so this is a good thing(TM).
Change-Id: I1c4326b80e2c6675356587879ec8471ef7249a50
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
CMake comes with a Find module for this, so use it in src/corelib/configure.cmake
Change-Id: I8f4abcb32fb10513d67c3c959310eefaf7b56d3d
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
Add FindSlog2 and use it in src/corelib/configure.cmake.
Change-Id: I7e6a696a49df568a41ed1224228ab608db2dbb0e
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
Improve conditions/enable/disable conditions for iconv related features.
These are detected a bit different from what qmake does, so adapt to that.
Change-Id: I7b3e4baf05dc324507f370d7f651a62f29e42a98
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
Find the PPS library and use the result PPS_FOUND in configure.cmake where
needed.
Change-Id: I08d3ace421278dc0ae5c3128d4234e6bca906c05
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
cmake have not built printsupport yet.
Change-Id: I635b4678bbf0b659750e7f6b842834e084b6f3a5
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
Change-Id: I9bf7d61a65950eafcfe6b3ea9c437e353ff7b2ed
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Store QT_FEATUREs that are not emitted, but do not show them in the UI. Also separate
out the UI (FEATURE_foo) from the internal CMake value (QT_FEATURE_foo). This does
break the overriding of settings, but that did not work well before either. This
will be fixed in follow-up patches.
Remove fallout: xkbcommon_system was now evaluated where it was not before. Remove
it as that is always the case now.
Change-Id: I2d303827a1cc9afeef93ad73285a2043ddaa9766
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
QTimer contains a template member function callOnTimeout(), which accepts
a variable number of arguments. Because it is difficult to document such
a general function, several specific declarations were added under the
guard Q_CLANG_QDOC that represent the typical ways this function is used.
They are easier to document because they have specific signatures.
Unfortunately, the clang parser recognizes two of them as being the same,
so this change removes one of the two. It also adjusts the documentation
of the remaining one so that it indicates both uses.
Change-Id: Ifa7bed9093bd1491b7bfe154990864454885c003
Reviewed-by: Martin Smith <martin.smith@qt.io>
This change simplifies memory management as long as it doesn't requires
manuall calls to qDeleteAll and manual deleting/nulling pointers.
Change-Id: Id0dc563d0b1e74ae33939d90d4b39999020cd7ce
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
POSIX specifies that tzset() consults environment variable TZ and
modifies some globals; it also specifies mktime(), localtime() and
strftime() to behave as if they called tzset(). Fortunately, we only
call strftime() from a test and only call localtime() when not
threaded. Provide wrappers for tzset() and mktime() that share the
lock used by our environment-access code, to prevent races on the
environment (and tzset()'s globals) when we call them.
In the process, re-use tst_QDateTime's TimeZoneRollback in its older
test systemTimeZoneChange() and presume that this can now be tested
cross-platform, since TimeZoneRollback is used in another test where
this works.
Fixes: QTBUG-71030
Change-Id: I79f559b8857ea2803e73501008bf0d7158c6731f
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
QWidget::isEnabledToTLW() and QApplication::setKeypadNavigationEnabled()
are deprecated for a long time but not marked as deprecated. Therefore
add QT_DEPRECATED and guard them with QT_DEPRECATED_SINCE(5, 13).
Change-Id: I12a76597aaad71025e4b7ad251dd67be55f8f966
Reviewed-by: Samuel Gaist <samuel.gaist@idiap.ch>
Mark some long deprecated functions as deprecated so they can be removed
with Qt6.
Change-Id: I2ccd21c829c954b6a3662799070682dbe71fd693
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Reviewed-by: Luca Beldi <v.ronin@yahoo.it>
This is not valid, but was confusing before and would be silently ignored,
warn instead.
Fixes: QTBUG-50583
Change-Id: If78c4a5ef96c76e1d5116a1bd24e5c289ff74cc4
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
The hue parameter in hsl/hsv was treated the same way as a the other
parameters although it's range is from 0-359 and not from 0-255.
Fix it by extending the maximum range for the first parameter when
parsing a color value given in hsv or hsl.
[ChangeLog][QtGui][CSS] Fix the range of the hue parameter when parsing
a color given in hsl or hsv
Fixes: QTBUG-70897
Change-Id: I9ffa65a89c0abcca62bae35777ca1cbde3375180
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
The Qt stylesheets color property did not support hsl or hsla although
CSS 2.1 does support it. Since QColor natively supports this color model
only the color parsing needed to be adjusted.
This also adds some stricter checks for a valid css color definition and
prints a warning about the issue.
[ChangeLog][QtGui][CSS] Added support for hsl/hsla colors
Fixes: QTBUG-58804
Change-Id: Ief65a36a7e0ed0d705dc1fe5a8658e8d07fe9a13
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Only QGuiApplication would emit the signal. Untangling the duplicate
code is rather non-trivial, so left alone for now.
Fixes: QTBUG-71186
Change-Id: I4021e3b9ff39718562f4fa3a03c092436b559e9a
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
A few member functions of QCborValue and QCborValueRef were given special
declarations for qdoc to see so that they could be documented as a single
function, but because clang is now used to parse c++, the special declarations
caused parsing errors.
The declarations for qdoc are removed in this update, but the functions are
still documented with a single comment by grouping the \fn commands for the
similar functions together in the single comment.
Change-Id: If97ee2f2bfcd045d2259a4375b31b8884eeb1072
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
Reviewed-by: Martin Smith <martin.smith@qt.io>
Use unique_ptr instead of plain array. No need to call 'delete'.
Change-Id: Ia77f4f209b1fd83391428d8b82b7acbba48781b9
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
This doesn't add any value and just complicates things.
Change-Id: I3a011174e330f212eda99371d2806517ceec45d7
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
It's needed to generate a pkcs12/pfx bundle from our
certificate chains which are then imported into a certificate
store in Schannel and then passed to various Schannel API.
Change-Id: Idb88f42f2aa15eb91c52404ee6c57bf43e983379
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
toolBarArea took non-const even though const would have been enough.
In the public API do this for Qt 6.
Fixes: QTBUG-45953
Change-Id: Ic99f4dd5a7f344d49d046e3b084b68120f8de3c0
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>