Commit Graph

34762 Commits

Author SHA1 Message Date
Allan Sandfeld Jensen
3dd0308634 Mask potentially undefined alpha in blend_transformed_argb
Makes sure the ARGB32PM that is painted on always have a defined alpha.

Task-number: QTBUG-55645
Change-Id: Ifcf5fcc2127d255518eca4763845a197da6c7914
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2017-12-16 09:23:58 +00:00
Jan Grulich
84731fbb2b Add support for FileChooser flatpak portal
Adds support for FileChooser Flatpak portal. To support them we just do
specific DBus calls, which are then caught and forwarded by xdg-desktop-
portal daemon/service. This is needed for Qt applications running in
sandbox.

[ChangeLog][Platform Specific Changes][Linux] Added support for flatpak
portals. Flatpak is a software utility for software deployment and
package management. It provides a sandbox environment in which users
can run applications in isolation from the rest of the system. To
communicate with the system flatpak uses portals, which are designed to
be a bridge between sandboxed applications and desktop/system running on
user's computer. Flatpak runs this service (called xdg-desktop-portal)
automatically. It exports the portals via DBus and they are visible by
default to all applications running under Flatpak.

Change-Id: I4de1402434ba7cbcc805eab51c30f84f8ba0c5c5
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2017-12-16 08:17:05 +00:00
Morten Johan Sørvig
91aa782f01 QDrag: Allow setting cursor for IgnoreAction
This is especially useful on macOS where the default
ignore cursor is the pointer cursor.

Change-Id: I5e14814abd2d59a7f4c4cd1029829ebbed5b3017
Task-number: QTBUG-26724
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
2017-12-15 16:18:24 +00:00
Sergio Martins
60d99b6413 Rework the "failed to find or load QPA plugin" message a bit
This is one of the most frequent problems users ask for help with, and they
don't even know if the plugin was found but not loaded or simply not found.

Qt knows what happened, so communicate it to the user.

Change-Id: I6003ed4ab3d147a5d159b2002004e53c251cb512
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: David Faure <david.faure@kdab.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2017-12-15 13:54:37 +00:00
Karim Pinter
9fbd9e066e Derive QPpsObjectPrivate from QObjectPrivate
Fixes 5d4089299a commit,
which was causing a build break if qnx pps is enabled.

Change-Id: I8c29f48bde0187a9db02d6325e8a9a0fae760bcb
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
2017-12-15 13:50:13 +00:00
Albert Astals Cid
b4330bc391 Reintroduce the Advanced tab in the QPrintPropertiesDialog
This is mostly a revert of 69de617761 adapted to the new code.

The commit that removed this code said:
 a) there's duplicate settings in the advanced tabs and in the rest of the ui: this easily
    solved with a blacklist
 b) you can set these options in the system settings: probably true, but it is very cumbersome
    to go to the printer settings every time i print to select from which tray the
    paper should be used

Task Number: QTBUG-54464

Change-Id: I7b1cacf51006dadb10aa6e00fe6dd2ff748fe576
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
2017-12-15 13:25:21 +00:00
Morten Johan Sørvig
c10f2aaeb7 Disable WiFi bearer plugins on macOS and Windows
Scanning for WiFi networks is causing network disruptions
in the form of higher latency, sometimes globally
for all running applications.

In practice, the default configuration selection algorithm
in QNetworkConfigurationManager prefers configurations
from the generic bearer plugin, due to the way the
plugins are ordered. Removing the platform WiFi bearers
should have no effect on default network configuration
selection.

Task-number: QTBUG-40332
Change-Id: I778281c41a1aaec1949c220a9266677bd788a57a
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
2017-12-15 12:41:41 +00:00
Morten Johan Sørvig
27f70d7826 macOS: remove existing color-profile handling code
This code is unused/not functional.

Use sRGB everywhere instead. This is not a change
of effective color profile: the backing store has
had the sRGB profile assigned since commit ac899f6d
changed it as a side effect.

