Commit Graph

15666 Commits

Author SHA1 Message Date
Oto Magaldadze
e913972d52 added QAbstractSpinBox::setGroupSeparatorShown function.
[ChangeLog][QtWidgets][QAbstractSpinBox] QTBUG-5142 - This will
allow a group (thousand) separator to be shown in QSpinBox
and QDoubleSpinBox widgets.

Task-number: QTBUG-5142

Change-Id: I2e23f5f83c93bb092a2dbd784e06d17d40d42909
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
2013-10-29 12:12:16 +01:00
Marc Mutz
fc5d07cee3 QLCDNumber: remove unused header #include
Change-Id: Ic1608a11a48c373b7ad816c1305cce0fe236425b
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
2013-10-29 12:11:54 +01:00
Roger Maclean
e65f568a8f Improve mapping between Font Config and Qt font attributes
It was sometimes impossible to select the desired font due to the code
completely ignoring the FC_WIDTH attribute and poor mapping of the
FC_WEIGHT attribute. The result was that it was easy to have a font file
that was inaccessible by Qt since it shared attributes with another
font file.

The FC_WIDTH attribute is now fetched and used unchanged as the font's
stretch value other than ensuring it is within the allowed range.

For FC_WEIGHT, the code no longer matches the value with the closest
QFont::Weight enum but instead does a piecewise linear mapping so
that Qt enum values match Font Config ones to the extent possible.

Also removed bogus call to fetch the width that was doing nothing with it.

Change-Id: Id39715f14a617c1d0e00ecf5a7d391cab99adc03
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Reviewed-by: Fabian Bumberger <fbumberger@rim.com>
Reviewed-by: Bernd Weimer <bweimer@blackberry.com>
Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
2013-10-27 23:51:16 +01:00
Marc Mutz
7f1017931c Add empty dist/changes-5.3.0 file
Change-Id: Iea2f6bb3b1d5c922167c4e96c825c08db9aa1b4e
Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
2013-10-26 00:39:51 +02:00
John Layt
041abb9316 QPrintSupport: Move QAbstractPrintDialog test into QPrintSupport
Move the test for QAbstractPrintDialog from widgets into printsupport

Change-Id: Ia7595fa650a7ad565df3090207500ed06564e842
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
2013-10-26 00:39:51 +02:00
Roger Maclean
10014e0831 Add configuration for building with imf support on QNX
Avoid need to modify qnx.pro in src/plugins/platforms/qnx to
build with imf support.  By default detects if necessary headers
and libraries are available.  Can also be explicitly requested or
disabled with -imf and -no-imf options.

Change-Id: I3f9780fc189a33e4c93fb4f950111121f8e947c3
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
2013-10-25 20:17:40 +02:00
Roger Maclean
db98b052ac Add support for BB10 input method framework
Added input method support for the BB10 variant of Qt to the extent
possible using standard Qt APIs.  This adds support for text predictions
and entry of languages such as Chinese.

Change in interface to QQnxAbstractVirtualKeyboard was made because it
is felt the new one is slightly nicer.  It doesn't appear safe to
assume the focus object has a particular property and in fact in my tests
the code failed to work.

In some cases the code uses variable and function naming at odds with
normal Qt coding standards.  This has been done for functions called
and data provided by the BB10 input system as for those of us who
need to maintain such things, it makes their meaning considerably
clearer.

While qqnxinputcontext_imf.cpp was used as an initial base for
development one can consider the new version as largely new code. I
don't believe the original version was ever complete and in any event
would not compile.

Change-Id: I09470801ffa237cee67da40c0b3d02ed5c77531e
Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
2013-10-25 20:17:21 +02:00
J-P Nurmi
1f22c1d981 Introduce QTextDocument::baseUrl
Required for QQuickText & friends to implement image resource handling
in a clean way - to get rid of QQuickTextDocumentWithImageResources and
eventually make QQuickTextEdit's document interchangeable.

