QFileDialog docs: remove misleading sentence about static functions

Native dialogs are used whenever possible, not just when the dialog is
instantiated via the static function.

Task-number: QTBUG-36657
Change-Id: Ibad67114e67f8e2f9956037f8469542c72bfd8ea
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
GTK file dialog: pre-fill the filename if given to a Save dialog

The docs for gtk_file_chooser_set_filename explain that if a file is
new, we should call gtk_file_chooser_set_current_name instead.
(But in that case it is necessary to set the directory separately.)
Qt doesn't make a distinction between a save dialog for saving a
new file vs. a dialog for re-saving an existing file, so it seems this
is the better way to do it all the time, since a save dialog would
most often be used for saving a new file.

Task-number: QTBUG-40573
Change-Id: I285e898fafc54ae39f09d564ca431a279a8f8919
Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
Android: Fix recursion bug in callStaticMethod()

calling callStaticMethod() with template type jlong, jdouble or
jboolean would cause the call to loop indefinitely.

Change-Id: I99caa576e761fdef623ece04e0779e4cf2535592
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
Android: Fix QAndroidPlatformServices::openUrl().

Return true only if an activity was found for the intent.

Task-number: QTBUG-34716
Change-Id: I764caf1e8afa3b17b2d71f52873c17e5d834a956
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
Android: Remove native views when their window is destroyd.

destroySurface() was not removing the native view as they are not
in the m_surfaces map.

Task-number: QTBUG-40159
Change-Id: Ib5457e0bd34141654fa47883f5e125d894b0bd05
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
Windows: Fix stored family name of fallback fonts

When we create fallback fonts, we copy the fontdef of the main font, but
we need to update the family name to match reality, otherwise a QRawFont
created with the font engine will have the wrong family name. This is
already done in the default implementation of loadEngine(), but was missing
from the Windows implementation.

One large consequence of this was that when the distance field renderer
cloned the font engine (to change its size), it would clone it with the
wrong family name. When it later painted its glyph indexes, they would
of course refer to the wrong font (the fallback) so random characters
would appear.

[ChangeLog][Windows] Fixed using QRawFont with fallback fonts, e.g.
in the case of text rendering in Qt Quick.

Task-number: QTBUG-39172
Change-Id: Ic8fcd9dfc20ec7aadf0b47d4a80417f401f355fd
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Check if Start/EndPage returns non-positive value when error checking

StartPage and EndPage are documented to return a non-positive value (0 or
less) when they fail, therefore it is not enough to check if !StartPage.
Checking if is 0 or less is more accurate.

Change-Id: Ia0ff43da4e4309ba0a5983e91a0ad583aad0a955
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Both HiQualAA and normal AA should mean antialiasing in rasterengine.

Change-Id: I1970c96e7681e4059984d837e12f044f138e6d7e
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Uncomment some tests which accidently got commented

With SHA1 47b3ecf3f49933f2a7e3a9dd98f0641d513822bb some tests got
commented out by accident. This re-enables those tests.

Change-Id: If9c7d8a672b66086895a0383fe87d3101fb146fb
Reviewed-by: Mitch Curtis <mitch.curtis@digia.com>
network tests: add manual test for auth / proxy auth

This is helpful to e.g. test an NTLM proxy.
The test server currently does not support NTLM; this test offers a
possibility to specify a proxy server via environment variables.

Change-Id: Iea94656d38424c1d932fc854d13ca15ca47cdd68
Reviewed-by: Richard J. Moore <rich@kde.org>
Document missing QLatin1String methods

Most of them were added before 5.0, but it's ok to just list as 5.0.

Change-Id: I6e83a210a0165659f710d47ed595e9e89d5dbac9
Reviewed-by: Martin Smith <martin.smith@digia.com>
Initialize member.

Change-Id: I9ed8d5a7aeb40886bafbd9eb2003e88e5d796cc9
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Apply upstream patch r1495 to our PCRE copy