Change-Id: Ib45cec3acad90db2a0873b052d6bc4a61c894b18
Task-number: QTBUG-47660
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2017-12-15 12:41:05 +00:00
Timo Aarnipuro
dffa01a438 Add EGLFS integration plugin for Salvator-X on INTEGRITY Multivisor
This plugin uses the Renesas RISP Window Manager.

Change-Id: If813c46ab8d39e966c0a969610841867885dd473
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
2017-12-15 12:27:18 +00:00
Johan Klokkhammer Helsing
034e92b0f4 Android: Set correct input hints when queried through getCursorCapsMode
getCursorCapsMode() now matches the Java implementation in
QtActivityDelegate.showSoftwareKeyboard() which is given to the Android
keyboard on InputConnection creation.

The reason we only saw this bug with some Android keyboards was that many
keyboards never call getCursorCapsMode and just rely on the initial hints.

Task-number: QTBUG-51865
Change-Id: I2aae024d9c77ea14e087e3f51a413d15a684179c
Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
Reviewed-by: Christian Stromme <christian.stromme@qt.io>
2017-12-15 12:23:17 +00:00
Kai Koehne
f2f75c0228 Doc: Fix paths to 3rdparty license files
Fix paths added in 870423f98b. This caused havoc on case sensitive
file systems.

[ChangeLog][Third-Party Code] Fixed glitch in attribution
documentation for Freetype licenses / Qt Gui.

Task-number: QTBUG-65138
Change-Id: Idb20a1ead772337f97a1262da42c62f6aef04a54
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
2017-12-15 09:17:41 +00:00
Morten Johan Sørvig
e739e984c3 macOS: Make retina OpenGL work on VMware
Qt requests full resolution OpenGL surfaces by default.
However, when running as a VMware guest it looks like
the OS silently creates low-resolution surfaces.

This is not possible to detect using the standard NSWindow
APIs for converting to backing coordinates or for
reading the backing scale factor. The result of this
is that Qt will incorrectly display one quarter of
the window content only.

Fall back to detecting if the OpenGL renderer is the
Apple software renderer, which it will be on VMware.
Cancel the high-resolution surface request if this
is the case. This needs to be done while we have a
valid OpenGL context.

Task-number: QTBUG-62357
Change-Id: I33bf12b3bb0408249e6d66e0a8ca86b044bea781
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2017-12-15 08:45:45 +00:00
Thiago Macieira
259acdcb8a qfloat16_f16c.c: inline in qfloat16.cpp if F16C is permitted in there
This is going to be the most common scenario for GCC: all recent
versions allow compiling F16C code in the same source, thus generating
better code.

MSVC is excluded unless AVX is already turned on by the user in the
mkspec file, because it fails to use the VEX-prefixed instructions for
everything else, printing a warning that it knows it should have done
so.

ICC is excluded because it's known to generate invalid code when using
the F16C intrinsics unless F16C is turned explicitly on.

Clang is excluded because it runs into an internal error compiling this
code unless F16C is turned explicitly on.

Change-Id: I57a1bd6e0c194530b732fffd14f58de6a46f0de1
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
2017-12-15 07:39:54 +00:00
Timo Aarnipuro
039ac7d20c Add mkspec for INTEGRITY Multivisor on the Renesas Salvator-X
Change-Id: Ie8d2f5c022a6a2396534cebf1f17cbb8df92cb27
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
Reviewed-by: Kimmo Ollila <kimmo.ollila@qt.io>
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
2017-12-15 07:01:54 +00:00
Morten Johan Sørvig
0b4b864d83 Remove testQuitLock from BLACKLIST
Follow-up to d044b0b, with claimed to remove it but
didn’t.