Change-Id: I97314a6c3e2d5726539d5722795a472631388cb0
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
2013-10-25 14:18:05 +02:00
Oliver Wolff
2ced0cb08d Clean up common winrt/winphone mkspec
Change-Id: I010bf977e01fab2f39184bbe730ec70128cc2982
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
2013-10-25 09:19:01 +02:00
Andrew Knight
07ee43142b qmake: Support MSVC2013 for WinRT builds
Change-Id: I1c102f0b029616997d72933a90c0f9a2a3a9e222
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
2013-10-25 09:00:37 +02:00
Oliver Wolff
c241e4aa49 WinRT: Added msvc2013 mkspecs
Change-Id: I052f6ba19056e7c0df6d7ea5548eb4dac4db125e
Reviewed-by: Andrew Knight <andrew.knight@digia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
2013-10-25 09:00:35 +02:00
Frederik Gladhorn
840f6a40e6 Merge remote-tracking branch 'origin/stable' into dev
Change-Id: Ie56539b2e0be611a363b5f15ae5412a78d6945a2
2013-10-24 12:48:42 +02:00
Kai Koehne
2e3870fe37 Reserve some space for future use in QLoggingCategory
Currently Qt offers only debug, warning, critical message types for
general use. Most logging frameworks offer more ... let's save
some space for future message types.

Change-Id: Icb4333da5c8f5277fd10d8a01b06d95369662bdc
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2013-10-24 10:18:26 +02:00
Sean Harmer
6d3e821349 Remove doc references to non-existing functions in QSurfaceFormat
Change-Id: I5a9de5b719e111e47a1ea7334609695f1db6149a
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
Reviewed-by: Gunnar Sletta <gunnar.sletta@digia.com>
2013-10-24 00:32:08 +02:00
Jonathan Hoffmann
5cc76dae7e BlackBerry: improve BPS event lifetime management
In QEventDispatcherBlackberry::select(), if an event handler called
through filterEvent() starts a nested event loop by creating a new
QEventLoop, we will recursively enter the select() method again.
However, each time bps_get_event() is called, it destroys the last
event it handed out before returning the next event.  We don't want it
to destroy the event that triggered the nested event loop, since there
may still be more handlers that need to get that event, once the
nested event loop is done and control returns to the outer event loop.

So we move an event to a holding channel, which takes ownership of the
event.  Putting the event on our own channel allows us to manage when
it is destroyed, keeping it alive until we know we are done with it.
Each recursive call of this function needs to have it's own holding
channel, since a channel is a queue, not a stack.

However, a recursive call into the select() method happens very rarely
compared to the many times this method is called.  We don't want to
create a holding channel for each time this method is called, only
when it is called recursively.  Thus we have the instance variable
d->holding_channel to use in the common case.  We keep track of
recursive calls with d->loop_level.  If we are in a recursive call,
then we create a new holding channel for this run.

Change-Id: Ib3584676d2db5a9a3754a1535d5fb6c9e14f5dbb
Reviewed-by: Thomas McGuire <thomas.mcguire@kdab.com>
2013-10-23 19:09:54 +02:00
Wolfgang Bremer
fe61f2d6b2 Rename BlackBerry arm mkspecs to be aligned with NDK structure
The current NDK uses CPUVARDIR variable to define whether x86 or armle-v7 is used.
Therefore, the whole structure uses these two definitions to separate simulator
and device builds. Renaming blackberry-armv7le-qcc to blackberry-armle-v7-qcc
allows to directly use CPUVARDIR during Qt5 builds.
For compatibility reasons the old folder is kept and includes the new qmake.conf.

Change-Id: Ia7feeeabe16eda48140a65178af28cbb9bd085a9
Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
2013-10-23 19:09:54 +02:00
Friedemann Kleint
d8745d249f Windows: Handle WM_SYSCOLORCHANGE as theme change.
Task-number: QTBUG-34170

Change-Id: I6ca11ab67c1e2752300fc167fb8f3c4f0d9ae2b8
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
2013-10-23 19:09:54 +02:00
Friedemann Kleint
7c1b39705c Fix crash in QXcbDrag.
handleStatus() was called with drag==0 when releasing the mouse over the
desktop.

Task-number: QTBUG-33920
Change-Id: I553647d1e734934b7c6caf4c984683cff88f9162
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
2013-10-23 19:09:54 +02:00
Kai Koehne
17809b41a6 Fix typo in check for MINGW_W64 version
Got introduced in 9b187bcd6a256b53cc2fb85500

