Commit Graph

7279 Commits

Author SHA1 Message Date
Jędrzej Nowacki
d17cf14185 Implement QVector with QArrayData interface.
Change-Id: I109f46892aed2f6024459812d24922b12358814d
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2012-05-30 17:07:27 +02:00
Jiang Jiang
5131aefc1f Fix text decoration width rounding
width passed in qreal should be set with setWidthF instead of
setWidth, otherwise the fractional part is lost.

Also remove the raster paint engine hack that has been removed in
Qt 4.8, it's no longer needed.

This fixed the drawUnderline and drawRightToLeft auto tests in
tst_qglyphrun.

Change-Id: Iace46fc27ff156c07fb4d08a145269fad36e9fdb
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2012-05-30 16:34:25 +02:00
Casper van Donderen
60fb770fa7 QDoc: Add support for 'all subfolders' in dependant modules.
It is now possible to use '*' when specifying the 'depends' qdocconf
variable, this will automatically load all index files found in
subdirectories of the index dirs.

Change-Id: I94b140df27da8d987824005a1dcf2a9348d5cd9e
Reviewed-by: Martin Smith <martin.smith@nokia.com>
2012-05-30 11:13:55 +02:00
Casper van Donderen
28ae5aa332 QDoc: Force writing \n before a snippet in DITAXML.
Previously the snippet text would be indented, which causes an XSLT to
render the first line of a snippet at the indentation level of the .dita
file.

Change-Id: Iead8d07277f83ca5ccbf463f1cdb1c8210459d56
Reviewed-by: Martin Smith <martin.smith@nokia.com>
2012-05-30 11:13:46 +02:00
Samuel Rødal
4f539b2671 KMS platform plugin: Introduce default cursor for better usability.
Similar to the default cursor in eglfs, not having it makes it hard to
interact with Qt applications using the evdevmouse plugin.

Change-Id: I9638267c7d790d91b66620e4a82d86f299061922
Reviewed-by: Andy Nichols <andy.nichols@nokia.com>
2012-05-30 11:11:02 +02:00
Girish Ramakrishnan
e18569ee1d eglfs: keep context active only during flush
The OpenGL context needs to be current only while flushing
the backing store.

Change-Id: I4d6a10f22bcfe04f35a14a690180237f6c691829
Reviewed-by: Andy Nichols <andy.nichols@nokia.com>
2012-05-30 11:10:42 +02:00
Girish Ramakrishnan
0cb7dac534 Add minimalegl QPA platform plugin
The EGLFS platform plugin was originally meant to be an example
and thus to be kept simple. However, EGLFS is becoming more
and more complex with the addition of hooks for board support,
cursor integration, built-in evdev support etc.

minimalegl is a new platform plugin that intends to follow
the original intentions of EGLFS.

The code is an adaptation of EGLFS as of f913859f8

Change-Id: I3d4cf84cde380cdcc7e0e8bfefff4df6be731b8d
Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
2012-05-30 08:30:42 +02:00
Holger Hans Peter Freyther
9e424adbdd directfb: Allow a window subclass to allocate a different kind of surface
A subclass of QDirectFbWindow might need to allocate a window with
different surface flags. This is the case for the DirectFB EGL plugin
and QSurface::OpenGLSurface type of surfaces. Add createDirectFBWindow,
make it virtual and call it from the platform integration classes. Add
an assert to verify that this method is only called once. Remove the
pre DirectFb 1.1 code as it was never really tested.

Change-Id: Icf3d262f40bca70e376043935eeb292958f6df5d
Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
2012-05-30 08:30:42 +02:00
Girish Ramakrishnan
56fca8ce14 Fix compile error in eglconvenience
Change-Id: Ic20d890a9c59e21a5f0c81f961074ab02083a266
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
Reviewed-by: Sergio Ahumada <sergio.ahumada@nokia.com>
2012-05-30 06:29:10 +02:00
Rohan McGovern
46ae50a5d0 Marked tst_qprocess as parallel-safe
This autotest appears to be parallel-safe.  It fails our parallel stress
test, but only because it writes to its own build directory.  This
should not interfere with other autotests.

