[ChangeLog][Platform Specific Changes][Linux] Added a device spec for
Raspberry Pi 4 (32-bit, V3D)
Change-Id: Idea889842a89dcc74705f1bb9559953dadc07251
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
Switches the text blending to be SourceOver as that is
much more common than Source, and means we can now handle
semi-transparent text colors there.
Task-number: QTBUG-72165
Change-Id: I7b3aedb22412e6fb6f60197596b37f26c6008784
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
QQuickMultiPointTouchArea needs to understand whether a stationary
touchpoint has relevant property changes, to decide whether to emit its
updated() signal. Amends 217dd1b3b0
Task-number: QTBUG-77142
Change-Id: I85e031820bef9d687369b7d67a57c67fe2875b4b
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
In 5bb178c479, the Android platform plugin was moved from
platforms/android to platforms/. The unforeseen consequence of this was that the plugin
loader for plugins/platforms would now find it, whereas before it would be ignored. It
would therefore be detected as the appropriate plugin, but since it was intended to be
loaded as a static plugin, loading it dynamically would fail.
Instead of fixing the static plugin loading, we remove this hack.
Fixes: QTBUG-78440
Change-Id: Idcb6c075fdebaf67644f32a59d7aaf0d1c0bbe20
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
Cleanup QTreeView autotest:
- use range-based for loops
- use nullptr
- use member initialization
- use new signal/slot syntax
- use static invocations / replace with QTRY_foo() calls
- use override
- use QStyledItemDelegate
Change-Id: I0e2d023254ed9f6f5d94cebf4d4358351cc4c3e2
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Set the variables within the condition introduced by
6c0e1dba40, as otherwise, the code
might not be executed.
Task-number: QTBUG-78300
Change-Id: Ia83db6fce197ebf16783f3b0c6d6fad7ebd2ba52
Reviewed-by: André de la Rocha <andre.rocha@qt.io>
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
Cleanup QTreeWidget autotest:
- use range-based for loops
- use nullptr
- use member initialization
- use new signal/slot syntax
- use static invocations
- use override
Change-Id: I2c07e95871d8725366cddd5cd098010709c8dc55
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
This reverts commit 319c478603.
Reason for revert: QTBUG-78450
Change-Id: Ifaea83626296508558591d4ff207d4e0c883f841
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
screen() may return a null QScreen pointer during
screen initialization.
Fixes: QTBUG-78118
Change-Id: Ide26eb3f06861c38cd7ae56789dd010d4cd7e572
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
Prevent recursive platform window creation from the events
received during window creation (WM_POSCHANGING, etc).
Fixes: QTBUG-78300
Change-Id: Ie2bb4308af645c30e556666589e2dd08f14d4035
Reviewed-by: André de la Rocha <andre.rocha@qt.io>
On systems where the pkg-config source fails, configure falls back to
a library source of the type 'freetype'. This ignored variables like
FREETYPE_LIBS users can pass to configure.
The qtConfLibrary_freetype function now diverts to
qtConfLibrary_inline which handles all those variables.
Change-Id: Icef70deb130ce6d2de1520af4344ccccd677f287
Fixes: QTBUG-77643
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
The variable QMAKE_DEFAULT_INCDIRS was misspelled, which means we
never really looked for freetype in the default paths.
Change-Id: I20c35a783505678169ecb642927f74b339e55b68
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
The styleSheet font cannot know about e.g dpi or other settings
(e.g from the current screen) so we should resolve font settings
from the original font. This patch ensures that the stylesheet
font is resolved with a relevant font before it is used.
This likely fixes many dual/triple screen issues.
[ChangeLog][QtWidgets][QStyle] Style sheets now only
use the part of the stylesheet font that it knows
about. The remaining will be resolved/inherited from
the context.
Fixes: QTBUG-77502
Change-Id: I3b1f821e1be9707506a6c1d1e93f76eeac4007e0
Reviewed-by: Morten Kristensen <me@mortens.dev>
Reviewed-by: David Faure <david.faure@kdab.com>
Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
(cherry picked from commit b68ade8282)
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Do not try to find a screen for native child coordinates.
Fixes: QTBUG-78158
Change-Id: I78ba814929f4db3dfd7dd43c09f7c7642222f4fb
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
The compositor context is not current during the resize()
call, but will be during updateTexture().
Change-Id: I29c2e06aa251b564b5d622dc9380ec994e15aab0
Reviewed-by: Lorn Potter <lorn.potter@gmail.com>
The requirement to separate debug and release DLLs on Windows stems from
the Visual Studio C run-time library appearing in two different variants
(debug and release) and not mixing well. It's possible to perform builds
without optimzations and with debug symbols while linking against the
release version of the C run-time, but at the same time the debug
version of the run-time brings other developer visible advantages.
MinGW on the other hand does not have this distinction, does not ship
with separate DLLS and does also not require the VS C runtime library.
Therefore we do not need this separation for MinGW, which means that our
packages can be reduced in size and application developers wishing to
debug their applications do not have to use debug builds of the Qt
libraries or run into Qt internal debug code.
Task-number: QTBUG-78445
Change-Id: Idf588606091298dc44262c4c89e689df18d34747
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
Commit 80dea664 broke .ui files with global includes that are not part
of the project, because we blindly added every file path that falls
out of 'uic -d' as dependency.
Introduce the extra compiler CONFIG flag dep_existing_only to bring
back the old behavior that ignores non-existent dependencies and set
it for uic.
Change-Id: I6eaa82817c932a98ebac6d08115a9815d4b9dd21
Fixes: QTBUG-78144
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
For nmake and VS projects we added the NDEBUG define for the release
configuration unconditionally within the qmake generators. To undefine
it, users had to use a nasty work-around.
Now, define NDEBUG within the MSVC mkspecs. In order to do that we
introduce the DEFINES_RELEASE and DEFINES_DEBUG variables that are
merged into DEFINES in default_pre.prf.
Users can unset NDEBUG by writing
DEFINES -= NDEBUG
in their .pro file.
Note that DEFINES_RELEASE and DEFINES_DEBUG are merged in
default_pre.prf in order to give extra compilers (like moc) the chance
to see the fully resolved DEFINES variable. This is different from the
QMAKE_CFLAGS_(DEBUG|RELEASE) variables that get merged in default_post.prf.
Fixes: QTBUG-78071
Change-Id: I381770a1d2f974fbae9b09a2254e3f2fc7842b68
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
We must not set QMAKE_INCDIR_VULKAN if the Vulkan SDK is installed in
some default include directory. MinGW's std headers rely on
#include_next, which will break if we mess with the order of default
include paths.
Fixes: QTBUG-76660
Change-Id: I5ee0fc4c328ff88b979a8c1c010472b3883dff8d
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
Change-Id: Iab74325da3bd0a22c1f69856b038d0b5615e4e63
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Change 7d29807296 removed the docs for
the obsolete pos() and globalPos() accessors, but the text should have
been reused to document their replacements.
Change-Id: If4d64e0f07666a99d9a0a4f0de9fca42d3acf0f8
Reviewed-by: Sona Kurazyan <sona.kurazyan@qt.io>
This is to inform Qt Quick when a stationary touchpoint is delivered
that it is because of a changed property. Qt Quick still needs to avoid
delivering item-customized events (with only the touch points that occur
inside the item) that contain only stationary touch points without
changed properties. To be able to check this private flag,
QQuickPointerTouchEvent needs to be a friend.
Task-number: QTBUG-77142
Change-Id: I6ee0dffbbeca9e513c77227b757252e2eec6a4ef
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
In the case when the Qt build is debug_and_release the debug plugin
check should be enabled, otherwise the mixture of Qt debug and Qt
release libraries will cause crashes (e.g. QTBUG-77431)
Task-number: QTBUG-78445
Change-Id: Ice0b03e63ddad893334a0e1a4ede1f6ace83007b
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Those values must be scaled to device coordinates - otherwise borders,
margins etc. will be too small when rendered on high dpi devices
(printers etc.).
This change will add the scaling to those values.
QTextDocument::print applies 2cm margins to the root frame of a
unpaginated QTextDocument. Those margins were previously scaled to
device coordinates in order to give the correct result. But because
scaling is now done inside QTextDocumentLayout that scaling must be
removed and pixel values based on qt_defaultDpi are provided instead.
Fixes: QTBUG-78318
Change-Id: I6fe6dcc25f846341f6a2fe5df2f54baea473fdfd
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Do not suppress the resize event caused by the handling of
WM_DPICHANGED unless the screen really changed.
Fixes: QTBUG-76510
Change-Id: I8b9ae41ad7deb863c1633ec5901bc04304b2165c
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
If the domain passed down is an actual TLD that's the subject of a *
rule, e.g. "ck" subject to *.ck, then we were finding no dot in it and
concluding that it couldn't be the subject of a * rule.
Added a test for the specific .ck case and commented on where we could
get some canonical test data that I tripped over while researching
this. Cross-reference the cookie-jar test from the QUrl test, too.
Fixes: QTBUG-78097
Change-Id: Id858a9dae22e6b306a68df3fc199e0160f537159
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Combining this with the indentation would be counted as mixing space
changes with non-space changes, so they're separate.
Change-Id: Iac57050717b1c4c86a253866c9a6cd5ea7add8f7
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
There was a haphazard mix of 4-space and 2-space indents.
Use four spaces throughout.
This commit includes no reflow (which is needed), as the inanity-bot
will complain about the mixing of space changes with "non-space"
changes if I do that.
Change-Id: If55ab035da02d0770471e77ecfe00eb168a3da15
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
qdoc needs to see these declarations now because... clang.
Change-Id: I93264125db5bcea6adb1a4636e5459ec80702de1
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
The DefaultFontFallbacks.plist system file that we used for looking up
style fallbacks does not exists in macOS 10.15, nor did it ever exists
on iOS. Instead of relying on this file, we hard-code a set of default
families, that we then look up the fallbacks for.
The result of QFont::defaultFamily() on macOS is now:
QFont::Helvetica --> "Helvetica"
QFont::Times --> "Times New Roman"
QFont::Courier --> "American Typewriter"
QFont::OldEnglish --> ""
QFont::System --> "Lucida Grande"
QFont::AnyStyle --> "Lucida Grande"
QFont::Cursive --> "Apple Chancery"
QFont::Monospace --> "Menlo"
QFont::Fantasy --> "Zapfino"
And on iOS:
QFont::Helvetica --> "Helvetica"
QFont::Times --> "Times New Roman"
QFont::Courier --> "American Typewriter"
QFont::OldEnglish --> ""
QFont::System --> "Helvetica"
QFont::AnyStyle --> "Helvetica"
QFont::Cursive --> ""
QFont::Monospace --> "Menlo"
QFont::Fantasy --> "Zapfino"
Fixes: QTBUG-78240
Change-Id: Ie9bc13c9c1031d89f024199e4736a046c568a48d
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Since 9c8d1ca18b, the test would fail
when High DPI scaling is enabled:
FAIL! : tst_QWidget::translucentWidget() Compared QImages differ in device pixel ratio.
Actual (actual): 2
Expected (expected): 1
.\tst_qwidget.cpp(8913) : failure location
Set the device pixel ratio on the expected pixmap to fix this.
Change-Id: I517495931c2c6b1f49125bb4b5836e304bdbf545
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
The function calculating a correction for the size of
windows metrics depending on screen would bail out when high
DPI scaling was disabled. This is wrong since the correction
is also needed in that case, delete the clause.
Task-number: QTBUG-64890
Change-Id: Idef22e18fc616a211ccac48400490fc52393a338
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
- use range-based for loops where possible
- use nullptr
- use member initialization
- remove a lot of C-style casts
- use override
- fix some signedness warnings
- add some missing break statements
Task-number: QTBUG-76493
Change-Id: Ica6ed65ec29e958406e54d816b8a679ed81bd177
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
When a prepared statement is still alive after the database was removed
with QSqlDatabase::removeDatabase(), the cleanup routine is trying to
access the driver which is no longer alive which results in a crash.
Fix it by checking if the driver is still alive similar to
5f66486cc2.
Fixes: QTBUG-43889
Change-Id: Ib466a76d014e32c055d203bda15b075ad3dff3d9
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
Reviewed-by: Jesus Fernandez <jsfdez@gmail.com>
This reverts commit 5859f7d0d9.
Reason for revert: the blocker for qtdeclarative has been merged
(in qtdeclarative/c060f6e765a2f155b38158f2ed73eac4aad37e02).
Change-Id: Ie69cb1567417173f543e88f659658fe03ba28830
Reviewed-by: Liang Qi <liang.qi@qt.io>
Cleanup QTableView autotest:
- use range-based for loops where possible
- use nullptr
- use member initialization
- use new signal/slot syntax
- remove a lot of c-style casts
- use static invocations
- use override
- instantiate objects on stack instead heap to avoid memleaks
Change-Id: I52fee26697b1732afa9f965e600d4c59551370ce
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Change-Id: I71c6a10f6593ac28bf8f60d9db8d167cf88715cb
Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
The logic was changed in ee82f8661 to only draw a window background
when the window was textured, and otherwise ask for a clear window
background. This has an unfortunate side-effect on macOS 10.15 that
the window's title bar will be partially transparent and reflect the
content under the window, with a blur effect.
It also inadvertently broke the use-case of setting the NSWindow
background color explicitly.
With this patch we're back to the behavior before ee82f8661, and
users who still want to have a non-borderless window with a clear
background can still do this by setting the background color to
the clear color manually.
Task-number: QTBUG-77637
Change-Id: I8a11bc46e6393b29a37f002ea123a987048106b9
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
When setting a DPI in xrdb, it should have the same effect on apps that
enable scaling and apps that don't (including Qt4 and GTK applications).
That's what happened in Qt 5.13, while the recent changes removed that
division, and as a result the fonts were huge in Qt5 apps compared
to Qt4/GTK/kwin/plasmashell/krunner (which don't scale, but do honor
the font DPI).
Change-Id: Icd7be2d15a9b50982ae624e41bd9e546f315d58b
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
Tidy up QDateTime::offsetFromUtc's doc, in the process. We don't take
DST into account for dates before the epoch; that should be mentioned
when saying we take DST into account. Also, referring to *this as the
"current" time begs to be misunderstood.
The \class comment also misleadingly claimed that we don't take into
account any changes to time-zone before DST; where, in fact, we only
ignore DST changes before 1970, not changes to standard offset.
Change-Id: I090e668edf0338c825f5afcc67f894579a129c46
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
There is no year 0 in the proleptic Gregorian calendar, so QDate()
won't be happy if asked for a date in it. Tweak scanning of the data
we get from MS-Win so as to avoid a date calculation that could
otherwise happen in year 0 when constructing
QDateTime(QDate(1, 1, 1), QTime(0, 0, 0), QTimeZone("Australia/Sydney")).
Added a test for this case, which Oliver Wolff has kindly verified
does reproduce the assertion failure. However, Coin is unable to
reproduce, as all its MS builds are configured with -release, so
Q_ASSERT() does nothing. (The relevant code then skips over year 0,
albeit for the wrong reasons, and gets the right results, albeit
inefficiently, leaving no other symptom by which to detect the
problem.)
Fixes: QTBUG-78051
Change-Id: Ife8a7470e5bd450bc421e89b3f1e1211756fc889
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
This reverts commit 521a85395d.
Having libraries resolved to absolute file paths by configure has
annoying consequences:
1. The Qt installer needs to unabsolutify paths in all kinds of files.
This is error-prone and fragile.
2. It hurts Qt's relocatabilty. The absolute paths are unlikely to be
right on different systems.
3. Qt's configure must imitate linker behavior correctly to do the
resolution right on every platform, which is hard to get right.
Consequently, the disadvantages of 521a8539 outweigh the advantages.
Task-number: QTBUG-72903
Change-Id: I3e159c46a1348963615b95614e56f026ecb2aefd
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
...and change the return value of makeThreadLocalNativeContextCurrent() to
a bool since we expect this to mirror QOpenGLContext::makeCurrent().
Change-Id: I339507152e461fe28fcf7fe777165e6d0072f055
Reviewed-by: Christian Strømme <christian.stromme@qt.io>
After these two classes were no longer marked final clang started
complaining because their dtor is not marked virtual.
Amends 9dc594b2bf
Change-Id: I42b78c0b444935d3e0cb4d476d3881fd5fb5c3cb
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>