The helper in QOpenGLDebugLogger did not account for the extra "KHR"
suffix in the function names and results in a crash when ANGLE is being
used. This commit fixes this issue.
Change-Id: I439d8bfc53b010be5410286b86c090aff171aaef
Fixes: QTBUG-62070
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
CreateCursor only works with standard sizes (32, ...) depending on the
display hardware. No longer apply the scale factor for the blank cursor, because
it might lead to unsupported cursor sizes resulting in random pixels.
Change-Id: I48d84bd913d2dd8f62129126c9a41e58ee2cbcae
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
The sysrootification of QMAKE_INCDIR_OPENGL on macOS must happen only
once. Commit 49ef3773 addressed this but stored the sysrootified
QMAKE_INCDIR_OPENGL in qt_lib_gui_private.pri. For installer packages,
these paths are the paths of the build machine and most likely wrong
on the user's machine.
This reverts commit 4949ef377349ba4dae840c2d5caa36e2d516707baa and
restores the sysrootification in sdk.prf. The original include paths
are assigned to QMAKE_EXPORT_INCDIR_OPENGL and stored as
QMAKE_INCDIR_OPENGL in qt_lib_gui_private.pri.
Fixes: QTBUG-75374
Task-number: QTBUG-73736
Change-Id: I4c0f65866d60660c632363dba3adc7ea2e344bfc
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
QFile::copy() didn't have the syncToDisk() call that QSaveFile::commit()
has. So add it.
[ChangeLog][QtCore][QFile] Made QFile::copy() issue a filesystem-
synchronization system call, which would make it less likely to result
in incomplete or corrupt files if the system reboots or uncleanly shuts
down soon after the function returns. New code is advised to use
QSaveFile instead, which also allows to display a progress report while
copying.
Fixes: QTBUG-75407
Change-Id: I95ecabe2f50e450c991afffd1598d09ec73f6482
Reviewed-by: Henrik Hartz <hhartz@gmail.com>
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@gmx.de>
If this plugin is loaded at some later point during application
run-time, the focus object might be nullptr. We can avoid that by
using qApp->focusObject(), when m_focusObject==nullptr;
Task-number: QTBUG-74465
Change-Id: I0d82410ed557ea1a8fde28a1807f790854951cda
Reviewed-by: Johan Helsing <johan.helsing@qt.io>
Don't go into an infinite loop breaking pages, when an image is about
as large as the page. Correctly take top and bottom margins into account
when calculating whether the image could fit on one page.
Amends change 416b4cf685.
Fixes: QTBUG-73730
Change-Id: Id311ddf05510be3b1d131702f4e17025a9861e58
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Fix warnings
qtbase/src/corelib/io/qprocess.cpp:776: (qdoc) warning: Class CreateProcessArguments has no \inmodule command; using project name by default: QtCore
qtbase/src/corelib/serialization/qcborstream.cpp:1441: (qdoc) warning: Class StringResult has no \inmodule command; using project name by default: QtCore
Change-Id: I1c85ca32aff1f89f70898af7b11cfead96c80349
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
...and other slight modernizations and minor fixes.
Change-Id: Ide587d9fe59ca9113ae775882c99a50debaf9000
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Using getaddrinfo, which implements RFC 6724, implies that addresses
that are not needed will be trimmed. In particular, IPv6 addresses are
often not returned.
Also move the implementation detail documentation down in the text, it's
a detail with little relevance for the usage of the class, but makes for
a good opener regarding this behavior.
Change-Id: I516a64f0b39a6a06621a63c1d5236544b7758049
Fixes: QTBUG-31865
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Otherwise, AppKit, while rendering 'detached' (not in any view hierarchy)
controls and cells will use NSAppearance.currentAppearance, which is not
guaranteed to be the same as NSApplication.effectiveAppearance.
Task-number: QTBUG-74515
Change-Id: I82dcebf2230932ecfcbf33c422a3b7bd0aed61d7
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Keep spinning the main event loop if we can't acquire the semaphore,
this way the Android UI thread can post events on it.
Fixes: QTBUG-74076
Change-Id: Ia87e0535f94c67728176918ab928ff5ce8b00f8e
Reviewed-by: VaL Doroshchuk <valentyn.doroshchuk@qt.io>
There is an effort to make KDE software accessible, which exposed the
missing roles. Check that they are complete with an assert.
Change-Id: Ibaff0a90e1cee316983569ecee7759a13212e3c3
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
When building in a unix style build system (i.e. msys), QMAKE_DIRLIST_SEP
is a colon, not a semicolon. Thus, always split the incoming string
(after the fixup regex) using semicolons on windows.
This matches the code for gcc, further up, which does:
equals(QMAKE_HOST.os, Windows): \
paths = $$split(line, ;)
else: \
paths = $$split(line, $$QMAKE_DIRLIST_SEP)
Change-Id: I6a0175f9d14ae9ca188553483b7868f0549c784a
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
stdcpp-path is needed to set the correct stdc++ library in libs.xml file.
This reverts commit 1366c4f046.
Change-Id: I79b398c5d97c1e98bf503ef7b95b2e9f0f18bc11
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Images in an ico file contains transparency information stored as a 1
bit mask. However, when the depth is 32 bit, it means there is an
alpha channel present, and the mask should be ignored. The Qt ico
handler failed to do that. This has gone unnoticed, since the mask in
such images is typically set to all 0s, and so makes no difference to
the result. But ico files exist that contain junk mask data, so fix
the reader to ignore it properly.
Fixes: QTBUG-75214
Change-Id: I1b4456d71689ec783076a582f2fb215e7dc56e62
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
The full stroker does not produce good results for aliased lines
thinner than 1 pixel. Avoid it by making sure that such thin lines
are painted by the cosmetic stroker, even when they have
non-uniform transformation.
Fixes: QTBUG-73866
Change-Id: I7b5f0fa555903246e0c3fd92cd435cc8c0b15a24
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
The dash stroker did not check for inf/nan coordinates.
Fixes: QTBUG-47887
Change-Id: I1e696cd15cc37d8fcb6a464cac3da33c3a8b95c2
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
We don't support CMake version 2 anymore. Instead of just updating
to a newer (but fixed) version let's link to the latest
documentation. This might create a bigger risk that links get
stale, but hopefully let people find always the latest information.
Task-number: QTBUG-72159
Change-Id: I082de80cf9ee107b5d017ab8ad6369f2448b0e1b
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
QDateTime's short names setUtcOffset() and utcOffset() have been
deprecated since 5.2, in favor of setOffsetFromUtc() and
offsetFromUtc().
QDate's shortDayName() and shortMOnthName() have been deprecated since
5.10, in favor of QLocale's dayName() and monthName(). Also, the
tests that were using them are testing methods only present when the
datestring feature is enabled; so condition them on that feature.
Change-Id: Ibfd4b132523ca8fbc1cb163353a44e0500877fd5
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
The grep given in the help from the program to process the
effective-TLD list only worked for voodoo reasons.
Replaced it with an actually-correct use of grep.
The commands given used the name effective_tld_names.dat in the URL
fetched; however, the relevant file has (for some time now) said
explicitly "Please pull this list from, and only from
https://publicsuffix.org/list/public_suffix_list.dat"
Changed the name used to match that URL.
Revised the output file's suggested name and the instructions for what
to do with its contents, making clear they *replace* what was there
before ...
Fixed some typos and related ugliness.
Change-Id: Iacd186c0003227d657099716262eb3a89c9e5f1b
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
This is a regression introduced by 63967313f5 which blocked signals
on the view, but not on the model.
Change-Id: Ib2f93fe6ef842264aaba200c98ee4a19065ca220
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Reviewed-by: Konstantin Shegunov <kshegunov@gmail.com>
Reviewed-by: Laurent Montel <laurent.montel@kdab.com>
Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
Valid indexes cannot have children, in a table model, so there's no
point in asking the model about it (by calling rowCount and
columnCount).
Change-Id: Ic2d7b52538a7b67acb2c35b26e69bba5956ef5af
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
The provided API uses Xlib types, so it should publicly link with Xlib.
Fixes: QTBUG-75045
Change-Id: Ifea1e8df27cdcc57fb04cd68a7aa1e9fa339c53d
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
If columns are removed and we get notified via layoutChanged, the code
tries to restore old section sizes, and went out of bounds, leading to
an assert in QVector. Simply add an if() to skip restoring out-of-bounds columns.
This comes from https://bugs.kde.org/show_bug.cgi?id=395181,
which translates into the unittest that is part of this commit.
Change-Id: Ide42176a758f87b21957c40508127d67f1d5a2d9
Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
Reviewed-by: Thorbjørn Lund Martsum <tmartsum@gmail.com>
This fixes the "could not parse compiler option" warning when
generating VS project files.
Fixes: QTBUG-75275
Change-Id: Idd98ae5fdb8ebf5a4e311cbb6cd3ed1daba74ca4
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
For gcc's -I and -L arguments a = prefix is replaced by the sysroot.
Since we're resolving include paths and library paths, we have to
support this feature.
For example, the linux-rasp-pi3-g++ makes use of this and is broken
without this patch.
Change-Id: Ie39e63322bd35e2a93aa8e55d52260164b8c6a6b
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
Injected headers were made relative to MODULE_BASE_OUTDIR by syncqt
and made absolute by resolving against REAL_MODULE_BASE_OUTDIR.
This breaks for modules that reside outside the original Qt source
tree (if the directory depth doesn't coincidentally match).
Now, we resolve injected headers against build_basedir, which is
REAL_MODULE_BASE_OUTDIR. To emphasize the equivalence of
REAL_MODULE_BASE_OUTDIR and syncqt's build_basedir, use the former for
syncqt's -output argument.
This commit amends 2aa779e8.
Fixes: QTBUG-70587
Change-Id: I2935d87d7ee681fa4aa795a270b94ab7a43abe59
Reviewed-by: Dominik Holland <dominik.holland@pelagicore.com>
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
If the client of the backingstore fails to pick up dpr changes, and
tries to flush the backingstore without a repaint, we will end up
flushing a back-buffer with a stale dpr. Detect when this happens,
warn the user, and smooth out the situation by adjusting the layer
accordingly.
Change-Id: If4596a8976a3902252c81d8e28c7aeb9fdd908bf
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
We now use QCFType to track the CGContextRef, instead of manually
maintaining the lifetime of the context. A bunch of unused methods
were removed, including completely broken ones like isNull().
Change-Id: Ib5a05aadbf8f228192e74c9a4c8919580b831497
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Makes it possible to build user projects and Qt with C++2a. It is not
automatically upgraded to yet though.
Change-Id: I949ce94871ddc53f21b7265a52b9c0e1370456c8
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
It is 2019, so the name c++17 is more than fixed by now.
At the same time remove an old restriction on using -c++std= with MSVC,
since VS2017 (15.7), we have been able to request c++14 and c++17.
Change-Id: I7129799a2e46301b7ec1322251a3805f4d6b20a8
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
In some build configurations, the build with MinGW would fail due to missing
declaration of localtime_r(). This is only visible when
_POSIX_THREAD_SAFE_FUNCTIONS is defined, which is achieved by including
<unistd.h>. Amends 6c543879a3.
Task-number: QTBUG-71030
Change-Id: I71296f24a450159d1c548e1ad836a2b42e42009f
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
For WM_APPCOMMAND messages that also trigger WM_KEYDOWN/WM_KEYUP, let the
latter messages be handled, instead of stripping them and synthesizing a
press/release from the command code, in order to get the correct scan codes
and autorepeat info.
Fixes: QTBUG-73879
Change-Id: I936cd76be87a76dc6b6223eeb246e4e7aee3a4ac
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Changes QWindowsDropDataObject to only ignore non-CF_HDROP formats when
the drop contains only "text/uri-list" mime data, and the URIs are for
local files, to avoid messing with custom formats set by the developer,
while still fixing the case reported in QTBUG-62662.
Fixes: QTBUG-74232
Change-Id: I946ced222377716876d0aea54b3eb05d40e7fa44
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Add 'source' window offset. This covers the cases where platform
window is created besides one full screen window (like for popups),
where content has qquickwidget / qopenglwidgtet. In that case
fbos/textures from those widgets have offset according to 'source'
window. Note backingstore texture has geometry of 'source' window.
Task-number: QTBUG-69533
Change-Id: I2514b36fd3a6b9b86f51999df1c2b3e9565aafde
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
WebEngine HTML based popups depends on setting Qt::WA_ShowWithoutActivating,
to keep forwarding events to chromium event handling. This works well with xcb,
windows or coca windows backends, however was not respected on eglfs.
Add check before activating the window.
Task-number: QTBUG-69533
Change-Id: I66b249ec497af890c8a2228eee3bac3c806e77ed
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
If the shared context had robustness set then all child contexts must
as well, otherwise we will fallback to a non-shared context breaking
threaded rendering.
Change-Id: Ie5526e632ad21289b6164c1ca06e54ec714187c7
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>