Removed redundancy in QGraphicsItem documentation.

Snippets [1] and [QGraphicsItem type] are the exact same, each
referenced once, and only in the same file.  Removed the later snippet.

Change-Id: I4f35a8322034b00e9b5f5d6c6d96e652f11f8384
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Fixed small bug in code snippet for QGraphicsItem

If the enumeration "Type" isn't declared in the public scope, it will
cause an issue upon compilation.  Previously, it was ambiguous on which
access level this should be in.  Snippet [18] though has the enumeration
in the correct access level.

Change-Id: If699df80def3e1b09d8d82df74c4ca85eba003d2
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Use categorized logging for ssl code

Place all debug output into the 'qt.network.ssl' category.
This allows people to disable certain warnings at runtime.

Task-number: QTBUG-43173
Change-Id: Ide731fae3109f9cd7730cc096ee069a5b99d35f1
Reviewed-by: Richard J. Moore <rich@kde.org>
doc: Clarify NOTIFY emission with MEMBER variables

Document that NOTIFY signals should be emitted only when really needed,
and that such is the case with MEMBER variables.

Change-Id: Icc38a0790aa43ffe8f24d124da966b4240a41a6f
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Handle SelectionClientClose in QXcbClipboard

QXcbClipboard listens for subtype SelectionClientClose of Xfixes
SelectionNotify event, but doesn't handle it. When the client holding
the clipboard selection closes the Clipboard becomes empty and thus the
change should be emitted.

This fixes downstream KDE Bug #329174.

Change-Id: I19fb8cfd7bd3b249c0bc6ca2a724a9aeeb05ac7e
Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
Reviewed-by: Aleix Pol Gonzalez <aleixpol@kde.org>
Enable input methods for QQuickWidget

Make it possible for widgets to have non-widget focus objects. Since
we cannot add new virtual functions due to binary compatibility, we
have to do it in QWidgetPrivate.

Task-number: QTBUG-42677
Change-Id: I5f74daed2793c1c149bbe02e54ff2f7e2ad1af9e
Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
GL2PaintEngine: Prevent fillInPendingGlyphs from breaking gradients

The glyph cache internally uses the image texture unit when blitting,
but doesn't always activate the unit before binding its texture,
resulting in sometimes binding the glyph cache texture to the
wrong unit.

The image texture unit is also the same as the brush texture unit,
so any time we fill in pending glyphs we need to re-bind the brush
texture, otherwise drawing text with eg. gradients will fail after
the new glyphs have been filled.

The new hasPendingGlyphs() member function of the glyph cache
is an optimization so that we don't need to activate and rebind
unless there are glyphs that need to be filled.

Change-Id: Iac74130145d2d6d7bf95206b5e8a2fc760743cb5
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
GL2PaintEngine: centralize logic for updating/preparing textures

Rewrite of updateTextureFilter to include activating and binding as well,
so that we can maintain a single view of which texture was the last one
to be used from within the engine itself.

The behavior should be the same as before.

Change-Id: I41781d00458b0176c614266f4360db3c68b120a1
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
iOS: Don't scroll screen on changes to input item transform

We auto-scroll the screen to reveal the cursor whenever the cursor rect
changes or other properties of the input methods are updated, but the
expected behavior when explicitly moving an item under the keyboard,
such as when scrolling a view or moving an item using drag, is to
not scroll the screen until typing commences. This matches how eg.
Safari or the Notes app handles the same use-case.

Change-Id: I6b6932d9bcbdccd8df26db982246c162f1574d86
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@theqtcompany.com>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
iOS: Only scroll to cursor on keyboard hide gesture reset if requested

Change-Id: I15b313b5f0d57358e405f16e941fc5061028c6a7
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@theqtcompany.com>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
ANGLE: Do not use std::strlen

This is a cherry-pick from upstream change

e7cfb3dd2029c1bfe5c175ad994c03cac221ad4d

Change-Id: Iefe01545319f9ad268c0c6bf8e8b2181e09d8a84
Reviewed-by: Andrew Knight <andrew.knight@theqtcompany.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
iOS: only clear focus object if it supports IM

We try to keep a on-to-one relationship between UI controls with text input
and keyboard visibility. But if the control does not use text input, then
there is no reason for us to clear focus when the keyboard hides. In fact, we
should avoid doing so, since that will stop e.g buttons from working correctly.

The typical flow is:

- a touch release targeting a button is sendt to QApplication.
- QApplication transfers focus to the button.
- qiosinputcontext gets notified, we refuse, and clear focus again.
- QApplication enters a propagation loop where it tried to
    find out the receiver of the event. Since the button is now
    unfocused, the event will propagate up to a grandparent instead.
- the button will as such not trigger.

Change-Id: I70baa38299f40defc4a77f62790502e2d6ebbba9
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
iOS: let keyboard gesture work better with other gestures

Let the keyboard gesture work better alongside other gestures
by reporting that it should:

1. not prevent other gestures from triggering. This means that
    even if our gesture triggers (we close the keyboard), gestures
    attached to sub-views will still continue tracking.
2. not be prevented by other gestures. This means that if
    a gesture in a sub-view triggeres before our gesture, our gesture
    will still continue to track.

In short it means that regardless of other gestures, we always
close the keyboard if our text responder is first responder and
the user flicks down. And we do so as "silently" as possible.

Change-Id: I22386b5ef5dedbc498a2899929ddd07424e514d8
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
Propagate the source of mouse events

Set the source for mouse events which were caused
by other mouse events.

Change-Id: Ifca1648883ef2b94bb317ed9340759475d350146
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
DiagLib: Add Wheel event to mouse event category of the event filter..

Task-number: QTBUG-42731
Change-Id: Ib0293a245ed430bd86a1ceb221628b3044ad305e
Reviewed-by: Andy Shaw <andy.shaw@digia.com>
Windows: Fix window geometry when using QWindow::fromWinId().

Take margins into account.

Task-number: QTBUG-43252
Change-Id: I816115d2bbbcee3e8663f42bf07b1a140a049e69
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
Windows: Do not register windows obtained by QWindow::fromWinId() for touch.

Fixes a warning:
RegisterTouchWindow() failed for window ''. (Access is denied.)

Task-number: QTBUG-43252
Change-Id: I92a565f3a5e2e8815eb709b5c6d0ccdba7330e31
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
Fix the Apple build version numbers for Clang

A bunch of zeroes were missing. And not to the left.

Task-number: QTBUG-43279
Change-Id: I1a710cf572099547b2ade7b2574a7e0a61649758
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
Fix incorrect QImage transformation when its devicePixelRatio != 1

QImage::transformed compensates for unwanted translation. This compensation
is performed in "pixel space". However, a possible code path to perform the
transformation uses QPainter which is devicePixelRatio-aware and expects the
transformation matrix to be in logical coordinates.

For example, image.transformed(QTransform().rotate(45)) will result in
cropped out image if devicePixelRatio == 2.

Change-Id: I830ff3ffa25531d842dc9c77f1d0e8d4bd502c9d
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
Doc: corrected documentation addOptions()

Task-number: QTBUG-43259
Change-Id: If27c0658f7abaa4ce01de343ce90c14bd911212f
Reviewed-by: Martin Smith <martin.smith@digia.com>