When using a style that wants to draw into the layout's margin (like
macOS style does with group box titles), parts of the widgets would be
clipped by the parent if the available margin is smaller than necessary.
This moves the x/y coordinates to at least 0/0, and adjusts width and
height accordingly.
[ChangeLog][QtWidgets][QLayout] Prevent clipping of group box titles
on macOS (and similar styles that draw into layout margins)
Change-Id: I32148a92858c13fb2325da4d0a2a58996e0e8930
Fixes: QTBUG-67608
Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
Enabling makes QtQuick to attempt to access window.devicePixelRatio
[via QWasmWindow::devicePixelRatio()] from a web worker.
Change-Id: I957df29060c7eb8c47d02bc67c8c5c2219b570f4
Reviewed-by: Lorn Potter <lorn.potter@gmail.com>
[ChangeLog][QtCore] Added support of deduction guides for QPair
Change-Id: I41a798390dc2c925b0f8432ba12aa345724de2d7
Reviewed-by: Martin Smith <martin.smith@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Ville Voutilainen <ville.voutilainen@qt.io>
QKeyEvent instance requires Qt::Key but currently X11 keysym is assigned
and the IBus QT module forwards the wrong key events.
Now QXkbCommon::keysymToQtKey() can generate Qt::Key from keysym and
forward the correct key events.
Change-Id: I25f0a9e9319b4a5f42847f8592ad3a30f6c9349d
Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
... because API from qxkbcommon_p.h includes xkbcommon headers.
When we use "QT += xkbcommon_support-private" in *.pro files, we
should not explicitly require "QMAKE_USE += xkbcommon" in those
projects.
Change-Id: I21049034ce93bee13a1107723f26498c221f8ea4
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Add a field remembering the tab position of the dock widget area to
QDockWidgetPrivate and use that when grouping floating docks.
Fixes: QTBUG-74242
Change-Id: I2a453080cb39dd4a5491976f1aeca70ae681682a
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
This document is bound to run out of sync with reality. Actually there are
changes from Qt4.x missing. The streaming operators of the classes contain
many if-then-else cases, making it difficult to represented in a plain text.
With only a partial definition of the protocol, this document is useless to
users, because they should not care how the actual protocol is implemented.
Fixes: QTBUG-73386
Change-Id: I7fc4066ef8186d54dfd48445452c1a6d8bf371c3
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
They are the only Qt symbols neither prefixed with q or with the Qt
namespace. This changes preserves source and binary compatibility
while making it possible to define conflicting symbols.
Change-Id: I6d4181206e63faa922fa0c8b644e0a4b88826a97
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
The test is flaky which was uncovered by the upcoming
QTimer::singleShot optimization patches:
When the Emitter's thread is started and executes the timout functor
before the state machine is started, then the state machine will never
see the emitSignalWithNoArg signal and thus never transition to the
final state and finish.
This patch ensures that the code in the background thread is only run
after the state machine was started to fix this flakyness.
Change-Id: I6f91a2420165662ece75e550a6d73fe098137d4c
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
Reviewed-by: Kari Oikarinen <kari.oikarinen@qt.io>
The logic for removing QScreens from QGuiApplicationPrivate has been
moved into the QScreen destructor, similar to QWindow.
Change-Id: I18ad57d8dcf9f765c47be7c082bf075af3ebe69c
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
LRESULT on Windows 64 is a 64bit type, adapt filter functions of
QAbstractNativeEventFilter and QAbstractEventDispatcher accordingly.
Fixes: QTBUG-72968
Change-Id: Ie53193e355f0b8e9bd59fa377f43e2b4664a2ded
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Initially TESTSERVER_COMPOSE_FILE could be manually specified.
Later this got removed by accident. Re-enable this feature.
Furthermore, check if a module has a platform-specific compose file. If
not, fall back to a default docker-compose.yml. This is useful to
include testserver.pri from other modules, where no platform-specific
requirements are present, ie the image from provisioning works on all
platforms.
Change-Id: Icb92552fd61196be332b2431ab0f8a43b9157fc8
Reviewed-by: Ryan Chu <ryan.chu@qt.io>
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
When checking whether a slot is connected to a signal, we need to
hold the signalSlotLock to be sure about the answer, or we can
get crashes when a connection gets removed while doing the check.
The check in activate() can handle some uncertainty as it's only
a shortcut to the longer path.
Fixes: QTBUG-74604
Change-Id: I3fc822455fbadc0223ef68632f5fb3df3ff3e86d
Reviewed-by: Aapo Keskimolo <aapo.keskimolo@qt.io>
[ChangeLog][QtCore][QVariant] Fixed a bug that caused isNull() to be
true after downcasting a QObject* payload using convert().
Fixes: QTBUG-73196
Change-Id: Ifda15952f873d7142c95609b69ac424bbf16b723
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
In release mode, MSVC linker will enable it by default
while clang-cl won't. So enable it explicitly.
Change-Id: Iabfd8698d426290fee59662acf6c124b9f226c11
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Do remove quotes around libraries before trying to parse them.
This patch is a follow-up to eda28621f6, and fixes
an issue on Windows where e.g. Qt5AxServer.prl contains entries
like
"-lole32"
Fixes: QTBUG-73475
Change-Id: I3d1353de618328a0d44bacd4dbd6aba8fc66b1b7
Reviewed-by: Kyle Edwards <kyle.edwards@kitware.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
QDialog::setOrientation/setExtension() was marked as deprecated without
a suggestion on how to replace those functions. Therefore add a
suggestion (taken from the documentation) now.
Change-Id: I13b2af2264064ca1c7c034cf6b920caaadcee113
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
Subjective, but for me its easier to follow code flow if
indentation is not interrupted.
Change-Id: If811ba1b975189c94a671627be8eb3a1fd67aeb9
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Sometimes the XVisual for an FBConfig have no alpha data, and thus
won't work when an alpha channel is required.
Fixes: QTBUG-74578
Change-Id: Idf05cbfcaea5edf667035939e9bc5d5df2172eec
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
To get appropriate aspect ratios for the splash screen, you usually
need separate drawables for the portrait and landscape versions.
We support this by adding two new meta data entries that can be used.
If they are not available, we will fall back to the generic one,
so we are still compatible with existing AndroidManifest.xmls.
[ChangeLog][Android] Added entries in the AndroidManifest.xml for
specific portrait and landscape splash screens. If one is present
for the current orientation, it will be preferred over the generic
one.
Task-number: QTBUG-74029
Change-Id: I5ffea56320aef85f62f21a59df4d077b4163a65a
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
When painting into a pixmap, we would apply the system clip,
which is a rectangle that starts at the position of the current
widget relative to the window. If the widget was not positioned
at (0,0), we would therefore clip the top left part of the drawing
when drawing into a pixmap, which is obviously not intentional.
The solution is in accordance with how it is done in e.g. the OpenGL
paint engine, where useSystemClip is set to true only if we are
drawing to a widget. The system clip should otherwise be ignored,
so we do that in the X11 paint engine as well.
Task-number: QTBUG-70387
Change-Id: I9cad26019970280a8a452dc6f1015d229120cac5
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
QIcon::paint() paints blurry icons on HighDPI screens.
In particular, it is called by QCommonStyle to paint
icons for CE_ItemViewItem's.
Change-Id: Iffe6bd01a8756e617656195ef63fe13c968e0832
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
The patch causes an Assert on close and thus cannot be used as is. I do
not have ICC available to try to come up with an alternative solution so
the patch is reverted for the time being.
This reverts commit 93a78799c3.
Fixes: QTBUG-74467
Change-Id: Ic572dfa667a479686675eb3f9066d133657b4499
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Yuhang Zhao <2546789017@qq.com>
Copy the test data into a temporary directory and do all the work there
without tainting the source directory. More importantly, do not pull in
any settings from the Qt build to test what actual users will encounter.
Change-Id: I793b86bfadb7597efb47c8f2d3fc863384c78a79
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
This will enable modules like QtWebView which needs to generate its
qmldir at qmake time since it changes depending on whether QtWebEngine
is available or not. This ensures that it is not created in the sources
directory and in the build directory and correctly picked up.
Task-number: QTBUG-65092
Change-Id: Iac628b97145d29778f554510e8e07102d588df64
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Fonts look ugly when they are drawn scaled without
antialiasing.
Change-Id: I64268db5b37d4bc763ffa23632aca2eaac5d8eae
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
INTEGRITY compiler searches for exact filename if the -l argument already
contains .a suffix. GNU linker uses exact filename if -l argument begins
with a colon.
Change-Id: I62be8f1e6b9c7dc7eaa5ab3d4bfc55460d729737
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@gmx.de>
Compilation breaks on Windows and macOS hosts with USE_ZLIB=1.
In addition, it turns out that the versions of the libraries in
Emscripten Ports are outdated. Since we have newer versions
of these libraries in Qt already, we will just use those.
This is a revert of 70b558ad5b.
Task-number: QTQAINFRA-2835
Change-Id: Ic2642b7d319a3447fd08843657eb0535255e0449
Reviewed-by: Lorn Potter <lorn.potter@gmail.com>
Destroying windows happens independently of closing them, e.g. when
a window is moved from one screen to another non-sibling screen.
The logic for quitting the application should apply to the actual
closing of a window, as documented.
Change-Id: I2226aff29278aa6fbf054a0994a320eb53196e9e
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
A QCOMPARE(..., true) isn't much use; and failure would have set the
object's .errorString(), which seems like it'd be worth reporting, so
use QVERIFY2() instead.
Change-Id: I2f3f9379984694891de81d2ffebc696d91eec70f
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
The rules of std don't permit us to add an overload for
fpclassify(qfloat16), so we need our own equivalent that we *can*
overload. Deploy it in the few places we use fpclassify().
Extended qnumeric's testing to cover qFpClassify().
Change-Id: Ie5a0a5cc24599d1571404c573d33c682b0d305a5
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
Renamed the test, since it covers both, verified slightly more and
added checks that QCOMPARE() copes as intended. Fixed some minor
coding-style defects in the process.
Change-Id: I49c2ffa0568a29e9e4b7f7395d4cacdeb0401da0
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This scans the public suffix list and emits suitable content for the
header. Made some modest efficiency gains while hopefully making the
code easier to understand. Check for success when opening files.
Change-Id: If6b25c5c85f86209b33d9188743e820690e7dc05
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
As - cannot be used in a function name but can still be used as part of
the TARGET, then we need to make sure that it is replaced to avoid a
compile problem.
Change-Id: I0b2e465310206e2522ce59235b1592517817d3e2
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>