Before applying this patch, the debug message will contain new lines
which will look rather weired, this patch fixes that.
Amends commit 5e0d9a077d
Change-Id: I2420c04dd7e18a6556664a05ac4ef35c9b652f0c
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
This patch addresses the following issues:
(1) some places are still using the original workaround, replace
them with the new qt_winrtbase_p.h workaround.
(2) add more comment to let people know how to workaround other
cppwinrt issues (it was a common issue for many years and may be
fixed upstream recently, but let's at least document it in case
the user is still using old version cppwinrt).
Amends commit b2c1237b45
Pick-to: 6.5 6.4
Change-Id: Ife676f41739bbe69d9fb23bf5758be4b1fab4855
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
Also, use the embind approach as the rest of the events do, and
introduce a KeyEvent class which simplifies and streamlines event
support.
The event translator has been given a more specific function of
just handling the dead keys. Rest of the translation functionality
is coded directly in KeyEvent for more encapsulation.
Change-Id: I11b0262fc42fe920206ecc6de0d434b9d9ab9998
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
There's no need of calculating offsets into the \0-separated string
of atom names; since we're going to iterate that string exactly once,
do that, and register the corresponding atom name as we iterate.
(This means that solutions that calculate the offsets at compile-time,
like qOffsetStringArray, are also overkill for the use case).
Change-Id: I71ed512dee4f2a8bfb99ca2392efbd8a07f2a7c1
Reviewed-by: JiDe Zhang <zhangjide@uniontech.com>
Reviewed-by: Liang Qi <liang.qi@qt.io>
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Any identifier starting with underscore followed by a capital letter is
reserved for the implementation in C++, so don't use them. Rename the
entries in the Atom enumeration by adding an "Atom" prefix to them.
Pick-to: 6.2 6.4 6.5
Change-Id: I059e2093149f39cc9324cd1159c0d9e076eda93a
Reviewed-by: JiDe Zhang <zhangjide@uniontech.com>
Reviewed-by: Liang Qi <liang.qi@qt.io>
Macro Q_FIXED_POINT_SCALE in qpathssimplifier.cpp clashes with
the macro with similar name in qtriangulator
Pick-to: 6.5
Task-number: QTBUG-109394
Change-Id: I02732ae62238e8b7fae0630764fdd33b6203afe3
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
We don't want them in Qt 7.0.0, either.
As a drive-by, also guard the implementation with the same check.
Pick-to: 6.5
Change-Id: I21b181e5563ebc2b247d6c5ad005bb76224f0daf
Reviewed-by: Marc Mutz <marc.mutz@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
These files should not change the outcome of the build process, but are
merely added to better support the CMake and Android integration in
Qt Creator. Also those files were previously listed in the OTHER_FILES
section of the qmake project files.
Change-Id: Id3d403130ee8800ed6b0877f9f1c3dd1f28b46b7
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
This is almost exactly the same as the "Analog Clock" (widget) example.
"Analog Clock Window Example" demonstrates:
* How to render to a QWindow (covered by RasterWindow example)
* QPainter and transformations (covered by Analog Clock example)
* How to use QTimer (covered by Analog Clock example)
Pick-to: 6.5
Change-Id: I7f20a29798830ed6345eca250e4139cb314cab84
Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
This somewhat indicates the progress of configuring a specific
repo and the slower period of time when configuring examples
in-tree.
Pick-to: 6.5
Change-Id: I643536c4ebc865933730b7af2a1d0c56bbbf2912
Reviewed-by: Amir Masoud Abdol <amir.abdol@qt.io>
Reviewed-by: Alexey Edelev <alexey.edelev@qt.io>
Use the CONDITION_INDEPENDENT_SOURCE argument to add the
accessible/qaccessible.h and accessible/qplatformaccessibility.h
header files as part of the QT_FEATURE_accessibility feature.
This will warn feature maintainers about the need of proper
guarding in places where headers are used.
Amends 11a9af6484
Change-Id: I9d3c3526572da205e316747f809a5ff93717897f
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
In all the cases below, the parameters are defined in the
qtestsupport_gui.h as well.
Pick-to: 6.5
Task-number: QTBUG-109394
Change-Id: I3311d6c23b3a811dbe20286bd4534ca1ed7cd7f3
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
The style hint SH_UnderlineShortcut can now be turned on/off via the
platform theme.
No change in functionality so far on any platform, this behaves the
same way it did before the change. The change just adds a possibility
for platforms to redefine the default underlining behavior.
Task-number: QTBUG-76587
Change-Id: Ibda104f1b733371da19825b96e73c22f42faf853
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
This is technically possible on iOS, but the system doesn't give us
a callback unless the user accepts the upgraded permission level,
and we need a deterministic callback in both cases so that we can
report the result back to the permission request callback.
https://tinyurl.com/requestalwaysauthorization
Pick-to: 6.5
Change-Id: Id006dbbb2f6fad4b831742e4d3e904525aaa8a2a
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
There's no way to upgrade an Approximate accuracy permission to Precise,
so once we have a known status we report the lacking accuracy as Denied.
Pick-to: 6.5
Change-Id: Id49af825335ff09669aa7f2285caaa744a5a4d24
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
Reviewed-by: Juha Vuolle <juha.vuolle@qt.io>
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
If AUTOGEN_BUILD_DIR is set, _qt_internal_get_target_autogen_build_dir
returns that; otherwise, the default builddir/${target}_autogen will be
returned.
Pick-to: 6.5
Task-number: QTBUG-110696
Change-Id: I028058bd0176c25bc4bc66be8abcae4f7e43a0f2
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
The painter saves existing paint engine state in the stack and restore
back to the previous state after performing required paint operation.
The clip path stored as part of paint engine state is getting
translated more than once during save and restore operation. This
multiple transformation of the same clip path causes incorrect
translation within the plane.
To fix this issue, during restore, remove translation of clip path
with redirection matrix.
Fixes: QTBUG-109518
Pick-to: 6.5 6.4 6.2
Change-Id: I1509bc7fa4965f2802bce62c1ed27cdb90da617a
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
This improves the performance of tst_QDir_10000::iDontWantAnyStat
(QDir::entryList Unsorted)
from 9.7ms to 7.2ms, i.e. the same as iDontWantAnyStatIterator
(QDirIterator).
Change-Id: I3faf8af1a55575df97912b1ce720492c8fd903c9
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Include the creation of the QDir inside QBENCHMARK, otherwise
the it can hit the cached code path where subsequent runs return
results much faster.
* Same for the opendir()/readdir() test: if opendir() isn't called
again, readdir() will just return null right away.
These two issues led to nonsense results like 0.00025 msecs per
iteration, doing nothing is really quick.
While at it, port the cleanup code to QDir::removeRecursively()
Pick-to: 6.5 6.4 6.2
Change-Id: Ic1bdd92d41efe1f6d0eaaa33eca066cb7d19fc93
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
- The optional nice-to-haves DebugMarkers, Timestamps, PipelineCache
are not yet implemented (features reported as false, to be
implemented later, although buffer/texture resource name setting
already works as-is, regardless of DebugMarkers).
- Mipmap generation for 3D textures is missing. Won't matter much
given that 3D textures are not used in Qt for anything atm. For
generating mipmaps for 2D (or 2D array) textures, the MiniEngine
compute shader and approach is used. 3D support for the mipmap
generator may be added later. 1D textures / arrays are supported
except for mipmap generation, and so the
OneDimensionalTextureMipmaps feature is reported as false.
- Qt Quick and Qt Quick 3D are expected to be fully functional.
(unforeseen issues are not impossible, of course)
- Uses minimum feature level 11.0 when requesting the device. It is
expected to be functional on resource binding tier 1 hardware even,
although this has not been verified in practice.
- 2 frames in flight with the usual resource buffering
(QRhiBuffer::Dynamic is host visible (UPLOAD) and always mapped and
slotted, other buffers and textures are device local (DEFAULT).
Requests 3 swapchain buffers. Swapchains are mostly like with D3D11
(e.g. FLIP_DISCARD and SCALING_NONE).
- The root signature generation is somewhat limited by the SPIR-V
binding model and that we need to map every binding point using the
nativeResourceBindingMap from the QShader. Thus the root signature
is laid out so each stage has its own set of resources, with shader
register clashes being prevented by setting the visibility to a
given stage.
Sampler handling is somewhat suboptimal but we are tied by the
binding model and existing API design. It is in a fairly special
situation due to the 2048 limit on a shader visible sampler heap, as
opposed to 1000000 for SRVs and UAVS, so the approach we use for
textures (just stage the CPU SRVs on the (per-frame slot) shader
visible heap as they are encountered, effectively treating the heap
as a ring buffer) would quickly lead to having to switch heaps many
times with scenes with many draw calls and sampledTexture/sampler
bindings in the srb.
Whereas static samplers, which would be beautiful, are impossible to
utilize safely since we do not have that concept (i.e. samplers
specified upfront, tied to the graphics/compute pipeline) in the
QRhi API, and an srb used at pipeline creation may change its
associated resources, such as the QRhiSampler reference, by the time
the shader resources are set for the draw call (or another,
compatible srb may get used altogether), so specifying the samplers
at root signature creation time is impossible.
Rather, the current approach is to treat each sampler as a separate
root parameter (per stage) having a descriptor table with a single
entry. The shader visible sampler heap has exactly one instance of
each unique sampler encountered during the lifetime of the QRhi.
- Shader-wise no different from D3D11, works with HLSL/DXBC 5.0
(i.e. existing .qsb files with DXBC in them work as-is). But unlike
D3D11, this one will try to pick 6.7, 6.6, ..., down to 5.0 from the
QShader, in that order.
- Uses D3D12MA for suballocating. As a result it can report vmem
allocation statistics like the Vulkan backend, and it does more
since the DXGI memory usage (incl. implicit resources) is also
reported. This is optional technically, so we also have the option
of going straight with the heavyweight CreateCommittedResource()
instead. That is what we do if the adapter chosen reports it's
software-based or when QT_D3D_NO_SUBALLOC=1 is set.
- PreferSoftwareRenderer (picking the WARP device) and the env.var.
QT_D3D_ADAPTER_INDEX work as with the D3D11 backend.
- It is not unexpected that with large scenes that generate lots of
draw calls with multiple textures/samplers per call the performance
may be slightly below D3D11 (probably mostly due to descriptor
management). Similarly, the reported memory usage will be higher,
which is partly natural due to creating heaps, descriptor pools,
staging areas, etc. upfront. Will need to be evaluated later how
these can be tuned.
Change-Id: I5a42580bb65f391ebceaf81adc6ae673cceacb74
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
qt6_finalize_target warned about double invocations on executables
already. For libraries and plugins this situation wasn't detected.
Make the warning consistent for qt6_add_executable, qt6_add_library and
qt6_add_plugin. The internal property _qt_executable_is_finalized has
been renamed to _qt_is_finalized and applies to all targets that can be
finalized.
Pick-to: 6.5
Change-Id: I06821d08042e1453f3e058ed90a13e90a4f06640
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Windeployqt now reads modules/*.json and translations/catalogs.json to
determine the available Qt modules, Qt plugins and their corresponding
translation catalogs.
This patch removes the hard-coded information that was used before. Now,
we don't have to update windeployqt anymore to teach it a new Qt module.
Pick-to: 6.5
Fixes: QTBUG-109841
Task-number: QTBUG-106342
Change-Id: Ib7b7f44ca7d40d0c73d717d8494367af412ebdbe
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
WindowTitleHint now correctly enables/disables the window title, and
FramelessWindowHint correctly enables/disables the window frame.
Change-Id: I6f98f0a53af828606748308c6b5bd5d492cef9d2
Reviewed-by: Aleksandr Reviakin <aleksandr.reviakin@qt.io>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
QLocale::matchingLocales() only returns matches from the CLDR database,
it does not include the current system locale as a match, even if it
does match. Add the current system locale, if it matches.
Task-number: QTBUG-106644
Change-Id: If2e409bf0fd8582941646838330e36b79952d3f6
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
There are still ambiguous overloads of display(), which cause PMF-syntax
to fail.
Pick-to: 6.5 6.4
Task-number: QTBUG-110952
Change-Id: I0887a5a06b026e4d5a20ef732d5892c8ac7fb6db
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
These linking issues were not caught by documentation testing in the CI.
* android-content-uri-limitations.qdocinc: Fix external link title
* Fix links to 'Native IPC Keys'
* Fix \sa links to 'Inter-Process Communication'
* Replace \sa links to non-existent function nativeKeyType()
* Drop explicit link to undocumented class QBasicAtomicInteger
Change-Id: I041a8cd2301cc2e77b88c085e74e9178e507a7a1
Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io>
Reviewed-by: Nicholas Bennett <nicholas.bennett@qt.io>
Easier to read, saying in one line that for which the old code needed
three.
Task-number: QTBUG-110710
Change-Id: Ie2a1d11aefe0bdf5f4db0694832fce669de564fc
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
decltype(QPropertyDelayedNotifications::used) is qsizetype, not int,
so don't use int to count from 0...used. The notify() and
evaluateBinding() functions use their int argument only for pointer
arithmetic, so this is completely self-contained.
Amends fdedcb6ec6.
Pick-to: 6.5 6.4 6.2
Task-number: QTBUG-103532
Task-number: QTBUG-110710
Change-Id: I765a06628d330fbb57a2fbecc96d66690bb62f13
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
This ensures the tst_QSqlQuery::record() test passes when checking the
tablename.
Pick-to: 6.5 6.4 6.2 5.15
Change-Id: I146f9f627ea366c6813af61ce48b930ca1041b15
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Cleanup the codebase a little bit:
- move loop variable into for scope
- use utils functions instead homebrew
- avoid use of const_cast<>
- simplify splitTableQualifier()
Change-Id: I6962f01c94a6b4e0e38ad1b229cdf6e8b3308c78
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Avoid an unneeded copy in toSQLTCHAR() when sizeof(SQLTCHAR) == 1 or 4
by directly writing the encoded data into the QVarLengthArray.
Change-Id: Ic4180343764fa1ca175a9cdd444c5359d664c754
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
QSettings was included but not needed.
This patch removes the include.
Pick-to: 6.5
Change-Id: I9da146312f26f87eb863d6409b90988603cf46d3
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
They cause clashes in CMake Unity (Jumbo) builds.
Pick-to: 6.5
Task-number: QTBUG-109394
Change-Id: I3c51fb41d29e5c649537b999dced7e2d413b26a7
Done-with: Amir Masoud Abdol <amir.abdol@qt.io>
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Amir Masoud Abdol <amir.abdol@qt.io>
The problem is `PropertyNotify` event generated by
`xcb_delete_property()` at return could be reported as an actual
timestamp at next call due to a missing `state` filter.
Because `PropertyNotify` is generated even if an unchanged property
value is set we can get rid of this delete event easily.
This issue causes observable problems in kwin_x11 (KDE project)
too.
Fixes: QTBUG-56595
Pick-to: 5.15 6.2 6.4 6.5
Change-Id: Ice6cfa934e3769d86e9f7264e369dc5918c8542a
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
Reviewed-by: Liang Qi <liang.qi@qt.io>
Reviewed-by: JiDe Zhang <zhangjide@uniontech.com>
Failing test functions fastMove, moveAccross, moveInOutOverlapped seem
to be stable in the meanwhile. This patch removes the blacklisting.
Task-number: QTBUG-109036
Pick-to: 6.5
Change-Id: I9a2b015572e4d8a4eac196d3985c052030fd84e2
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
The html accessibility elements are positioned relative
to the window a11y container. Convert the global (screen)
coordinates we get from QAccessibleIntreface::rect() to
window coordinates.
Pick-to: 6.5
Change-Id: Ifd4eb671def296b1eb418789b7ca85afa365e546
Reviewed-by: Mikołaj Boc <Mikolaj.Boc@qt.io>
The code was a assuming that an a11y interface always
has a parent, which is not the case for the root interface.
Also factor out to a getWindow() function, to prepare
for re-use later on.
Pick-to: 6.5
Change-Id: I52a841bf94c712deb9603e8b9c2c878820c5f117
Reviewed-by: Mikołaj Boc <Mikolaj.Boc@qt.io>
We don't want to make the top-level screen contenteditable,
since that interferes with accessibility. Instead, make
the canvas contenteditable and install clipboard event
handlers there.
Also move follow-up settings which counters some of the
effects contenteditable (outline: none and inputmode: none),
and move aria-hidden.
Pick-to: 6.5
Change-Id: Ibe73d8d097acd948ba8920c781a2003db0a14f3d
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
Since 32666691c2, icons have been set
manually on img elements. The css code assigning the icons to elements
is now unused - remove it.
Change-Id: I394f08371c80f0e374a5cc7e39d17bb6091d18dc
Reviewed-by: Aleksandr Reviakin <aleksandr.reviakin@qt.io>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
The new name better matches the names of existing functions there.
A comment on the old code noted that such a move should really be
done, so as to correctly share the environment-mutex locking.
In the process, move the (now three) time-related internal functions
from qglobal_p.h to a new qtenvironmentvariables_p.h since that's the
natural place for them given where they're defined (and the fact that
they're for internal use only).
Change-Id: Ib028baebaf31a806a2c0c97caaaba0a466c11cea
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>