Change-Id: Ifeeb6b062c7c41f1914d677e8aa20e4cb9378ac9
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2017-12-14 21:07:39 +00:00
Tor Arne Vestbø
fddc5a27b1 macOS: Enable using CoreGraphics helper functions from C++ sources
Change-Id: If32c96d224bfb90ba22661b6f5ac3c920acb39d2
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
2017-12-14 19:35:38 +00:00
Jake Petroules
dc0bb57f86 Fix an issue causing asset catalogs to be miscompiled with iOS simulator
This works around the inability to build iOS apps for a "generic"
simulator by explicitly setting the Xcode build setting
ENABLE_ONLY_ACTIVE_RESOURCES to NO in order to ensure that all variants
of assets in an asset catalog are built when targeting iOS simulator
devices. Otherwise, we will simply build for whatever the first
simulator in the list happens to be. If the application is then deployed
to a different simulator, some of the assets needed for that device
variant may be missing.

This "helps" QTCREATORBUG-19447 but is not a workaround since this fix
is necessary for command line builds anyways, even though it's unlikely
to crop up in practice there, since one would have to manually deploy
the built application bundle to the simulator using simctl rather than
going through Xcode (which would rebuild for the appropriate device).

Change-Id: Ia41c48dcc715fe79a2c50db66a0ca7a1fea159c2
Reviewed-by: Vikas Pachdha <vikas.pachdha@qt.io>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
2017-12-14 19:00:43 +00:00
Friedemann Kleint
1adb1ef6ba QStyleSheetStyle: Draw menu item also when font is set
Task-number: QTBUG-64055
Change-Id: I0674e7b43bb56aa1834c8df10794714dbcc4e5e3
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
2017-12-14 18:23:35 +00:00
Friedemann Kleint
9e1b6b6e53 QFileSystemModel: Enable experimental code path for per-file watching
QFileSystemModel had a #ifdefed out experimental code path for watching
single files to track changes in size, which got outdated over time.

Replace the #ifdef 0 by a check for the environment variable
QT_FILESYSTEMMODEL_WATCH_FILES, fix it up and apply some fixes to
related code to make it work:
- Split file names signaled by QFileSystemWatcher on '/' always.
- Do not instantiate QDirIterator on "", which means "current directory"
  and results in mixed-up directories.
- Check on lastModified() in QExtendedInformation::operator==() so
  that changes trigger an update in _q_fileSystemChanged().
- Fix the #ifdefed out part to compile and not to add directories
  to the watcher.

[ChangeLog][QtWidgets][QFileSystemModel] It is now possible to enable
per-file watching by setting the environment variable
QT_FILESYSTEMMODEL_WATCH_FILES, allowing to track for example
changes in file size.

Task-number: QTBUG-46684
Change-Id: Ia5da9170866416c9529251f889814b23d7a7d069
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2017-12-14 18:23:22 +00:00
Giuseppe D'Angelo
00c09e752f QAbstractItemModel: add more checks in begin{Insert,Remove}{Rows,Columns}
Check that the inserted/removed range is indeed valid.

Change-Id: Ifccbe13f0753252ee1450c8668df782dc699f05b
Reviewed-by: David Faure <david.faure@kdab.com>
2017-12-14 18:15:50 +00:00
Oswald Buddenhagen
81b5155e82 fix "make clean" of qmake in a builddir with spaces on mingw
Change-Id: Ice61a11250694afa66f263fa79a74ff9642ef285
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2017-12-14 18:06:31 +00:00
Oswald Buddenhagen
7830cdd833 configure: during early setup, skip all of default_pre.prf
... instead of only toolchain.prf.
the license check could go haywire, and everything else that file does
is meaningless in configure context anyway.

Task-number: QTBUG-63452
Change-Id: I5e31c87fe717fda40978c0317556070637e537e2
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
2017-12-14 18:06:07 +00:00
Oswald Buddenhagen
0a8a759822 fix namespaced build
Change-Id: Ibd16658ef800afe1dec01311cc4ef1a9a6d83929
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
2017-12-14 18:05:59 +00:00
Oswald Buddenhagen
fb326ae126 qmake: print compiler output if detection phase fails
helps enormously with debugging.

