- executed pro2cmake script on windows qpa plugin
- added windowsuiautomation platformsupport project
- fixed plugin dlls and lib files to be written to the same path
- fixed an issue comErrorString which used implicit casting
from QString to char*, but plugins are currently built
with QT_NO_CAST_TO_ASCII
Task-number: QTBUG-74140
Change-Id: I5db3b6c5264bbd5dfba2998b049fda36eb312c70
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
- Fix qmake build
- Fix QtNetwork moc-ing, by including the moc files
inside the cpp files
- Fix sql odbc plugin by including QT_PLUGIN define
- Fix Boostrap to link against the Platform target, to get the
correct Unicode and WIN64 defines.
- Fix vulkan headers to be found
- Fix freetype bzip and png unresolved symbols / linker issues
when building minimal platform plugin (also need to make
sure to use the vcpkg toolchain instead of CMAKE_PREFIX_PATH
because then find_package is overridden, which does magic
to properly propagate static library dependencies).
- Fix qfilesystementry test not to be built without private
tests feature (it led to undefined symbols issues).
- Make sure to remove QT_NO_CAST_TO_ASCII define when building
QtCore, so that the qstringbuilder3 test builds
successfully.
Task-number: QTBUG-74140
Change-Id: I353d08392b604d55f8e62cdd8696d1e19a3c084a
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
This change fixes a few things in one go:
* cmake's FindOpenGL cannot be used reliably to detect EGL. So use a
custom module for that.
* Added a custom module for GLESv2 detection, as cmake's FindOpenGL
does not support that.
* Map CONFIG += opengl to a WrapOpenGL target, which links against
either GLESv2 or libGL - just like mkspecs/features/*/opengl.prf
* cmake's FindOpenGL remains in use solely to detect the availability
of desktop gl.
Change-Id: I9315e5ad1fd88e1b7dc7e920053e98fb51fea7fc
Reviewed-by: Volker Krause <volker.krause@kdab.com>
This is less self-contained than what we have, but significantly speeds
up cmake configure/generate runs.
This patch also warns when a feature is already defined.
Change-Id: I8cab63e208ba98756b47d362a39b462f5ec55e20
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
These inclusions are necessary when compiling without pre-compiled headers.
Change-Id: I4345ad3f6882046e4b8f2ba9d315299e280c9f18
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This reverts commit 341bfcd1ea.
As it turns out there might be use cases where we want to have proper
windowing system event integration with glib dispatcher via g_source_attach().
For example with gtk_dialog_run, where GTK blocks in a recursive main loop.
We want to continue dispatcing our windowing system events during this nested
event loop. Not having a proper glib integration can result in rendering issues,
e.g. when resizing parent window via mouse while GTK-based dialog is shown. Can
be seen on examples/widgets/richtext/textedit/ -> Format (from menu) -> "Color..."
The issue from 341bfcd1ea actually should be fixed inside XCB platform plugin,
by improving integration with event dispatcher. That is handled in follow-up patches.
Change-Id: Icabc6d841a554aefbdd460765a3165d22e65f651
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
On later versions of macOS, the font weight trait of fonts is a 64 bit
double, not a 32 bit float, and on macOS 10.14, CFNumberGetValue()
started returning false for values when the type conversion is lossy,
like it is documented to. Therefore, we would end up without weight
information in 10.14.
The fix is to ask for a double instead, which works regardless of
whether the CFNumber represents a 32-bit or 64-bit value.
[ChangeLog][macOS][Text] Fixed font weights on macOS 10.14
Task-number: QTBUG-69955
Change-Id: Ia0577236ddc6b96f9231e6de7b1c49f7f8a837a6
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Reviewed-by: Jason Haslam <jason@scitools.com>
We use DirectWrite to determine whether a font is a color font
or not, so all fonts go through DirectWrite initially. However,
the load call will fail for bitmap fonts, causing us to output
lots of pointless warnings each time such a font was in use.
Instead, we only output this warning if we actually plan to
load the font through DirectWrite later. If the load fails,
we can assume it is not a color font and do not need to output
any warning for this.
[ChangeLog][Windows][Text] Removed confusing DirectWrite warning
when loading bitmap fonts.
Task-number: QTBUG-57180
Change-Id: Iaac8117745ef05a1dff23b346dbe0c6dbfb315f7
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Snap now uses xdg-desktop-portal for portal support. Add check for apps
running in Snap and make them use portals by default. We also should be
using different name for the platform theme used by sandboxed apps.
Change-Id: Ibaa35b7549b3d94775d7edb937f729a300d071b6
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Add override, disable copies where appropriate and use = default
for trivial functions.
Change-Id: Ia5bc7419b1aa053c5503ea7dfaf11cb6dfafd2e2
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Some Pointer Input messages are defined only for Windows 10 and new
versions of the Windows SDK and could break compilation with older
SDKs. Currently, they are not used anywhere outside of the
MessageDebugEntry debug function. Checking if they are defined before
using.
Change-Id: I5fc7bb8e52ab8aca66bb21084289ab8938938063
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
Replace by reinterpret_cast or const_cast, respectively.
Use auto when initializing a variable to fix Clang warnings
about repeating the type name, do minor tidying along the way,
and a few conversions of 0 or NULL to nullptr.
Change-Id: Ieb271a87ddcf064f536e1ff05d23b1e688b1b56a
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
macOS 10.14 uses a new font smoothing algorithm that takes the fill color into
account. This means our default approach of drawing white on black to produce
the alpha map will result in non-native looking text when then drawn as black
on white during the final blit. As a workaround we use the application's current
appearance to decide whether to draw with white or black fill, and then invert
the glyph image in the latter case, producing an alpha map. This covers the
most common use-cases, but longer term we should propagate the fill color all
the way from the paint engine, and include it in the key for the glyph cache.
At the moment we do not react to changes in the application appearance,
as that seems to be buggy in general in Qt (palette/style, e.g.), and those
bugs need to be weeded before we can react to the theme change with confidence.
Task-number: QTBUG-68824
Change-Id: Ibbfd49fcf3a091e454009c08159f46b3499e2bd0
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Add it to configure.json and replace all occurrences of QT_NO_THREAD
with QT_CONFIG(thread). Add conditions for other features that depend
on thread support. Remove conditions where we can use the QMutex and
QThreadStorage stubs.
Change-Id: I284e5d794fda9a4c6f4a1ab29e55aa686272a0eb
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
QUnixEventDispatcherQPA has no private class, there is no need to
declare a fake one.
Change-Id: I615304709fbbea83f6747bb6202dbfd2cc03256d
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Easier than renaming it with a "qt_" prefix everywhere it's used
(it's in a lot of plugins).
Change-Id: Ie01831ddac5446fdbdeefffd15468918f3bc2238
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
fedorahosted seems to be gone and I didn't find a better source for the
data.
Change-Id: Ifb02b9833a735bab4aff2dc7a6db46aedd567583
Reviewed-by: Pier Luigi Fiorini <pierluigi.fiorini@liri.io>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
In Python 3.6 the sorting comes for free, since dict keeps the insertion
order, but adding sorted means older Python versions behave the same.
Change-Id: I3ac4c0f5c3739cb8b284c8a02c4a96b5f41b2286
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Pier Luigi Fiorini <pierluigi.fiorini@liri.io>
The code was quite dubious, in the edid data, the manufacturer is
encoded with a three letter shortcut. In addition it can be set by the
extra data strings, which is not often the case. We would randomly
overwrite the identifier string, so clearly separate the pnpId (3 letter
ID) out and use the fallback table we have.
Also looking up the manufacturer string twice is pointless (contains and
then operator[]).
Change-Id: I18882a78d69b9f3dfc2af31e646ded44f2b70a50
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
The spec gives 13 bytes (5 header, 13 data in increments of 18).
Change-Id: I059590cd750ac403a1f3b44b5f9a0ee300cff5b5
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Pier Luigi Fiorini <pierluigi.fiorini@liri.io>
Replaces the handling of tablet/touchscreen/touchpad/mouse input with a
unified implementation based on the Windows Pointer Input Messages added
to Windows 8. The legacy implementation is still used for Windows 7.
Task-number: QTBUG-60437
Change-Id: I0a0f48ee9d5365f84ba528aa04c6ab1fe4253c50
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
The types have the same size. So it's stupid for it to make the issue a
warning...
qkmsdevice.cpp:737:88: error: format specifies type 'unsigned long long' but the argument has type '__u64' (aka 'unsigned long') [-Werror,-Wformat]
Change-Id: I117816bf0f5e469b8d34fffd153e640b62bef635
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
Newer mouse devices support a so-called "free-scroll" mode, which
unlocks the wheel and allows for faster scrolling. For such input
devices, evdev will report an event value greater than 1, when free
scrolling is active. Examples for such devices would be the Logitech
G700 or MX Master series.
However QEvdevMouseHandler interpreted such an event's data incorrectly
and triggered wheel events for the opposite scrolling direction. This
also often resulted in jittery & jumpy scrolling, when the events'
values alternated between 1 and 2.
Change-Id: Ibb23ed4419d647fff9b90d371d5bb4037cf2bd9b
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
TempFileTemplate is initialized each time an application starts.
It leads to the call of QStandardPaths::writableLocation(QStandardPaths::RuntimeLocation)
which is slow and can even change permissions of the runtime directory.
Use a static wrapper function to initialize this variable only when needed.
Change-Id: Ib620f9b842c88103c67f8dfab200f4d39c9981ee
Reviewed-by: Dmitry Shachnev <mitya57@gmail.com>
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Silence warnings about copying/clearing memory types which g++
considers non-trivial, for example:
windows\qwindowsfontdatabase.cpp:1003:75: error: 'void* memcpy(void*, const void*, size_t)' copying an object of non-trivial type 'class QChar' from an array of 'const ushort' {aka 'const short unsigned int'} [-Werror=class-memaccess]
memcpy(faceNamePtr, faceName.utf16(), sizeof(wchar_t) * nameLength);
qwindowsxpstyle.cpp:946:46: error: 'void* memset(void*, int, size_t)' clearing an object of non-trivial type 'struct ThemeMapData'; use assignment or value-initialization instead [-Werror=class-memaccess]
memset(&data, 0, sizeof(data));
^
qwindowsxpstyle.cpp:1053:38: error: 'void* memset(void*, int, size_t)' clearing an object of non-trivial type 'struct ThemeMapData'; use assignment or value-initialization instead [-Werror=class-memaccess]
memset(&data, 0, sizeof(data));
by introducing a cast.
Task-number: QTBUG-68742
Task-number: QTQAINFRA-2095
Change-Id: I160eb5fc7b64a2bc404e1fa61d306af2662d1252
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>