Change-Id: Ie99dde24edc0fda0c8ec4352a6e44abb7cbc54f8
Reviewed-by: Toby Tomkins <toby.tomkins@nokia.com>
Reviewed-by: Kalle Lehtonen <kalle.ju.lehtonen@nokia.com>
2012-05-30 06:29:10 +02:00
Holger Hans Peter Freyther
717ca1a2a6 directfb: description.surface_caps was already assigned conditionally
We have already assigned this flag in case the IDirectFBSurfaceLayer
has the capability of premultiplied alpha. Do not set it unconditionally.

Change-Id: Id5f9bd6bdfa29dc9cd35d913b61fb55c09f54864
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
2012-05-30 04:27:50 +02:00
Johannes Zellner
e6a4d6054d evdev: Cleanup mouse and keyboard plugins
Remove fallback event0 device usage. All available devices should be
detected automatically from DeviceDiscovery either through udev or the
static fallback discovery method. This also removes the never used 'key'
argument, which was pulled over from Qt4.

Change-Id: Iffe8bd80f0770664024019a220cbbc6f98843340
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
2012-05-30 04:25:48 +02:00
Morten Johan Sorvig
a530ffd6de QtConcurrent: Remove QMutex kept for BC reasons.
Task-number: QTBUG-25052

Since upgrading to Qt 5 forces a recompile there
are no longer inline versions of the acquire/release
functions in play.

Change-Id: I6ce6abe0f16f810891f32c7e8c5c94726e5de873
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
2012-05-30 01:54:45 +02:00
Morten Johan Sorvig
d725c3ee23 Remove the MacMainWindow example.
setUnifiedTitleAndToolBarOnMac will not be supported
on Qt 5, which removes the point of having this example.

The replacement for setUnifiedTitleAndToolBarOnMac
will be a NSToolBar wrapper in the MacExtras module,
and this example will probably re-appear in some form
there.

Change-Id: I46d5e70a7c45625d9334911bb48059e86f05282d
Reviewed-by: Christoph Schleifenbaum <christoph.schleifenbaum@kdab.com>
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
2012-05-30 01:54:45 +02:00
Morten Johan Sorvig
9ea919915d Make popup windows show on the correct desktop.
Set NSWindowCollectionBehaviorFullScreenAuxiliary
for Qt::Popup windows. This will make them show
on the same desktop as their parent full-screen
window.

Change-Id: Ice1bd50976ef0cd66b01a683a43e08e782573153
Reviewed-by: Christoph Schleifenbaum <christoph.schleifenbaum@kdab.com>
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
2012-05-30 01:54:45 +02:00
Tasuku Suzuki
96c5b5ecf4 Fix compilation for QT_NO_CONTEXTMENU in QtWidgets
Change-Id: I05b23504549c0156ba5e72144674f843149932c0
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-05-30 01:54:45 +02:00
Debao Zhang
e5bd2ed18c qmake can not process project file with UTF-8 BOM
Project file contains UTF-8 BOM can't processesed by qmake and will
cause subtle errors.

Task-number: QTBUG-25848
Change-Id: Id69ed38c6be63a29fa3792a631cb8cb0ac176148
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-05-30 01:54:45 +02:00
Konstantin Ritt
a9b30841b9 QTBF: fix the mandatory line breaks not being set in some cases
e.g. for the text "Aaa bbb ccc.\r\nDdd eee fff." the \r\n wasn't treated
as a hard line break or as a line break opportunity, ever.
Quite ancient bug...

Change-Id: I8d8497c55a3a4d51c27de99ccfe1e31f3bf4de77
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2012-05-30 01:54:45 +02:00
Konstantin Ritt
32c39330ef Introduce QUnicodeTools
Add QUnicodeTools namespace and rename qGetCharAttributes to initCharAttributes;

Make it possible to disable tailoring globally by overriding
qt_initcharattributes_default_algorithm_only value
(useful for i.e. running the specification conformance tests);

This is mostly a preparation step for the upcoming patches.