Change-Id: I1d713f8309d3d8568ea836cc1d29f9dca685ac01
Reviewed-by: Jonathan Liu <net147@gmail.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
2013-10-23 19:09:54 +02:00
Venu
e55ecc4a55 Doc: Added a link to the Qt Quick Test page
Task-number: QTBUG-33316
Change-Id: Ib8c479837cac4b7cca47b979cbb2dad0aaae6412
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
Reviewed-by: Caroline Chao <caroline.chao@digia.com>
2013-10-23 19:09:54 +02:00
Shawn Rutledge
7e30d3afd3 QFileDialog can delete files too, not just directories
After Ic12de12ec51c20de52d040514e90be5e783add43 this functionality
was broken.  Added an autotest.

Task-number: QTBUG-34159
Change-Id: I8f41b7073dc57fea855ab87796f09e8a91520d13
Reviewed-by: David Faure <david.faure@kdab.com>
2013-10-23 19:09:54 +02:00
BogDan Vatra
483a9d83f0 Don't crash if the platform plugin is not initialized
Change-Id: I999411816192edbd2bf40c6bda92d6e94fb3d1b0
Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
2013-10-23 14:08:36 +02:00
Oswald Buddenhagen
f3785471b7 de-duplicate QT_MODULES
Change-Id: I8f1bf08070abb1ba05a4fdb14e7de9e7da5b3ec7
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
2013-10-23 13:43:27 +02:00
Oswald Buddenhagen
7d462a2fb4 return()-related break() insanity is not necessary in qt5
Change-Id: I593c7160e44d51d25dee76c56c2e5580345ab42a
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
2013-10-23 13:43:23 +02:00
Oswald Buddenhagen
a0a0b6446c don't suggest to use qtAddModule(), it's internal API
Change-Id: Idf01d0dd74a0708014b7fca33611535c604a75f9
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
2013-10-23 13:43:19 +02:00
BogDan Vatra
0096264800 Fix deploy mechanism.
The order of "android:value" and "android:name" attributes can be changed when
saving the XML document. Use placeholders instead.

Change-Id: I9a97bb0df2d2d16c8a9443a21ce7d3290e0ab466
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
2013-10-23 13:23:12 +02:00
BogDan Vatra
744a201853 Move untranslatable stings to AndroidManifest.xml
strings.xml file is used to store strings that can/should be internationalized.

Change-Id: I2fc305b6917752e9f502bd4beb172205ba4f9fba
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
2013-10-23 13:22:57 +02:00
Gunnar Sletta
cbcfbd798f Rely on isLayered() to decide layering
The logic here was a bit broken. Every QWindow has an opacity
which is 1 by default so the expose was hit for every single
window, regardless of it being layered or not.

Change-Id: I04873cd5db1cd147708e7de140f5947d3a01e9e1
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
2013-10-23 13:15:54 +02:00
Jonathan Liu
5d8a882c11 Fix misaligned selection region with text when centered
If the text is centered, the x/y position in the selection QRectF may
be a multiple of 0.5 which is rounded up. This rounding causes
misalignment of the selection region with the text.

The alignment is fixed by using qFloor on the x and y components.

Task-number: QTBUG-34218
Task-number: QTBUG-34234
Change-Id: I4f2fadeb38602f62a93773c6e5faecf03b28069f
Reviewed-by: Gunnar Sletta <gunnar.sletta@digia.com>
2013-10-23 10:54:44 +02:00
Paul Olav Tvete
aa7fa09312 Android/LinuxFb: fix QWidget::showFullScreen()
Previously, showFullScreen() had a race condition: it depended
on QFbScreen::setGeometry() being called after the window state was
set (that would trigger QPlatformScreen::resizeMaximizedWindows(), which
was the only part of the code that reacted to WindowFullScreen).
On Android this caused random behaviour.

Task-number: QTBUG-33294
Change-Id: I228e6af4139af1a47387e7d80757d7b46e859580
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
2013-10-23 10:19:10 +02:00
Paul Olav Tvete
bd3f3f31bf Android: Make platform menu more robust
Don't crash and lock up the whole device when people try to
remove menu items that don't exist.

Task-number: QTBUG-34246
Change-Id: I4396d252c5af93e021c9e218dbab7c0e7f190d9d
Reviewed-by: BogDan Vatra <bogdan@kde.org>
2013-10-23 10:18:45 +02:00
J-P Nurmi
a83983d861 QTextHtmlParser: restore the default link color from app palette
The default link color used to be resolved to the link color of the
application palette, but got lost during the Qt 5 modularization (see
commits 7351a43 and 3f9a7f9).

