summaryrefslogtreecommitdiffstats
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
* Fix bounding box of DirectWrite font engineEskil Abrahamsen Blomfeldt2012-07-091-4/+9
| | | | | | | | | | Vertical bearings of the font were ignored, giving the wrong height. Also, the left bearing is right bound in DirectWrite, so the sign should be flipped. Task-number: QTBUG-22649 Change-Id: I82934f5b08e68e46d1b2221b35008bf9d75c5748 Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
* QNX: QtGlobal: compile as a C header againMarc Mutz2012-07-091-1/+3
| | | | | | | | | | | <utility> is a C++ header, only execute the check for the Dinkumware standard library if we're compiling under a C++ compiler. Change-Id: I1b24e76f20bfc03b70a330f9da96b4f815106e61 Reviewed-by: Thomas McGuire <thomas.mcguire@kdab.com> Reviewed-by: Sean Harmer <sean.harmer@kdab.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Fix cursor truncate to include line positionJiang Jiang2012-07-091-2/+2
| | | | | | | | | | | Since we could have moved the line position (QTextLine::setPosition), the truncating position should be adjusted with that. Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com> (cherry picked from commit ca89c49fa2c5cbb3945897046f33eed9f7da846c) Change-Id: I89ea1a3776a50732181bdfea9e79b4dddef950d4 Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
* fix "paintEngine: Should no longer be called" warnings on WindowsJoerg Bornemann2012-07-091-1/+1
| | | | | | Change-Id: Idece743d1f28f1c579d823123b6814fae786b58b Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com> Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
* qpa: Fix crash when native interface is nullGirish Ramakrishnan2012-07-091-8/+9
| | | | | | | QPlatformNativeInterface is optional. Change-Id: Iae2a6de63fc8a36deb6059047a0d7f05defb6b5c Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* Remove Library dependency on SettingsTasuku Suzuki2012-07-0914-31/+29
| | | | | | | | made QLibraryInfo available with QT_NO_SETTINGS. QKdeTheme is removed when QT_NO_SETTINGS is defined. Change-Id: I63d619bb305e6c23985d9ea50c72d39a697b7a4b Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* QWindowsWindow: fix FullScreen state transitionJoerg Bornemann2012-07-091-2/+11
| | | | | | | | | | | | | | When putting the window into FullScreen state, we - must not override the saved style and geometry if it has been saved before. E.g. FullScreen -> Minimized -> FullScreen - have to retrieve the window's normal geometry if the window is currently minimized. E.g. Minimized -> FullScreen Task-number: QTBUG-26420 Change-Id: If4164feee5997682406701f0ea7018d7f6257d35 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* QWindowsWindow: fix state transition FullScreen -> MinimizedJoerg Bornemann2012-07-091-1/+1
| | | | | | | | | When going from FullScreen to Minimized we must not restore the window's saved geometry. Task-number: QTBUG-26420 Change-Id: I75af8bb9aeb38f5bc24bc4e0b725786c8c22fdb3 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* QWindowsWindow: fix restoring from minimized to fullscreenJoerg Bornemann2012-07-092-2/+8
| | | | | | | | This fixes the state transition FullScreen -> Minimized -> FullScreen. Task-number: QTBUG-26420 Change-Id: I555c4f332e796b465149e592c2583d615b37c4ec Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* fix fullscreen state in QWidgetWindow::handleWindowStateChangedEventJoerg Bornemann2012-07-091-2/+0
| | | | | | | | | A widget can be Qt::WindowMaximized and Qt::WindowFullScreen at the same time. See tst_qwidget::windowState. Task-number: QTBUG-26420 Change-Id: I89d6edb857f41cda911152244cf23d36dfd1cdce Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* Use QDoc instead of Qdoc to be consistent with the rest of the documentationLaszlo Papp2012-07-082-2/+2
| | | | | Change-Id: Iec031e207609b87e3c85bec66a7aaebd971973d1 Reviewed-by: Richard J. Moore <rich@kde.org>
* QMimeType: document preferredSuffix()/suffixes() betterDavid Faure2012-07-081-2/+3
| | | | | | | Change-Id: Icf4aab3516cd622d9932e32cb0bd819bef22ce9b Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: Ivan Komissarov <ABBAPOH@gmail.com> Reviewed-by: Wolf-Michael Bolle <wolf-michael.bolle@nokia.com>
* Fix QMimeType::operator== to only compare mimetype names.David Faure2012-07-082-20/+3
| | | | | | | | | | The name is the unique identifier. Code such as if (oldItem.mimeType() == newItem.mimeType()) really wants to detect whether the item has a new mimetype (name), not compare static mimetype data such as comments and icons. Change-Id: I5fe56443295c91e1024c066ad6e7f93d842ae507 Reviewed-by: Wolf-Michael Bolle <wolf-michael.bolle@nokia.com>
* Q_DECLARE_SHARED: fix docs; require and use member-swapMarc Mutz2012-07-061-5/+5
| | | | | | | | | | | | | | | By requiring a member-swap, this macro becomes applicable to a wider range of types (e.g. QFont, which has another member besides 'd'), while at the same time avoiding the encapsulation leak that is data_ptr(). There have been concerns over breaking existing users of this macro, but for some time now, Q_DECLARE_SHARED only works within QT_BEGIN_NAMESPACE anyway, so its a safe bet that all users of this macro are in-tree. Change-Id: I7fdd9dba204554af8d3f9768b97bb42847a5acf4 Reviewed-by: Olivier Goffart <ogoffart@woboq.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QPalette: add member-swapMarc Mutz2012-07-062-32/+50
| | | | | | | | | | | | | | Implemented as in other shared classes (e.g. QPen), except that I wrapped the bitfield in a union to speed up swapping. (GCC didn't manage to optimize (hand-rolled) swaps of adjacent bit field elements into an integer one, even at -O2). GCC -pedantic complains about anonymous structs, so I had to give the struct in the union a name. Change-Id: I519e1c2f88f6ae2dffed38b493991189d67073b8 Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com> Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QtNetwork: add member-swap to shared classesMarc Mutz2012-07-0628-0/+202
| | | | | | | | Implemented as in other shared classes (e.g. QPen). Change-Id: Ib3d87ff99603e617cc8810489f9f5e9fe054cd2a Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
* QtGui: replace some copies with swapsMarc Mutz2012-07-063-5/+4
| | | | | | | | | | | This provides move speed even for non-C++11 compilers and avoids having to call the copy assignment operator from within copy ctors. (which will result in infinite recursion when using the copy-swap idiom). Change-Id: I379bc8bf2c72d9f986c0f17f9eef56cd592e7a06 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com> Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
* Doc: Replace all occurences of \BR with \br.Casper van Donderen2012-07-062-108/+108
| | | | | Change-Id: I9b0fac5fac7b0467de2d9a57a951b10a0f5438d7 Reviewed-by: Martin Smith <martin.smith@nokia.com>
* Fix some typos in the qdoc manualLaszlo Papp2012-07-061-10/+10
| | | | | Change-Id: I7d5e4ad684556b6c96fde2dcbdce6c772856cc33 Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
* Update framestrut initially after window creationMiikka Heikkinen2012-07-061-0/+7
| | | | | | | | | | | Creating native widgets such as QGLWidget and then calling move() on top level widget before doing show() on it caused framestrut to be incorrect, as native widgets force the creation of the native windows also on their ancestors when they are constructed, rather than waiting for window to be shown. Change-Id: I3e8d60547b3b683178ba059c5d92526a1d447442 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* QArrayData: Fix gcc warning about parentheses in 'a + b & c'.Friedemann Kleint2012-07-061-1/+1
| | | | | Change-Id: I2c08dc8170c77de401663b1643ebca8484dbfec0 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* Fix division by zero in triangulating stroker.Kim Motoyoshi Kalland2012-07-062-20/+49
| | | | | | | Task-number: QTBUG-15621 Change-Id: I10e0e39e57078507a01e1c2edb59fa52fd932f6c Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
* Remove duplicate triangulating stroker implementation.Kim Motoyoshi Kalland2012-07-069-753/+7
| | | | | Change-Id: I9d8f609c9ecb02dd25e588313bc98db4b9325974 Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
* QPlatformScreen::grabWindow() support on MacTasuku Suzuki2012-07-063-1/+64
| | | | | | | | Added QCocoaScreen::grabWindow() and copied Qt 4 implimentation. examples/desktop/screenshot works but WId window is not handled yet. Change-Id: If228bb59d98a5166788ab38293d7e6a6300d1f85 Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
* make QtGui compile when QT_NO_WHEELEVENT is definedJeremy Katz2012-07-061-0/+2
| | | | | | | | | | | | This is necesary but not sufficient to make the small configuration build. Task-number: QTBUG-24816 Change-Id: I1a06555e6f54f4d3c09a34fd50bf76e7b47d469f Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com> Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com> Reviewed-by: Tasuku Suzuki <tasuku.suzuki@nokia.com>
* Fix positioning when embedding native widgets such as QGLWidgetMiikka Heikkinen2012-07-061-0/+1
| | | | | | | | | | | Embedding native widgets creates window before ActiveQt has a chance to set the _q_embedded_native_parent_handle property on the window, so embedded flag doesn't get set during window creation. Update embedded flag also when setting window flags. Task-number: QTBUG-26438 Change-Id: Id29d7123de81d6542dfd6471d6dba3d31bbfe2df Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* qdoc: Removed several #if 1 macros.Martin Smith2012-07-064-28/+0
| | | | | | | | The code should be there. Also removed a few obsolete #defines. Change-Id: Id63418b344157a99ac502329eea4f0bc9dc77849 Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
* QDoc: Fix relative URL generation for cross-linking.Casper van Donderen2012-07-061-1/+1
| | | | | | | | Previously the URL relative to the installdir was used, now we use a relative URL to the index file. Change-Id: Ia2485aa49da8240901d0db1f102eb48da689ef2a Reviewed-by: Martin Smith <martin.smith@nokia.com>
* Implement nativeResourceFunctionForContext for xcbJorgen Lind2012-07-062-2/+12
| | | | | Change-Id: Icf6c39fb456b39fec58ac2f74c569b9d01993589 Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
* qdoc: Removed several #if 0 blocks.Martin Smith2012-07-068-317/+0
| | | | | | | Removed a lot of dead code. Change-Id: I237521efab7dd046d3a47ab92a6a0e083c59ab55 Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
* fixed cursor handling on winceBjoern Breitmeyer2012-07-064-1/+68
| | | | | Change-Id: Iea91dde458b0e41a55ba6cb3e157756a1473f653 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* Clean up attribute arrays flags in OpenGL glyph cacheEskil Abrahamsen Blomfeldt2012-07-061-0/+3
| | | | | | | | | When used in the SceneGraph we're expected to disable the arrays after we're done, otherwise we'll get a warning about memory corruption and crashes. Change-Id: Ie8e426309716bef4b75d79039e8ca0b4943c79e7 Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
* eglfs: Allow setting screen size through environment variables.Robin Burchell2012-07-061-0/+16
| | | | | | | | | | | | This adds: - QT_QPA_EGLFS_WIDTH - QT_QPA_EGLFS_HEIGHT If both are set, fb0 detection is completely bypassed, otherwise, the environment variables act as an override for the fb0 values. Change-Id: Iaf38c8b0d40ce0a921bb6c5dbf31af788802d3fa Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
* android: work around android's linux/input.h being retarded.Robin Burchell2012-07-062-0/+35
| | | | | | | | It seemingly doesn't include many of the required defines for evdev, so do what everyone else seems to do, and work around it. Change-Id: I4a6ffb548c7370f675c736177b63220f034d06b8 Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
* Disable dedicated screen event thread by default.Rafael Roquetto2012-07-051-3/+3
| | | | | | | | Screen events should come through QEventDispatcherBlackberry by default. Change-Id: I64d17b99e9dd8edf23f68e1186e9318849f1a398 Reviewed-by: Sean Harmer <sean.harmer@kdab.com> Reviewed-by: Thomas McGuire <thomas.mcguire@kdab.com>
* QHeaderView - resizeSection improvementThorbjørn Lund Martsum2012-07-052-1/+16
| | | | | | | | | | | | | | | | | This patch improves the manual resizeSection a bit. Before we didn't consider that the program could maybe resize other sections when the user was resizing one section. The main issue with that is that setOffset is so smart that it helps moving the mouse cursor - however it really shouldn't do if the program is trying to change something too. Maybe this won't solve all (possible) problems at once - but it is a fixed needed just to make something work - trying to make anything work without this fix is horrible.... Change-Id: I3cefa375a9b8ee4c1ef1e08ba0900025c671e4c6 Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* Fix event loop throughput issueRafael Roquetto2012-07-051-8/+25
| | | | | | | | | | Currently, only one bps event can be handled per event loop iteration, bringing about a huge performance penalty. This patch fixes this issue by bulk processing events whenever they are available. Change-Id: Iecce1e86730bd90c3c81a7c6ebdf9ed83189e58e Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com> Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* Do not delete m_blitProgram more than onceJiang Jiang2012-07-051-1/+0
| | | | | | | | | | | When m_blitProgram is created the constructor will add it to QOpenGLContext as a child of that QObject, so it will be deleted when that QOpenGLContext is deleted as QObject will delete its children in destructor. Delete it here will cause crash in thread termination. Change-Id: If9d3287d159cc3276b6a840a584a1b212b9c9fd0 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
* Support for overlay-scrollbars on MacChristoph Schleifenbaum2012-07-056-40/+449
| | | | | | | | | | | | | | | On Lion scroll bars are within the scroll area itself and are not being shown as long as the user is not scrolling. This patch draws the new scroll bars and makes them fade away. Further it introduces a pixel metric checking for this behaviour. It's used by QAbstractScrollArea to put the viewport to the correct place. Task-number: QTBUG-21673 Change-Id: Id530265043549318ac420b392de6b8642deaa4c6 Reviewed-by: Sean Harmer <sean.harmer@kdab.com> Reviewed-by: Gabriel de Dietrich <gabriel.dietrich-de@nokia.com>
* Sync QWindow properties on NSWindow creation.Morten Johan Sorvig2012-07-051-0/+6
| | | | | | | Synchronize size hints, window title, flags and state. Change-Id: Ibc2358d8d4d0625aaddfbcad159e3682e3e79d3c Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
* qdoc: The \br macro is promoted to a qdoc commandMartin Smith2012-07-055-0/+14
| | | | | | | | | | | The \br macro, which is used to insert a line break in the output text, is now promoted to be a qdoc command. For html, it outputs a <br/>. For DITA XML it does nothing. Task Nr: QTBUG-26435 Change-Id: Ie0542c9053f68473ccaa2f50ace74baa30f78dd0 Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
* Native drag implementation on MacJames Turner2012-07-045-2/+170
| | | | | | | | | | | | | | | | Create a native implementation of QCocoaDrag, using the 10.6 (and earlier) Cocoa dragging API. This matches the implementation in Qt4 closely for the moment. In the future it may be desirable to create an alternative implementation using the new (non-blocking) drag API introduced in 10.7, but that will require deeper changes to the mime-data handling. This changes makes one more method on QPlatformDrag virtual, since the Cocoa behaviour diverges from the base version: ::defaultAction is customised. Change-Id: I1843293a62b2b4973a07b5e75ea3c312dc064018 Reviewed-by: Christoph Schleifenbaum <christoph.schleifenbaum@kdab.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com> Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
* Cocoa: Fix size hint and resize increment setting.Morten Johan Sorvig2012-07-041-4/+16
| | | | | | | | Call the corresponding NSWindow size functions. Add special cases where Qt returns null or empty sizes. Change-Id: I880c50c04e92271dc342ad587191c8cb2c006dba Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
* QHeaderView - prevent negative default+minimum section sizesThorbjørn Lund Martsum2012-07-041-0/+4
| | | | | | | | | In 96f1fe8855082017fbbecccdab1eb11fd8c1f870 we agreed that sections with negative sizes did not make sense. Of the same reason default section sizes and minimum section sizes should be not negative. Change-Id: I6a770e7f510d8e2bb90bfd8f38b4fa0566fc137b Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* Properly detect the max texture size when using QOpenGLPaintDevice.Jocelyn Turcotte2012-07-042-1/+37
| | | | | | | | | | | The value is currently hard-coded to 1024, this is a problem since any image painted with a size higher that this will be scaled down before being uploaded. This patch copies the implementation from QGLContext which works correctly. Change-Id: Ia2bda60cf21d9adf13c91cea4854a2b20e4041f2 Reviewed-by: Kim M. Kalland <kim.kalland@nokia.com>
* disable building uic when -no-widgets is setTasuku Suzuki2012-07-041-1/+1
| | | | | Change-Id: I86040ec086621913fefcf6d349fe603758991c4e Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* Fix socket notifier registration on Blackberry.Rafael Roquetto2012-07-042-8/+52
| | | | | | | | | | This fixes a bug on QEventDispatcherBlackberry, where registerSocketNotifier() and unregisterSocketNotifier() wrongly assumed that a file descriptor was being watched exclusively by one QSocketNotifier, while in fact there can be more than one QSocketNotifier associated with a single file descriptor. Change-Id: I0ce54bf809df109ad97f4a7f170f448d5d04d453 Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* Uppercase the CONFIG for verbatim mode.Stephen Kelly2012-07-041-1/+1
| | | | | Change-Id: Iec883e0218af80fc329d866affb2b95db72c54d3 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* Add a Q_PROPERTY for the sourceModel of a proxy model.Stephen Kelly2012-07-042-9/+16
| | | | | | | | | | | Now that Q_PROPERTY with a QObject derived type is more powerful. This property can be used in QML so that wrappers for proxy models do not need to be created, such as in the example at https://codereview.qt-project.org/#change,13007 Change-Id: I6ba676549d2135585d429a28e214fef0b2a6b1f9 Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* Make QGenericPlugin and QGenericPluginFactory public APIGirish Ramakrishnan2012-07-0413-27/+20
| | | | | | | | | | These classes are not specific to QPA. Discussed in QtCS 2012. Change-Id: I32bc5fad4f0fa5e7095af86d61966fdf4d9e4ad7 Reviewed-by: Paul Olav Tvete <paul.tvete@nokia.com> Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>