Change-Id: I783879fd17b63b52d7983e25dad5b820f0515e7f
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2012-05-30 01:54:45 +02:00
Konstantin Ritt
c16455dbcf Re-generate the Arabic joining tables from UCD 6.1.0
Some names were fixed to meet their values in the Unicode data files (e.g. Zain -> Zhain);
Some other names were added as a value alias (Nya -> Noon) or deprecated
but retained as a value alias for BC (HamzaOnHehGoal -> TehMarbutaGoal);
Newly assigned Arabic characters were mapped into respective joining types and classes)

Change-Id: Ic4b4a6baf70f51fb5936f74fe9a173b8790dda11
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2012-05-30 01:54:45 +02:00
Lars Knoll
de255a8caf Remove QUpdateEvent from the public headers
It's only used internally in qwidget, so it might as well
live in qwidget_p.h.

Task-number: QTBUG-25070, QTBUG-25373
Change-Id: I87770e0b49253b4bdebe90ce84dd42448d6175bd
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2012-05-30 01:54:45 +02:00
Eskil Abrahamsen Blomfeldt
770e0bb756 Add some batching functions to QPlatformSharedGraphicsCache iface
This adds some pure virtual functions to the interface to enable
batching requests.

The interface functions no longer need to be invokable, as
invokeMethod() is too slow to be used at the required frequency
anyway.

Change-Id: I89b607de1a28f3f4b728c334c04bcd443d4366b4
Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
2012-05-30 01:54:45 +02:00
Jan-Arve Saether
7cdcc26722 Fix Qt 5 todo issues for QSizePolicy.
* Merge the two public ctors.
* Use bitflags instead of shifting bits (more readable).
* Add autotest
* Use int datatype for the "stretch setters". (values out of bounds are clamped)

Streaming to QDataStream will still use the Qt 4 format.

Task-number: QTBUG-25100

Change-Id: Iecb1e78cb12717e4d84448484c3ad8ca469d571a
Reviewed-by: Paul Olav Tvete <paul.tvete@nokia.com>
2012-05-30 01:54:45 +02:00
Samuel Rødal
ef204659b9 Fixed KMS y-invertedness.
Upgrade to new gbm_surface API which lets us use eglCreateWindowSurface.

Change-Id: I4af86d442375017ae3b4744e7b3bdebf3b496b6e
Reviewed-by: Andy Nichols <andy.nichols@nokia.com>
2012-05-29 23:48:29 +02:00
John Layt
44f7df439f QtPrintSupport - Add QPrinterInfo api for more printer details
A previous commit changed the Mac behaviour for printerName()
from returning the CUPS Description to returning the CUPS Name.
In case anyone was relying on this for a human-readable name
add new api to return the CUPS Description.  Also add the
Location and Make and Model which will be used in the Unix
print dialog instead of directly calling CUPS.

Change-Id: I9901bf8d6368466adf111580f5db5a3f01ca9170
Reviewed-by: Teemu Katajisto <teemu.katajisto@digia.com>
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Reviewed-by: John Layt <jlayt@kde.org>
2012-05-29 23:48:15 +02:00
Holger Hans Peter Freyther
b7104d6645 Document QWindow's setSurfaceType and setFormat update behavior
QWindow::setSurfaceType and QWindow::setFormat do not re-create
the QPlatformWindow. Attempt to document this behavior and point
to the documentation of destroy() and create().

Change-Id: Idf7eb343d4918a45b5a701effe3263145a33790a
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
2012-05-29 23:38:13 +02:00
Girish Ramakrishnan
d460f089e5 eglfs: Don't update screen for non mouse-move events
Change-Id: I7df089a9dc87396e19c08cef3d76c7c7f95a8fbf
Reviewed-by: Donald Carr <donald.carr@nokia.com>
Reviewed-by: Andy Nichols <andy.nichols@nokia.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2012-05-29 23:37:51 +02:00
Girish Ramakrishnan
a72f64f1c1 Add q_printEglConfig to qeglconvenience
The code was initially part of eglfs.