Task-number: QTBUG-28998
Change-Id: I7f07427f6c03f83c557100938ad9f7a39349d303
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2013-10-23 00:01:44 +02:00
Tasuku Suzuki
109bf980b3 Fix a bug in QSqlQuery::isNull documentation
the method returns true if there is not such field.

Change-Id: I25db8de4561d3e0604f3e64edc1810140ba4aad2
Reviewed-by: Andy Shaw <andy.shaw@digia.com>
Reviewed-by: Mark Brand <mabrand@mabrand.nl>
2013-10-22 17:05:47 +02:00
Matt Hoosier
163bbeb218 Detect pointer size at configure-time on Windows-hosted builds
The configure-time procedure used on Windows does not currently
perform the same tests to determine the width of a pointer as are
performed on Unix-based builds.

This causes QT_POINTER_SIZE to be undefined in the generated
qconfig.h file. This in turn breaks compilation of various Qt modules
such as QtDeclarative.

This patch adds the same level of support for automatically
determining the target platform's pointer size, as is currently
offered to Unix users.

Change-Id: I93838c1759b14089ba9f4daf442048fb5c8da738
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
2013-10-22 12:15:57 +02:00
Oswald Buddenhagen
377c7575a7 don't load wayland-scanner for all projects on linux
it's wasteful, given that exactly one add-on module (and most probably
nobody else) needs it.

i'd do the same with yacc and lex, but i suspect this would cause quite
an uproar.

Change-Id: Ic2a6ca19e829393835f824e31cd0893e78c3fd39
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
2013-10-22 12:15:57 +02:00
Kai Koehne
9b187bcd6a Fix compilation with latest MinGW-w64 (release 3)
Now that MinGW-w64 fixed the headers the old hack actually break stuff.

Change-Id: I1f60b9176982f6c07e01f3960bc1d7e70d7f9481
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
2013-10-22 12:15:57 +02:00
Gunnar Sletta
72a7882cec Better QWindowContainer by not relying on native widgets.
We change the behavior slightly from the initial implementation in
5.1. Forcing the use of native child widgets is causing massive
performance issues so instead, we attach the embedded QWindow directly
to the root window. The only exception is QScrollArea and QMdiArea
which still enforces native windows for the entire parent chain
to make clipping and stacking work.

Task-number: QTBUG-34138
Change-Id: If713637bd4dce630552ace2f8ad6b2e86c063721
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
2013-10-22 10:46:21 +02:00
Friedemann Kleint
2d107c20b9 Fix settable style hints.
Introduce QStyleHintsPrivate and introduce internal
setters called by QApplication.

Task-number: QTBUG-33991
Change-Id: Id61f8b1e2b5c9cfd7b4713aaded66e93e6f63719
Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
Reviewed-by: Andy Shaw <andy.shaw@digia.com>
2013-10-22 10:04:48 +02:00
Marcel Krems
c9ad904af9 Doc: Add missing \since 5.2 to QSizePolicy::retainSizeWhenHidden
Change-Id: I461e8187810e564e06869df86b23cc40aeba72bd
Reviewed-by: Thorbjørn Lund Martsum <tmartsum@gmail.com>
2013-10-22 05:49:34 +02:00
Roger Maclean
93cd08bfcc Correct handling of font weights bolder than bold.
A couple of places were checking for a font weight equal to QFont::Bold
rather than a weight that is greater or equal to this. This sometimes
results in QFont::Black being rendered with a lighter weight than
QFont::Bold even though it should if anything be heavier.

Change-Id: I5aa73a84ea2718783bbac93a031d87b2ad90012c
Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
2013-10-22 03:54:40 +02:00
Konstantin Ritt
7627f6739b Skip extra PKGCONFIG variables with empty value
The fallback value is an empty string anyways.

Change-Id: I77a2d3ad275321cb8b2e059fb6359f921cbc697c
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
2013-10-22 00:22:17 +02:00
Allan Sandfeld Jensen
690cf426f3 Fix Q_ASSERT(!channels[0].isSocketBusy());
Since commit f30641a7 is has been possible to issue more than one host
lookup request per HttpNetworkConnection. If the result was both an
IPv4 and IPv6 address, and we get a second similar DNS reply, we
end up triggering the assert in startNetworkLayerStateLookup().