Change-Id: Ic8876e74a4dbb14006d8b48658eb141a3f0e0fbf
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2017-12-14 18:05:53 +00:00
Oswald Buddenhagen
e291f67743 unbreak plugin dependency tracking
use the correct operator.
amends 623b191c10.

Change-Id: Ice8b2a82b1c7828587cccc7d464f9313e176d536
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
2017-12-14 18:05:28 +00:00
Oswald Buddenhagen
5dd76ba31c update sqldriver docs
- adjusted to new configure system realities
- centralized 'make install' instructions
- fixed 'make' command for mingw
- externalized the license compatibility question
- removed dated information about postgresql client libs
- removed dated claim that freetds is not stable yet
- updated official sybase client link to point to sap support
- removed apparently bogus "demo" include path from oci instructions,
  based on the archive content description
- removed troubleshooting item about static builds - one can use static
  "plugins" with a static build just fine. and building dynamic plugins
  for a static build is plain impossible to start with.
- removed troubleshooting item about build key mismatch, as build keys
  have been removed in qt5
- removed "general info" sub-section titles, as that's bad style
- misc language and minor content fixes

Task-number: QTBUG-62479
Change-Id: Ic4efa9e20a5966b6fc646062aec6d1a8d4ff4158
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2017-12-14 18:05:12 +00:00
Oswald Buddenhagen
ff1c8baf4a configure: make cached results immediately available
otherwise test de-duplication between modules doesn't work.

Change-Id: I2c6222d853108df223758aa8907dc8d004efd87f
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2017-12-14 18:02:36 +00:00
Oswald Buddenhagen
fd3423bfb8 configure: support discarding selected test results with -recheck
especially during debugging, it is often necessary to re-run only one
(or a few) tests, where -recheck-all would be wasteful.

Task-number: QTBUG-64059
Change-Id: I9410894dec4289ff832d7f75e04f9b60fe76c57c
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2017-12-14 18:02:30 +00:00
Paul Olav Tvete
af70d4ee85 Allow empty namespace URI
W3C Namespaces Standard states that "The attribute value in a default
namespace declaration MAY be empty" (secion 6.2). Analysis and fix
thanks to Eugenio Rustico.

Task-number: QTBUG-63538
Change-Id: Icd8d4df639b9737d8e0d215bf2bea56fe1e161ac
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2017-12-14 16:53:30 +00:00
Jesus Fernandez
345be58100 Fix assert when emitting a signal from a different thread
If a signal is emitted more than once in a multithreaded application the
QSignalEventGenerator::execute function asserts in the check for a valid
signal index. It happens after abandoning the state and all the
connections are disconnected. If we have pending signal to be
processed the QObject::sender() won't be able to resolve the sender
object.

Task-number: QTBUG-61463
Change-Id: I9d4b7266c6dddc9ff2e7453b05a6989876ccb332
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2017-12-14 16:30:38 +00:00
Martin Smith
c87ed145f1 doc: fix signatures and missing module headers
The update adds the moduleheader variable to the qdocconf
file for qttestlib.qdocconf and qmake.qdocconf. The problem with
qmake is that it doesn't have a module header file, but it does
have qmake_pch.h, which is used here. This update also corrects
several \fn commands in the qttestlib docs.

Change-Id: I2202b9db96390bac1ee491ca8a99ca9010057ce3
Reviewed-by: Martin Smith <martin.smith@qt.io>
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
2017-12-14 13:37:51 +00:00
Marc Mutz
5cb54cb5eb QPlatformPrintDevice: use QVector, not QList in the API
QPlaformPrintDevice uses QVector to store, but QList in the getters to
retrieve these data. Port API from QList to QVector to avoid
conversion between the two containers on every access.

Saves almost 4KiB in text size (another 0.9% of QtPrintSupport).