Change-Id: I8aa6e77edec85ab2b23765ca04e4416757f3bed6
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2012-05-29 23:37:47 +02:00
Girish Ramakrishnan
e973d0965c eglfs: remove support for widget rendering using opengl paint engine
The eglfs backing store code can render either using the raster paint
engine (through QImage) or using the opengl paint engine. Rendering
quality using the opengl paint engine is pretty poor so remove
it.

Change-Id: I64061ceb3a480049cfebe61aaf172ad1f1da7042
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2012-05-29 23:37:43 +02:00
Girish Ramakrishnan
d324019913 eglfs: release shader program after use
Change-Id: Ibe89de88c6c01d182a240def92eb78c0cc896463
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2012-05-29 23:37:40 +02:00
Girish Ramakrishnan
42f4fa60f3 eglfs: rename QEglIntegration to QEglFSIntegration
Change-Id: Ifa096537d417571ed660a63a501fed188186f400
Reviewed-by: Donald Carr <donald.carr@nokia.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2012-05-29 23:36:49 +02:00
Thiago Macieira
095000c898 Fix shadow build compilation with MSVC
\#include "foo" in MSVC does not search the output path, so we need to
pass the proper -I flag to find the build dir's src/corelib/global.

Change-Id: I546051c99fd29d7734f8bf35d058ea283ec9bca7
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2012-05-29 20:24:23 +02:00
Miikka Heikkinen
618ea643ca Fix some painting issues with native widgets
QWidgetPrivate::drawWidget was missing an important line about marking
native widgets dirty compared to 4.8, which caused all other widgets
besides the native one to not repaint unless window was resized in such
a way that the widgets would get hidden and then re-exposed.

The above didn't fix repainting issues when moving native widgets
(e.g. widgets in QMdiArea subwindows or just calling QWidget::move()).
Added setting widgets dirty to QWidgetWindow::handleExposeEvent to
address this issue.

If there is one native widget, Qt enforces that all widgets in same
parent hierarchy are native - presumably to get overlapping widgets
drawing correctly. However, qapplication_qpa.cpp set the attribute
Qt::AA_DontCreateNativeWidgetSiblings for all applications, which
caused only the parents of native windows be forced native, leading to
drawing artifacts related to siblings of native widgets (e.g.
overlapping QMdiArea subwindows). I don't see a reason for setting this
flag indiscriminately for all applications, so removed it.

Also added setting newly created QWindow visible if associated
widget is already visible, which can happen if regular widgets
are shown before the first native widget is shown and retroactively
forces other widgets native.

Task-number:QTBUG-25805
Change-Id: Ib133dae9b13cc6e7155e7cae00fc1339d3b5ae86
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2012-05-29 20:13:11 +02:00
Lars Knoll
4d0424b671 Ask the platform drag for the correct default drag action
This fixes a remaining feature regression from Qt 4.x, where the
dragmanager also determined the default action for a drag given
the set of supported actions and the keyboard modifiers.

Task-number: QTBUG-25373
Change-Id: I80b23b135ba218eb5b7ccc692f12140477bc7809
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-05-29 20:13:03 +02:00
Thiago Macieira
a4ca3280c0 QApplication::activeWindow is replaced by QApplication::focusWindow
Change-Id: I28ec9b59171fbacbe5c7c0dd1cc998d75538545f
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-05-29 20:12:53 +02:00
Friedemann Kleint
a09c20f19b QWidget::grab: Add a default value for the QRect parameter.
The documentation is misleading in that a default-constructed
rectangle that has size = 0 causes the entire widget to be
painted; this happens only if the one of the size values is
 < 0.

Add a default value such that size < 0 and the entire widget is
painted based on the rationale that a size = 0 might be the result
of some calculation and it would be unexpected to get a pixmap
containing the entire widget in that case.

Change-Id: I2a5fb38cd407b4b64348213101d8196b2c40ad9a
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2012-05-29 20:12:39 +02:00
Friedemann Kleint
65a264c4a1 QWidget::grab(): Do not call adjustSize() unconditionally.
This breaks the combo dropdown animation on Windows as it
uses special layout tricks and potentially other (unlaid-out)
widgets.

If the size is unknown, call prepareToRender instead.

Reverts d6f971c854.

