Future versions of emscripten will remove the timestamp, so we need to
replace this with the current timestamp
See a7f058a1e6 (diff-9a5d68085dc7db2938b37a2b7b05c1f5)
Change-Id: Ieba323ad54933626d90ac7cbae5a2c471c52628e
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
In the presence of multiple overloads of a function taking either
QString or QStringView, QStringView should always be preferred.
The rationale is that the QStringView overload may have been
added "later" (read: the function was written when QStringView
was not available yet, so it took QString), and the fact that
a function with the _same name_ offers a QStringView overload
implies the function never needed to store/own the string in
the first place.
Add a (compile-time) test for this preference. This is in
preparation for a future QString(char16_t*) constructor
(in Qt 5.15 / Qt 6).
Change-Id: I60a435e494b653548f8f8d52c5d7e7cac2cc875a
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
'QTypedArrayData<T>::iterator QVector<T>::insert(int,QItemSelectionRange &&)': cannot convert argument 1 from 'QTypedArrayData<T>::iterator' to 'int'
'bool QVector<QItemSelectionRange>::isValidIterator(QTypedArrayData<T>::const_iterator) const': cannot convert argument 1 from 'QTypedArrayData<T>::iterator' to 'QTypedArrayData<T>::const_iterator'
Change-Id: Id43ca5a9cd7b5709d47515ffdab3896feb298087
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Properly scale size hints to the new scaling factor.
Fixes: QTBUG-80476
Change-Id: I1081c9b01560f7e434f0f1de0199ef3d3cae787c
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
QApplication tries to close all windows on quit using closeAllWindows,
but closeAllWindows skips some windows, in particular any widget with
WA_DontShowOnScreen set.
QApplication then tries to verify that all windows have been closed,
and that logic should skip the same kind of windows as closeAllWindows
does.
We include WA_DontShowOnScreen so that widgets that are proxied via
QGraphicProxyWidget will not prevent the application from quitting.
There's still some divergence between closeAllWindows and the logic
in QApplication::event's quit handling, but aligning that requires
more work than this particular fix, and should probably also be
based on using the return value of tryCloseAllWindows() directly.
Change-Id: I2555eeee0cb04b8e736109fed57f37150efd1964
Fixes: QTBUG-81107
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
Change the default rounding policy to "Round" so that 2 is used
for 150% (144DPI) on Windows, as it was in 5.13.
Fixes: QTBUG-80934
Change-Id: I0cba986ce6afc9e2737c656000ad854c07844360
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
Previously, there was only a Python compile test which triggers
only when PySide2 is found. Rename it to pythonCompile().
Extend the TestEntry structure by adding the base line file
and flags, which represent all special cases found in the code.
Check for the presence of a Python base line file in addition
to the C++ one.
Prototypically add one form. Further forms can be added
on the go.
Task-number: PYSIDE-797
Change-Id: Ic2983fa3cab2399a6809e244f93c663e0212f675
Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
Add missing call to QHighDpi::fromNativePixels(), retrieving
the screen from the menu.
Task-number: QTBUG-79248
Change-Id: I9f358c8010615c3f96ed9dc3b6666013ae9a0ed9
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
As long as we do a multi abi build in one go there is no easy way for us to know
where the ssl libs are located for each ABI. The easiest way is to use libs
prefixed with the ABI.
For configure set we are using "_arm64-v8a" prefix as the configure script will
always use arm64-v8a to run the tests.
Don't show the OPENSSL_LIBS example as it won't work on Android.
Here https://github.com/KDAB/android_openssl/commit/ebb0b68be4 you can find
a script which builds these libs.
Fixes: QTBUG-80862
Change-Id: I019c2a208ae48a7356b8f3933d0f4aad5ac156a3
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
De-duplicate the code that calls the extra compiler's depend_command by
using the central function callExtraCompilerDependCommand. This one
actually tries to resolve dependencies unlike the removed code that
blindly resolved relative paths to the build directory.
This fixes dependencies reported by uic which need to be resolved
against what is in DEPENDPATH.
Fixes: QTBUG-80579
Change-Id: If482e50ff3eff716fefffee82004acc076b3a547
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
This reverts commit c17a5cec19.
The patch introduced a call to View.getRootViewInsets() which
was introduced in API level 23. We don't want to change the
minimum level for Qt 5.x series now, so we will revert the
change in 5.15 and reintroduce it in Qt 6, simultaneously
setting the minimum API level to 23.
Task-number: QTBUG-74202
Change-Id: Ia25bb2cd62287aa80a43bbd294fb757f3f79ff5e
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
Change e453222414 tried to map global
position directly from the desktop to the window that should receive
the event. That's fine for single-window applications; but media
players like OBS and VLC often use embedded windows to play video.
So the mapping needs to traverse the window parent hierarchy somehow.
In this patch it's done by calling QWindow::mapFromGlobal(), but that
only works with integer coordinates (QPoint). To preserve the fix
for QTBUG-48151 (and other jitter bugs), we need sub-pixel accuracy;
so we have to add back the fractional part after mapping the int part.
Fixes: QTBUG-77826
Change-Id: Ib52ce14138e477182e0ef53b0ff30ce1eff40372
Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
...not the connector. Passing the connector id to drmModeGetEncoder()
is clearly an oversight.
Task-number: QTBUG-80976
Change-Id: I80a6088fca558d1637bd01b0aca8c4a8ba3b25f5
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
Deprecated the SAX classes and disabled or replaced their uses in
tests if applicable.
Removed the saxbookmarks example, no point in keeping examples for
the deprecated code.
[ChangeLog][QtXml] SAX classes are now deprecated. Use QXmlStreamReader,
QXmlStreamWriter in QtCore instead.
Task-number: QTBUG-76177
Change-Id: Ic171d62fa0527b0f36f94cf09a69586092269957
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
QT_VULKAN_INSTANCE_EXTENSIONS to specify additional
instance extensions.
QT_VULKAN_INSTANCE_LAYERS to specify additional
instance layers.
QT_VULKAN_DEVICE_EXTENSIONS to specify additional
device extensions.
These will apply to all QVulkanWindows and everything
that uses RHI, including Qt Quick with the Vulkan RHI
backend.
Task-number: QTBUG-80499
Change-Id: I912495affa987d62a9823d55d06d6a8209f6adc6
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
qmake itself does not use the variable, but Qt Creator does.
Fixes: QTBUG-77866
Change-Id: I313d1ebe32dbc1eeac8d2d79b519349c7097a5a6
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Commit 4d289edb14 did disable debug-and-release
for MinGW completely. While it makes sense to change the
default, we should allow people to opt-in to old behavior
by explicitly setting '-debug-and-release'.
To allow differentiation between debug and release libraries
debug dll's (again) have a 'd' suffix.
Fixes: QTBUG-80792
Change-Id: I341b1a94788f490e975be6736159980cd9273f08
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Qt 5.14.0 switched the default from -debug-and-release
to -debug only. Change this to -release, like on the
other platforms.
[ChangeLog][MinGW] Qt will by default be built in release
mode. Use -debug-or-release to force the pre 5.14.0
default.
Change-Id: I020268d0672c80cdc0259068c6dc2c743a794237
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
When scanning the prl files to set up usage requirements for the Qt libraries
we omitted "-framework Foo" flags. Those were passed as linker flags, but not
as interface libraries. Consequently, the frameworks that are used by Qt
libraries were missing on the link line when building against a statically
built Qt.
Fix this issue by scanning the dependencies for "-framework Foo" just like we
do with "-lfoo" flags.
Fixes: QTBUG-80855
Change-Id: Ie7804304141c86207d143a6e1005e78bdc099113
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
Reviewed-by: Kyle Edwards <kyle.edwards@kitware.com>
They don't store the strings.
[ChangeLog][QtCore][QRegularExpression] The escape(),
wildcardToRegularExpression() and anchoredPattern() functions
now have overloads taking a QStringView parameter.
Change-Id: Icc66ba1201ef1f1064d9565900439e78912b675c
Reviewed-by: Samuel Gaist <samuel.gaist@idiap.ch>
This amends a1f4321bbb as the font
families should take precedence over the font family set. If the font
family is already included in the families then it should keep its
placement. Otherwise it should be appended.
Task-number: QTBUG-80475
Change-Id: I0049189c88b6879e57619815ec780960e9c0a300
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
- qeasingcurve.cpp: Add a cast, fixing:
qeasingcurve.cpp(1515,25): error: implicit conversion between pointer-to-function and pointer-to-object is a Microsoft extension [-Werror,-Wmicrosoft-cast]
- Disable copy and move of QMainWindowLayoutSeparatorHelper, fixing:
qbasictimer.h(59,5): note: 'QBasicTimer' has been explicitly marked deprecated here
QT_DEPRECATED_X("copy-construction is unsupported; use move-construction instead")
Task-number: QTBUG-63512
Change-Id: I4d12a29cb1dcd68da9f9316c9e42992f218e6045
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
Reviewed-by: André de la Rocha <andre.rocha@qt.io>
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
In order for SE_TabBarTabText to correctly calculate the space available
for the text it needs to get the rectangle of the tab directly instead
of relying on the option's rectangle as this may have been modified
before this point. Therefore we introduce QStyleOptionTabV4 to be able
to store the index as part of the option so it can be queried directly.
[ChangeLog][QtWidgets] Added QStyleOptionTabV4 as a subclass of
QStyleOptionTab so that the tab's index information can be obtained.
Fixes: QTBUG-50637
Change-Id: If705f5069fdd14eeccf06bc63dba4e8d2e704359
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
The two methods have been marked obsolete for a very long time,
setAlphaChannel() is still convenient though, so this patch
modernizes it and removes obsolete from the API, while marking
QImage::alphaChannel() as deprecated. They don't work as getter
and setter anyway, since setAlphaChannel() actually does an
alpha composition.
Change-Id: I634d6463f78c42bb9c5fa3df17500ec01bfcac33
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
The newly optimized rgbBlend function wasn't updated to handle
SourceOver compositing when dealing with semi-transparent text color.
The extra composition isn't SIMD optimized but short-cut for all opaque
colors.
Fixes: QTBUG-80982
Change-Id: I88c1e60fd5e80a8c7f9e6b0e7de8248c7c00ebc2
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
When the dropdown button of a combobox is drawn with QStyleSheetStyle,
not only the background color is used for drawing but also
QPalette::Light/Dark/Shadow. Since the palette was not properly set up
in some cases, the shaded frame around the button was drawn with the
default colors instead the ones derived from the given background.
Therefore we have to properly set up the palette before drawing the drop
down button by calling QRenderRule::configurePalette()
Fixes: QTBUG-80950
Change-Id: Ibf98fa28612b5c7527ef9dd6ae06c417315f2632
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Under some circumstances it's possible that firstVisibleBlock() returns
an invalid block within QPlainTextEditPrivate::_q_textChanged() which
results in a nullptr access later on.
Therefore add a check similar to other places and test the validity of
the returned block before accessing it.
Fixes: QTBUG-80929
Change-Id: I1fd4643b10b842acfe1c356048379f0ba225dddf
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Conflicts:
src/corelib/tools/qvector.h
Make QVector(DataPointer dd) public to be able to properly merge
5b4b437b30 from 5.15 into dev.
src/widgets/kernel/qapplication.cpp
tests/auto/tools/moc/allmocs_baseline_in.json
Done-With: Christian Ehrlicher <ch.ehrlicher@gmx.de>
Change-Id: I929ba7c036d570382d0454c2c75f6f0d96ddbc01
Just print the hex value of the format.
Task-number: QTBUG-74409
Change-Id: I0441eda050735325f7686532b17ef765f71bec9b
Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
oss-fuzz sets the environment variable LIB_FUZZING_ENGINE
to link with AFL or libFuzzer. If this variable is not set,
libFuzzer will be used as before, only that the right qmake
variable will be used for doing so.
Change-Id: If9fe7739a8d2d4a76f4633a75cad3d2e935f3b61
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Reviewed-by: Albert Astals Cid <albert.astals.cid@kdab.com>
The Python-bases pyside2-uic would write an import for each
resource file encountered, adding a "_rc" suffix. Add this
handling.
Task-number: PYSIDE-1171
Task-number: PYSIDE-1170
Change-Id: I870d61ca7262c0684de5359a5f990d23a4171032
Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
Add some casts, fixing warnings like:
src/corelib/text/qbytearray.h(490): warning C4267: 'initializing': conversion from 'size_t' to 'int', possible loss of data
src/corelib/text/qstring.h(1045): warning C4267: 'initializing': conversion from 'size_t' to 'int', possible loss of data
src/corelib/tools/qarraydatapointer.h(80): warning C4267: 'initializing': conversion from 'size_t' to 'int', possible loss of data
src/corelib/tools/qarraydatapointer.h(75): warning C4267: 'initializing': conversion from 'size_t' to 'int', possible loss of data
src/corelib/text/qbytearray.h(490): warning C4267: 'initializing': conversion from 'size_t' to 'int', possible loss of data
Change-Id: I221db4d5b660224f0fc1869248802c496db1b91c
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
src/corelib/serialization/qjsonvalue.cpp:174: (qdoc) warning: No such parameter 'n' in QJsonValue::QJsonValue()
...
examples/widgets/doc/src/icons.qdoc:584: (qdoc) warning: Command '\snippet (//! [24])' failed at end of file 'widgets/icons/mainwindow.cpp'
src/corelib/text/qbytearray.cpp:5177: (qdoc) warning: clang found diagnostics parsing \fn QByteArray::FromBase64Result::operator QByteArray() const
error: out-of-line definition of 'operator QByteArray' does not match any declaration in 'QByteArray::FromBase64Result'
src/corelib/serialization/qjsonarray.cpp:178: (qdoc) warning: Overrides a previous doc
src/corelib/serialization/qjsonarray.cpp:140: (qdoc) warning: (The previous doc is here)
src/corelib/serialization/qjsonobject.cpp:1016: (qdoc) warning: clang found diagnostics parsing \fn QJsonValueRef QJsonObject::iterator::operator[](int j) const
error: out-of-line definition of 'operator[]' does not match any declaration in 'QJsonObject::iterator'
src/corelib/serialization/qjsonobject.cpp:1267: (qdoc) warning: clang found diagnostics parsing \fn QJsonValue QJsonObject::const_iterator::operator[](int j) const
error: out-of-line definition of 'operator[]' does not match any declaration in 'QJsonObject::const_iterator'
src/corelib/tools/qhash.cpp:2641: (qdoc) warning: Overrides a previous doc
src/corelib/tools/qhash.cpp:1492: (qdoc) warning: (The previous doc is here)
src/corelib/tools/qhash.cpp:2659: (qdoc) warning: Can't link to 'unit()'
src/corelib/text/qchar.cpp:274: (qdoc) warning: Undocumented enum item 'Script_Sundanese' in QChar::Script
src/corelib/text/qchar.cpp:274: (qdoc) warning: No such enum item 'Script_Sundaneseo' in QChar::Script
src/network/ssl/qsslsocket.cpp:1514: (qdoc) warning: Can't link to 'QSslConfiguration::addDefaultCaCertificate()'
src/widgets/widgets/qtabwidget.cpp:581: (qdoc) warning: Undocumented parameter 'visible' in QTabWidget::setTabVisible()
Change-Id: I05c2a4884873850b684fa94036cd90db1a6e7726
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
It used to be "iterator", causing a qdoc warning:
src/corelib/serialization/qjsonobject.cpp:1405: (qdoc) warning: clang found diagnostics parsing \fn int QJsonObject::const_iterator::operator-(const_iterator other) const
error: out-of-line definition of 'operator-' does not match any declaration in 'QJsonObject::const_iterator'
Add a small test.
Change-Id: Id65effffa720ed1e0fb0ee6937dcc4298f3ef363
Reviewed-by: Lars Knoll <lars.knoll@qt.io>