Change-Id: If33df141b87753803c45d9f4dae501a68abe49af
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2017-12-14 13:35:35 +00:00
Marc Mutz
2356c173b2 QPlatformPrintDevice: store QPageSize/QMimeType/int in QList, not QVector
This commit pains me, because we want Qt to migrate away from QList,
but the QtPrint API stack (all the way to public API, for QPageSize,
and int) is formulated in terms of QList, not QVector, so it makes
zero sense to store data in QVectors just to convert to QList on every
opportunity.

Store QMimeType in QList, too, since that's what QtCore uses.

Saves 3KiB in text size (0.7% of QtPrintSupport).

Change-Id: I71249f60be517cc06973b38d9ccad7a31f348be3
Reviewed-by: Albert Astals Cid <albert.astals.cid@kdab.com>
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2017-12-14 13:35:32 +00:00
Tor Arne Vestbø
d48c502ce5 Share QWidget update and repaint code for QRect and QRegion
QWidgetBackingStore::markDirty has an optimization for QRect, so we don't
want to unify these two functions by calling update/repaint(QRegion(rect)).

Change-Id: Id2a42f478f71863da45697041e0ab0130c74b9d2
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
2017-12-14 13:11:51 +00:00
Tor Arne Vestbø
3d65284b60 QWidget: Remove dead code for handling painting without a backingstore
Change-Id: Iacf852c8620ea06d790cddcf6774b772f754e08a
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
2017-12-14 13:11:43 +00:00
Andy Shaw
9832f0ab85 Copy argv[0] to prevent it pointing to invalid memory later
If QCoreApplication is recreated, it is possible the previous argv[0]
pointer has become invalid, so we should not rely on it. So to prevent
that, we copy the original argv[0] to a static QByteArray.

Task-number: QTBUG-58919
Change-Id: Idadd4cb78e4281830165fb681ea7925109f316ff
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
2017-12-14 09:39:40 +00:00
Jake Petroules
6a2609f379 Stop blocking the ability to generate dSYM debug symbols with Xcode
In Xcode, the default value for GCC_GENERATE_DEBUGGING_SYMBOLS is YES,
which causes Xcode to emit debug symbol bundles (.dSYM) on macOS and iOS
*if* DEBUG_INFORMATION_FORMAT is also set to dwarf-with-dsym. Since that
setting is already set to an appropriate value with debug vs release
builds, the default Xcode value for GCC_GENERATE_DEBUGGING_SYMBOLS is
already correct and in effect the only thing qmake was doing was always
setting GCC_GENERATE_DEBUGGING_SYMBOLS to a wrong value for release
builds - it should be YES in all cases, to allow the .dSYM bundles to
be generated in release mode, which is in fact the only case where
they're really needed in the first place.

Task-number: QTBUG-41246
Task-number: QTBUG-50896
Change-Id: I07639a3c4ff9f62d591cde3ad66748767d475e3b
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2017-12-14 09:39:16 +00:00
Eskil Abrahamsen Blomfeldt
ff2ae36551 Windows: Support application fonts as fallbacks
In order to support the generated EUDC.TTE font for
End-User Defined Characters on Windows, we need to allow
fallback fonts which are not part of the default font
collection. This is the same as change
21c7421d4e, but adapted to
the fallback font code path.

Without this change, the EUDC file would still be loaded,
but it would be loaded through the GDI fallback, and we
would display an error message on the console.

Task-number: QTBUG-44594
Change-Id: Id2404228c7fd345523e4e5c99f31862e256930e3
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
2017-12-14 09:01:45 +00:00
Timur Pocheptsov
2086c183c1 Fix/workaround a quirk in SecureTransport
We set anchors from QSslConfiguration::caCertificates. On macOS these
anchors are by default copied from the system store, so I expected
setting 'trust those anchors only' should not break anything.
Somehow, on 10.11 SecTrustEvaluate fails to evaluate a valid
certificate chain (apparently because it has an intermediate
certificate, it's just a guess, since their API/docs are too poor
to explain well what was the real cause) as I can see connecting,
for example, to google.com - we have a chain with a valid root,
say it's GetTrust CA and we have it also in our list of anchors we set
on trust, but evaluation fails with: kSecTrustResultRecoverableTrustFailure:

"This means that you should not trust the chain as-is, but that
the chain could be trusted with some minor change to the evaluation
context, such as ignoring expired certificates or adding an
additional anchor to the set of trusted anchors."

Since none of certs is expired, and the required anchor already set,
this must be some bug in SecureTransport. For macOS (deployment
target) < 10.12 we fallback to the original version of the code
(the one that unfortunately does not allow us to limit the set
of trusted anchors by what client code wants to trust).

Change-Id: Ie42fd77c3eb6ef7469812aa0d7efff88a003c0b8
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2017-12-14 04:54:35 +00:00
Gatis Paeglis
9dc7904556 xcb: update libXi version requirement in the README file
... from 1.7.4 to 1.7.5 (released Sep, 2015).

Some more locking issues were fixed after 1.7.4. Testing
for a prolonged period of time has showed that 1.7.5 does
not cause a system lock-up.

[ChangeLog][Platform Specific Changes][X11 / XCB] Minimal libXi
version requirement has been updated from 1.7.4 to 1.7.5. This
is because XIAllowTouchEvents is known to deadlock with libXi 1.7.4
and earlier. When touch events are never received, this is not
an issue. Plain mouse / keyboard systems are not affected.

Task-number: QTBUG-62224
Change-Id: Ie70264b9af0390df33c417f660350d4bce48c6d3
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
2017-12-13 22:50:33 +00:00
Tor Arne Vestbø
ba44cdae38 Teach QPlatformWindow about safe area margins and implement for iOS
The safe area margins of a window represent the area that is safe to
place content within, without intersecting areas of the screen where
system UI is placed, or where a screen bezel may cover the content.

QWidget will incorporate the safe area margins into its contents margins,
so that they are are never smaller than the safe area margins. This can be
disabled by unsetting the Qt::WA_ContentsMarginsRespectsSafeArea widget
attribute, which is set by default.

QLayouts will automatically use the contents area of a widget for their
layout, unless the Qt::WA_LayoutOnEntireRect attribute has been set. This
can be used, along with a contents margin of 0 on the actual layout,
to allow e.g. a background image to underlay the status bar and other
system areas on an iOS device, while still allowing child widgets of
that background to be inset based on the safe area.

[ChangeLog][iOS/tvOS] Qt will now take the safe area margins of the
device into account when computing layouts for QtWidgets.

Change-Id: Ife3827ab663f0625c1451e75b14fb8eeffb00754
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
2017-12-13 20:47:15 +00:00
Lars Knoll
59febb49e4 Fix a bug in the generation of the Unicode joining property data
The code that was supposed to initialize the joining property of
characters to the correct defaults was actually applied after reading
in the data from the Unicode file, and was in a couple of cases
overwriting explicitly specified data in ArabicShaping.txt