Change-Id: If44e2a7e7fb134c228674cf228bbee0d5520e04f
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2012-05-29 20:12:32 +02:00
Friedemann Kleint
97659d87be Windows QPA plugin: Add \internal to class documentation.
Prevent the classes from appearing in the Qt documentation.

Change-Id: I62abff0c57effdf16629f9d5a0dc384ea2c43d5a
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-05-29 20:12:24 +02:00
Holger Hans Peter Freyther
486f0e93de Only build devicediscovery on linux systems
libudev and linux/input.h are Linux specific. Instead of add a !*bsd*
to the pro line I have decided to only check for linux-*. This is fixing
the compilation on FreeBSD.

Change-Id: If59481421e811eca205407031db593e00b6e8534
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
2012-05-29 19:54:25 +02:00
Laszlo Agocs
243a0660e1 Make qWaitForWindowShown more robust on X
Try ensuring the window has received its valid position from the WM.

Change-Id: Ibd75bc19ae820765bfaadd30c22e77a19cd28849
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2012-05-29 11:37:35 +02:00
Eskil Abrahamsen Blomfeldt
2e6b8b4734 Disable GSUB feature when text contains surrogates
This is a work-around for a feature missing in Harfbuzz that
can make a text run that contains a surrogate and a ligature
crash. This will potentially cause the ligatures to break up
if you combine them with a surrogate, causing visual changes
to the text, but the scripts that require GSUB should not be
affected by this, since they will not use surrogates. Still,
it's not a permanent fix, but will serve as a bandaid for the
crash until the underlying problem has been fixed.

Task-number: QTBUG-22275
Change-Id: I90c37fba76bc7d1f369f3afddd1bd0dc306f5750
Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
2012-05-29 11:35:21 +02:00
Thiago Macieira
291b05e4b2 QApplication::syncX doesn't do anything in Qt 5 anymore
Change-Id: I325f8badeb5bd7120c691b49fdf51dc9b2649f68
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2012-05-29 11:35:21 +02:00
Bradley T. Hughes
19e2b4d6eb Remove unnecessary forward declaration in std namespace
qiterator.h doesn't use std::bidirectional_iterator_tag or
std::random_access_iterator_tag, so remove the forward declarations.
(These actually confuse clang when building with C++11 support enabled).

Change-Id: Idd0daa0840a0995e6e5b0ffc01ddcdf06f048149
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2012-05-29 11:35:21 +02:00
Thiago Macieira
fad1fa65ed QtDBus: compile with QT_STRICT_ITERATORS
Unlike most other modules, QtDBus in its use of QVector also needs to
check if the item isn't null, which makes for some special changes.

Change-Id: Ia22ad2a6b26c9c34dc09ab882d81323a941d166a
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
2012-05-29 11:35:21 +02:00
Thiago Macieira
395f7579c0 Make qdoc compile with QT_STRICT_ITERATORS
Change-Id: I2923315678d1aef516b35a8c83fe734367723a28
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
2012-05-29 11:35:21 +02:00
Giuseppe D'Angelo
779e2f38ea QtOpenGL: remove \link usages
Change-Id: I34509eaf87a91bf31a78b08c91d9a57e704d8989
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
2012-05-29 11:35:21 +02:00
Giuseppe D'Angelo
5343ec6cff QtXml: remove \link usages
Change-Id: Ifcf1e66bad04e312c29de623fee47fabb91cc108
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
2012-05-29 11:35:21 +02:00
Giuseppe D'Angelo
3471e2de78 QtWidgets: remove \link usages
Change-Id: I9887a24485233f29d07054b3110d4db9e499b9f4
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
2012-05-29 11:35:21 +02:00
Giuseppe D'Angelo
358f78f215 QtGui: remove \link usages
Change-Id: Ib8cca14a8fa35fbc631bfea9b4873225eac3677f
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
2012-05-29 11:35:21 +02:00
Giuseppe D'Angelo
2c49ea852f QtCore: remove \link usages
Change-Id: I0de764b51a972de0b6eb2bf3c04d2b190f581f52
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
2012-05-29 11:35:21 +02:00