It's actually a subset of the patch (tests, docs, other whitespace
fixes were dropped).

Fixes a stack overflow issue on pathological regexps reported upstream:
http://bugs.exim.org/show_bug.cgi?id=1503

Change-Id: If080e4c1e7a86c86459bbbc631c8d8bb3cd7b99f
Reviewed-by: Richard J. Moore <rich@kde.org>
Apply upstream patch r1498 to our PCRE copy

It's actually a subset of the patch (tests, docs, other whitespace
fixes were dropped).

Fixes a stack overflow issue on pathological regexps reported upstream:
http://bugs.exim.org/show_bug.cgi?id=1515

Change-Id: Ie36536e820d79ff842d90efa6bec22b701423793
Reviewed-by: Richard J. Moore <rich@kde.org>
Font Database: Add support for private, system UI font families

We introduce QPlatformFontDatabase::isPrivateFontFamily() to allow
testing for private, system UI font families. Both QFontComboBox
and QFontDialog need to filter out those private font families
which, by definition, should be hidden from the end user.

(The textedit example had to be updated to fix the issue where the
default font would be private. In 5.4, we will be adding an equivalent,
public API in QFontDatabase, and a better solution for the textedit
example and QTexEdit in general).

In particular, on OS X and iOS, private fonts are used for the system
UI font. Those have their font family name prefixed by a dot.
QCoreTextFontDatabase knows about this, and makes sure those are
tested positive as private font families. In order to have a cleaner
layer separation, we moved the QPA theme font resolution from the
platform theme classes into QCoreTextFontDatabase for both Cocoa and
iOS QPA plugins.

In both cases, we use CoreText's CTFontCreateUIFontForLanguage(), that
nicely maps to the HITheme API we were using so far on Mac. That means
one HITheme dependency less. We also cache the font descriptors we get
for these font for each time QCTFD::populateFamilies() gets called.
(While not common, this currently happens in auto-tests, like
tst_QFontDatabase, and could happen in actual applications -- specially
when adding and removing application fonts.)

Change-Id: Ic6f0b60f9f597afee1a43596a669742dc546b97f
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
Fix build with QT_NO_DRAGANDDROP

viewportSizeHint() should be defined outside the QT_NO_DRAGANDDROP ifndef

Change-Id: I7c23c820ea58b3614eb030dc5b0f290ad891ccb1
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Fix build due to missing include when using a minimal config.

QStyle is used, so include it explicitly instead of relying on
indirect inclusions.

Build was broken when using a bunch of QT_NO_ defines, not sure
which one triggers the failure though.

Change-Id: Ib07218521648448576f1b55d2d91d1711c048f09
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Fix rendering alpha-blended text which needs to be clipped at the top.

Task-number: QTBUG-34148
Change-Id: I9c0694e67cc9883db318c1a1558bdf6e08088db4
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
Doc: document that we have unfixed bugs with waitForXxx on Windows

We have to document because we don't know how to fix the bug and don't
know when they will be fixed. We should also disable the unit tests
related to those functions, as they probably cause CI instability.

Task-number: QTBUG-24451
Change-Id: I0e60682ec4af7570258b13735339051ba8f4a6e4
Reviewed-by: David Faure <david.faure@kdab.com>
Reviewed-by: Richard J. Moore <rich@kde.org>
Fix disconnect()ing from signals declared in a base class

Fix disconnection from pointer to member signal that belongs to the base
class, but whose type is a pointer to a member of the derived class.

Commit 9cc106d9d7d951fcf30f4b0f8606afa6b50892ec fixed connect, so apply
the same fix in disconnect

[ChangeLog][QtCore][QObject] Fixed disconnecting from pointer to member
signal that belongs in the base class but whose type is explicitly given
as a pointer to a member in the derived class

Task-number: QTBUG-40638
Change-Id: Ia546fc8f36e1ea0dd0645bdd820aea47f43677ac
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>