This patch splits the InProgress state to HostLookupPending and the state
of trying both IPv4 and IPv6. This makes it possible to ignore any new DNS
replies received after the first succesfull one.

Change-Id: I0b8d6b1582fdaed69dde5926019b60bb0cbd580d
Reviewed-by: Peter Hartmann <phartmann@blackberry.com>
2013-10-21 17:35:00 +02:00
Richard Moe Gustavsen
13035f7fd6 iOS: default_post: let xcodebuild_distclean depend on xcodebuild_clean
Otherwise, make would upon distclean first remove the xcode
project, then try to do xcodebuild distclean. xcodebuild would
then complain about a missing project.

Change-Id: I0a9a6af6d86d1a95e37f4bbafa38c63d892bf1cc
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
2013-10-21 14:13:51 +02:00
Peter Hartmann
04771062a1 changelog: add note about TLS session tickets
Change-Id: I154a56ff85adb8d43ddb730d91d2c59f129f7a26
Reviewed-by: Richard J. Moore <rich@kde.org>
2013-10-21 13:38:00 +02:00
Sergio Ahumada
bdc558019a tests: Replace Q_OS_MACX -> Q_OS_OSX
Use the correct identifier for the OS X operating system.

Change-Id: I7158a6b77e5e7418bc6b0a565f003500820a346d
Reviewed-by: Jake Petroules <jake.petroules@petroules.com>
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
2013-10-21 10:37:56 +02:00
Mandeep Sandhu
c371680a86 QDnsLookup: Support for custom DNS server
This commit only adds a new QProperty, "nameserver", to QDnsLookup.
This property currently does not do anything and is not used internally
by QDnsLookup. The next commit will implement it's usage.

Task-number: QTBUG-30166
Change-Id: I85b72bd6661603128cab4068c1b83883fb2bfd1a
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2013-10-21 06:46:02 +02:00
Sze Howe Koh
a9d5627e6a Doc: Update, and reduce duplication of, QThread-related info
Added/Changed:
- Move content from the Thread Basics overview to the QThread class ref
- Rephrase bits for clarity
- Use more links

Removed:
- (threads-basics.qdoc) Warning against moveToThread(this): This usage
  came about when people tried to add slots to a QThread subclass. This
  patch adds a warning against the root cause.
- (threads-basics.qdoc) Note on sleep() et al.: They were made public in
  Qt 5.0.
- (threads-basics.qdoc) The strategy for managing member variables:
  Sounds error-prone. Pushing results through signals is safer.
- (qthread.cpp) The note about GUI classes: Irrelevant to QThread,
  and it's already mentioned elsewhere.

Change-Id: I6bc53cc22b929523f9976d2b920f94c02bd7273e
Reviewed-by: Geir Vattekar <geir.vattekar@digia.com>
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2013-10-21 02:12:11 +02:00
Keith Gardner
4dc6a89151 Used QT_DEPRECATED_X in QtAlgorithms
Made all of the deprecated functions in QtAlgorithms now use
QT_DEPRECATED_X with helpful deprecation messages.

Change-Id: I3358e44b8c1f15eeb4689ab02b1802a07d04fc09
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2013-10-21 00:13:33 +02:00
Keith Gardner
b1093ef647 Added QT_DEPRECATED_X(text)
Defined the Q_DEPRECATED_X to use the Q_DECL_DEPRECATED_X macro.

Change-Id: I334328059c6a1e046f57470027b0d1086a35042c
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2013-10-21 00:13:29 +02:00
Keith Gardner
345907344d Fixed Q_DECL_DEPRECATED_X for Gcc 4.4
Apparently the __attribute__((__deprecated__(text))) feature for gcc was
introduced in version 4.5.  Since Qt's minimum supported version of gcc
is 4.4, the declaration of the macro needed to check the compiler's
version number.

Since clang reports its __GNUC__ and __GNUC_MINOR__ as gcc 4.2, the
check for the compiler support had to be added in with
__has_feature(attribute_deprecated_with_message).

For icc, a check was added to see if __INTEL_COMPILER >= 1300, __GNUC__
is defined and Q_DECL_DEPRECATED_X was not defined.  If this is true,
the gcc syntax is used in the define.

Change-Id: I23980ac28b79264e8fd657cd3bfd2af7674779a1
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2013-10-21 00:13:24 +02:00