Task-number: QTBUG-63191
Change-Id: Ie35261039b2211a827322ca11afacd9555ccefc7
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
2017-12-13 19:14:49 +00:00
Edward Welbourne
99b1253101 Kludge round MS TZ APIs' lies breaking a test
Commit 68bcccac took account of MS TZ APIs mis-describing non-DST
zones making changes to standard offset (e.g. Europe/Samara in 2011 at
the end of October); however a DST transition that coincides with an
equal and opposite change to standard offset, while the other end of
its DST period changes normally, ends up looking exactly the same
(although it's nominally subtly different), in MS's APIs.  Thus fixing
the more common case broke this more obscure case; there is no way to
fix this (other than not using MS's broken-by-design APIs).  So kludge
the test to skip the bit we know this breaks.

Task-number: QTBUG-64985
Change-Id: I068500e2e783ab72b400bfd6dbb7dbbd5b08a7bc
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2017-12-13 18:51:29 +00:00
Johan Klokkhammer Helsing
13f09acb66 Make tst_QOpenGLWindow pass on platforms where the default FBO != 0
The test would fail on Wayland with window decorations enabled because there
window content is drawn to an FBO before it's blended with the window
decorations (also drawn by the client).

Task-number: QTBUG-51741
Change-Id: I7c74ad235c6a2d50231a9f863da1810675dd4eae
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
2017-12-13 15:00:02 +00:00
Eskil Abrahamsen Blomfeldt
9e99dba4a2 Windows: Add font fallback for EUDC glyphs
EUDC, or "End-User Defined Characters", is a concept in Windows,
where the end-user can create a local fallback font of default
glyphs for the PUA (Private Use Area, a range of Unicode
not reserved to any writing system), and these glyphs will be
used when displaying the character using a font which does not
itself support the code point.

To support this in Qt we look up the default EUDC font in the registry
and add it to the fallback fonts if it is available. We use the
font for code page 1252. This has been tested on a couple of systems,
and appears to always be present. The font is added to the front of
all fallback lists, so that it will override other fallbacks,
such as Segoe UI Symbol, which happens to assign glyphs to the PUA.
If there is no end-user defined fallback, then Segoe UI Symbol will still
be used as before.

Note that this required a small change in the code to get canonical
font names. The EUDC font that Windows generates will only have a
name set for the current locale, and we expected all fonts to have
an English name. Instead, the code has now been changed to prefer
the English name if one is present, but accept any other name if
there is nothing in English.

[ChangeLog][Windows][Text] Added support for End-User Defined Characters
in Qt.

Task-number: QTBUG-44594
Change-Id: I83ae68b6d16e9b50e990dfb3ac3d294b7b2a5113
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2017-12-13 14:42:50 +00:00
Oliver Wolff
457fe3e8e2 ANGLE: Fix resizing of windows
Use the correct height/width values when calculating
the vector for resizing the window content and the
new size as viewport size.

Task-number: QTBUG-62475
Change-Id: I33a8dc1379a908e991b04bc31dfc6254a6d005c9
Reviewed-by: Andre de la Rocha <andre.rocha@qt.io>
Reviewed-by: Miguel Costa <miguel.costa@qt.io>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
2017-12-13 13:07:52 +00:00
Oliver Wolff
27c840f5d4 Fix typo
Change-Id: If6111c59b958ba03f6ec5966af5cf443cae5cf9b
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2017-12-13 13:07:48 +00:00
Marc Mutz
27aacfb61e QString: fix documentation of NUL-termination of unicode(), data(), constData()
(or lack thereof).

* `QString::utf16()` reallocates if `*this` has been constructed using
  `fromRawData()`.

* `QString::data()` ensures a writable string, so will detach from raw
  data.

* `QString::unicode()`, `constData()`, and `data() const` do not. They
  just return `QStringData::data()`, which may point to raw,
  non-NUL-terminated data.

These functions can therefore not possibly have the same behavior, but
were documented the same.

Fix.

Also drop the discussion of operator[](size()), as that, too, was not
correct, and anyone who indexes with op[] beyond size() - 1 should not
rely on proper behavior.

[ChangeLog][QtCore][QString] QString::unicode(), constData() and
`data() const` do not return a NUL-terminated string. This was true
before, but the documentation claimed the opposite.

Change-Id: I1437f57cd02bdf80264e8559608b46aa749c23a8
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2017-12-13 10:55:59 +00:00
Oswald Buddenhagen
91996d4ec4 Bump version
Change-Id: I752089caa4f2a0cb91d1c4bfa2c53fe25b6bb34e
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
2017-12-13 10:53:55 +00:00
Allan Sandfeld Jensen
ae55e75b1b Paint text decoration where the text is
For multi text-item texts we should render the text decoration at the
same position as the text-item part is, and not always from the
beginning of the line.

Task-number: QTBUG-60422
Change-Id: I9aa58fc164122ad1fae9716b8b18bdfbbbd778a9
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
2017-12-13 08:43:39 +00:00