Commit 1c623bc6d1 introduced a new
QMetaObject revision, which change the size of the QMetaEnum data.
When looking up QMetaEnum in a QMetaObject, this size need to be
checked for every different QMEtaObject from the hierarchy, not just
the first one.
Change-Id: I6f0d3982329822e15e284aef9b141d4c9ab351b9
Reviewed-by: David Faure <david.faure@kdab.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Fixes a speed regression on ARGB32 painting on low end hardware
introduced when it was switched to using the RGB64 raster routines.
It turns out several of our embedded QPA targets use ARGB32 as native
format.
Task-number: QTBUG-69724
Change-Id: I6d7993c12da46a85b8354eb905930dae9602b5e6
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
If the hardware produces events faster than the app can consume between
two updates, Windows automatically coalesces them into a single message
with the latest touch/pen pointer state and coordinates, effectively
compressing those events. But the pointer API also supports querying
and retrieving the skipped individual touch and pen frames.
There are cases where keeping all the events generated by the hardware
is desired, especially for pen events where having the most sampled
points available is critical to precisely rendering curves.
Qt already defines application attributes to control event compression
for general high frequency events and for tablet events in particular.
Use them on Windows also to control whether to retrieve skipped frames.
[ChangeLog][Windows] The application attributes AA_CompressTabletEvents
and AA_CompressHighFrequencyEvents are now supported on Windows 8 and
above for touch/pen input, with the same defaults as on X11 (compress
touch events, don't compress tablet events)
Task-number: QTBUG-44964
Task-number: QTBUG-60437
Change-Id: I1b11a043e2d71ee502895971fafb3a46306a89d8
Reviewed-by: Andre de la Rocha <andre.rocha@qt.io>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Both sqlite3_open_v2 and sqlite3_close are documented to return an error code:
https://www.sqlite.org/c3ref/open.htmlhttps://sqlite.org/c3ref/close.html
However, those were ignored (other than checking whether the operation
succeeded), causing QSqlError::nativeErrorCode() to always be "-1" when there
was an error while opening/closing the database.
Additionally, the error string needs to be read (via sqlite3_errmsg16) in
qMakeError *before* d->access is set to 0, or the databaseText() will always be
"out of memory" no matter what error actually happened.
Task-number: QTBUG-70506
Change-Id: I75cbf178c9711442e640afd26c4502214d20c598
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
This was found while running the ODBC tests. tst_QSqlQuery::isNull()
accounts for this already.
Change-Id: Idf99a85396d7aa4e69b89467f873b105ef946f7f
Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
On Samsung devices this would cause it to always to captalize each word
even if it was not a new sentence. Therefore we use QTextBoundaryFinder
to determine if it is a new sentence or not.
Task-number: QTBUG-69398
Task-number: QTBUG-66531
Change-Id: I24bf36f09a2570acfefd4343551cb1720ddc6279
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
If SHM is disabled, that code path already does its own bswaping.
Change-Id: I6c17f6c5c5502c8f89098d38d931b6b8f50b2640
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
The default values for varchar columns were not decoded properly.
Task-number: QTBUG-46968
Change-Id: Ie13d48c316cd694240f7e287010b97afc8c6c341
Reviewed-by: Robert Szefner <robertsz27@interia.pl>
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
Stencil is - very likely - cleared just like depth. Also, switch to
STORE_OP_STORE for the multisample buffer, for correctness.
Change-Id: I31b56658286205af8551018115ca2abbe541be67
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
Running with QT_VK_FORCE_STAGE_TEX does not work at all with recent
NVIDIA drivers due to QVulkanWindow's and the example's naive way of
picking the memory index. Enhance this and add a warning note to the
QVulkanWindow docs as well.
Change-Id: I7f200e11d982b56e3da3b71ee3915bd7bfca5cc1
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
After convert and fetch were split, only convert was still NEON
vectorized, while fetch is the more commonly used version.
Change-Id: Iea2af7ccee6589b3d6e9908afeaae2d1ad2753be
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
in non-prefix builds, the forwarding headers always end up in qtbase's
build dir, while the injected headers always live in the build dir of
the module they belong to. to deal with that, we now record the target
path relative to the module root dir instead of relative to the base
directory of the forwarding header itself.
Fixes: QTBUG-70056
Change-Id: Ic4346148a125b13e2610f6965cdf4f5266ac763e
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
As transform() returns worldTransform(), point out that it is an alias
in its description.
Fixes: QTBUG-18117
Change-Id: I0eb1f78c6955b499906024105f9969cdccf13303
Reviewed-by: Martin Smith <martin.smith@qt.io>
39cb9ac873 moved the _ENABLE_EXTENDED_ALIGNED_STORAGE define from
msvc-version.conf to msvc-desktop.conf which basically removed the
define from winrt builds. By adding it to winrt's common qmake.conf
these builds are fixed.
Change-Id: I3d87c55fb52685859713f7466012b45c46145678
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Some ODBC drivers, such as old Informix ODBC drivers will incorrectly
include a trailing \0 in a string when this should not exist. For
unicode strings this was already accounted for, but for non-unicode ones
this was not covered.
The change also fixes up the comments a bit to make this clearer and
also added one for the unicode case.
Task-number: QTBUG-62406
Change-Id: Id932a58d9e5fdff2f4d1aacf8cc9fdaeb34f95f4
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
When a window is resized AppKit groups all updates to the view frames and
corresponding layer bounds, so that the result of the resize is visually
atomic, but this only works for the main thread.
http://openradar.appspot.com/radar?id=4990815088672768
When a separate thread renders to one of the views in the window, it may
result in the view and its layer updating its bounds visually before the
resize has been visually reflected for the window itself and its border.
To ensure visually atomic updates, we disable all screen updates for the
process during resizing. This is the same workaround used by e.g. the
NSOpenPanel class, which renders the content of the view out of process,
and by Chromium for a similar use-case:
https://chromium-review.googlesource.com/c/chromium/src/+/798774
Ideally we'd do this only for the window that is being resized, but there's
no known API to do that. The deprecated [NSWindow disableScreenUpdatesUntilFlush]
is a no-op these days, and used NSDisableScreenUpdates internally anyways).
Fixes: QTBUG-69321
Change-Id: I84de714782278f2e0b2b2e1eb245c30810cb3023
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
The test was computing GMT with a suffix added to it for the offset;
but when the offset is zero there's no need for it. Cleaned up the
logic so that it only checks for a "padded to two digits with zero" if
the number is single-digit (and use string arithmetic in preference to
wantonly complex .arg()ing; and use simpler names). Since we don't
try to check anything unless GMT does appear in the string (because
the actual zone ID was used, instead of GMT with an offset), the case
of zero offset has nothing more to check than that GMT was present,
the precondition for checking anything.
Task-number: QTBUG-70322
Change-Id: I0b8abe7e63d9d72fa9cf32f188b47a78a849044b
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Set Qt::AA_DisableShaderDiskCache when the feature "disable_program_cache"
(modeled after the Chromium driver bug list) is present and set it for the
Intel HD Graphics 620 card.
Task-number: QTBUG-64697
Change-Id: Ibba588d2ab296b5c959ab8ee9712b47ec7cc906e
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
In openSUSE 15.0 /etc/os-release the ID of the OS was
changed from "opensuse" to "opensuse-leap". So every blacklisting
we did for opensuse, didn't cover opensuse-leap. This one adds
opensuse-leap as a blacklisted platform whenever opensuse
was blacklisted.
Task-number: QTBUG-70463
Task-number: QTBUG-51399
Change-Id: I5879eb34926757163973d8b9442eae58f47d2f11
Reviewed-by: Liang Qi <liang.qi@qt.io>
Make the decoder fail early to avoid spending time and memory on
attempting to decode a corrupt image file.
Change-Id: I874e04f3b43122d73f8e58c7a5bcc4a741b68264
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
These were hardcoded to light colors, which made the
QMainWindow status bar look out of place and made the
(light) text hard to read.
Hardcode to dark colors for DarkAqua which more or less
match the native look. Keep the optimization where the
Gradients are stored in static variabless.
Change-Id: I3e75b42c41d3e2d18e4bc0f17d950a702ccad662
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Reviewed-by: Gabriel de Dietrich (DO NOT ADD TO REVIEWS) <gabriel.dedietrich@gmail.com>
Commit 8b6100d512 removed
bool QtPrivate::QStringList_contains(const QStringList *that, const QString &str, ...)
(in favor of a QStringView overload). However this was used inline in
qstringlist.h, so apps were referencing that symbol directly.
As a result, upgrading to Qt 5.12 gave errors like
libKF5ConfigCore.so.5.50.0: undefined reference to `QtPrivate::QStringList_contains(QStringList const*, QString const&, Qt::CaseSensitivity)@Qt_5'
collect2: error: ld returned 1 exit status
Change-Id: I862263a9b06157052df894a201dfd86df8c3f4fe
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Luca Beldi <v.ronin@yahoo.it>
Clicking in the main renderer window passes a new position to the lens,
disregarding the "What's This" (documentation) overlay window.
This change checks if the documentation window is open on click, and if
it is, closes the documentation window and returns without further
handling of the mouse event.
Fixes: QTBUG-7205
Change-Id: I821245ec6c78be00d80af461baf8e4d59e0f351f
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Calling setView or update on NSOpenGLContext results in recreating the
internal GL surfaces of the view. Unfortunately there seems to be a
fixed amount of these surfaces available, so if we spin a loop where
we for some reason end up recreating them, we'll easily run out, and
lock up the whole window system:
thread #6, name = 'SwapThread'
frame #0: 0x00007fff7b45220a libsystem_kernel.dylib`mach_msg_trap + 10
frame #1: 0x00007fff7b451724 libsystem_kernel.dylib`mach_msg + 60
frame #2: 0x00007fff751c1675 SkyLight`SLSBindSurface + 247
frame #3: 0x00007fff5d9c4328 OpenGL`___lldb_unnamed_symbol29$$OpenGL + 255
frame #4: 0x00007fff6bf42c33 libGPUSupportMercury.dylib`gldAttachDrawable + 364
frame #5: 0x00007fff5d9e61e7 GLEngine`gliAttachDrawableWithOptions + 257
frame #6: 0x00007fff5d9c4bb0 OpenGL`___lldb_unnamed_symbol38$$OpenGL + 969
frame #7: 0x00007fff5d9c8b0e OpenGL`___lldb_unnamed_symbol57$$OpenGL + 82
frame #8: 0x00007fff5d9c8e55 OpenGL`CGLSetSurface + 330
frame #9: 0x00007fff50d0eb2c AppKit`NSOpenGLContextAttachOffScreenViewSurface + 352
This can happen e.g. when resizing the application, where AppKit itself spins
a loop where we don't end up back in QCocoaEventDispatcher::processEvents()
for each pass (where we do have a local pool). Or it can happen in the
render-loop of a render-thread that doesn't use the event dispatcher.
Change-Id: Iaf2f879dd01e3d807d0f35705ccc978dbc89036b
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
While these destructors are essentially trivial and contain no code,
the classes inherit QObject and thus have virtual tables. For such
classes -Wweak-vtable generates a warning: "'Class' has no out-of-line
virtual method definitions; its vtable will be emitted in every translation
unit." Noticed this after updating QtCreator to the latest version.
Change-Id: Iacb5d0cd49353bd35260aff736652542bb1ef197
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
On platforms where char is signed, like x86, the following is an error
(narrowing conversion):
unsigned char x[] = { '\xc3' };
Change-Id: I495bc19409f348069f5bfffd15518f9ef4e43faf
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
We don't need a separate QWindow pointer to keep track of the active
window, it's recorded already by the NSOpenGLContext's drawable.
And we don't need to juggle the drawable when the window is hidden,
the drawable is still valid after the window is re-shown, and we
call update on every frame (for now) anyways, which will reconfigure
the drawable if needed.
Change-Id: I199b6c027226dd239c13ecc4aba86986ca09a1eb
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
tst_QItemView::indexAt() was disabled since Qt 5.0 (and maybe earlier)
maybe due to it's long runtime (15s on my machine).
Speed it up by checking only some special positions inside the visual
rect (borders, center) as it will likely not fail on other positions but
succeed for the ones which get tested.
Task-number: QTBUG-22470
Change-Id: I5c7135757049176f9daca4afc1b7f40c75b9ecd9
Reviewed-by: David Faure <david.faure@kdab.com>
When the first row(s) of a QTableView is hidden, PageUp could not reach
the first visible row because logicalRow(0) is taken without checking
if the row is visible.
Task-number: QTBUG-70215
Change-Id: Ic7820352b8988accb685ea7d16908d3fa8bf2847
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Luca Beldi <v.ronin@yahoo.it>
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
Reviewed-by: David Faure <david.faure@kdab.com>
QLayout(QWidget *parent) directly calls parent->setLayout(this) which
can lead to a runtime warning later on when someone tries to set the
layout on the parent again.
Task-number: QTBUG-69761
Change-Id: I21ef8895fd65f3e23e57527a6d38936e45417b63
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io>
Instead of doing it up front and then restoring the current context
if the makeCurrent call failed.
By delaying the update, QPlatformOpenGLContext::makeCurrent has the option
to check which context was current before the call.
Change-Id: I458f5c00d7c820acbe2f8552b0513fce99b9b683
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>