summaryrefslogtreecommitdiffstats
path: root/src/gui
Commit message (Collapse)AuthorAgeFilesLines
* Fixed some clipping bugs in raster paint engine.Samuel Rødal2009-09-031-7/+7
| | | | | | | | | | Clip against the correct base region in clip(const QRegion &, ...) and make sure to not access QClipData's clipRect unless hasRectClip is true. This fixes the tst_QWidget::render_systemClip3() autotest, and the clipping bugs in Qt Creator. Task-number: 260666 Reviewed-by: Gunnar Sletta
* Fix test failure & optimize matrix operations in QGraphicsItem.Andreas Aardal Hanssen2009-09-031-0/+13
| | | | | | | | | | | | | | | | This fixes failures in tst_QGraphicsItem::setTransformProperties(). Change 9e8ff32d introduced QMatrix4x4 as an internal matrix for QGraphicsItem. Problem is, QMatrix4x4 is float-based whereas QTransform is double-based. This change readds the use of QTransform in the case where there are no QGraphicsTransforms in the list. This by itself also makes this common case a bit faster. The workaround is moot if somebody adds any QGraphicsTransform, including one that doesn't do anything (like rotate by 0 degrees). So we might have to find a better fix. Reviewed-by: Olivier
* Merge branch '4.6' of scm.dev.nokia.troll.no:qt/qt into 4.6Morten Sorvig2009-09-0312-107/+266
|\
| * Revert "Optimize qt_format_text test operations: try not to detach"Eskil Abrahamsen Blomfeldt2009-09-031-28/+40
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 5c4c47facfcb75b0277872a0fac813ab41700e5e. The commit broke line breaks in text (and also other special formatting characters.) QChar *chr is a pointer for a reason =) Reviewed-by: Trond Task number: 260622 Conflicts: src/gui/painting/qpainter.cpp
| * Added a property to QPinchGesture to specify what exactly changed.Denis Dzyubenko2009-09-033-1/+32
| | | | | | | | | | | | | | Added QPinchGesture::whatChanged() which specifies which property in the pinch gesture changed - the scale factor or rotation angle or both. Reviewed-by: Bradley T. Hughes
| * Improved the gesture api.Denis Dzyubenko2009-09-033-39/+144
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Made properties in QPanGesture and QPinchGesture more consistent - all of them have value, lastValue and totalValue. Documented that totalValue means the value from the beginning of the gesture, while the 'value' - from the beginning of the current sequence. This is especially useful on Windows when you zoom with two fingers and then release one finger and touch again to continue zooming. Also added a workaround for native Rotate gesture on Windows which contain a 'bad' value in the first WM_GESTURE message in every gesture sequence. Reviewed-by: Bradley T. Hughes
| * Improved the gesture api.Denis Dzyubenko2009-09-039-58/+46
| | | | | | | | | | | | | | | | | | | | | | Added a new widget attribute Qt::WA_DontUseStandardGestures that disables all implicit gestures (i.e. gestures that are automatically enabled by Qt itself). This change also changes the way gestures are handled on QAbstractScrollArea-based widgets on Windows - the gestures are supposed to be created on the viewport widget. Reviewed-by: Bradley T. Hughes
| * Fixed the QGesture::updateState function.Denis Dzyubenko2009-09-031-2/+5
| | | | | | | | | | | | | | | | When a state changes from NoGesture to any valid gesture state and we emit the started() signal, we need to make sure that the state of the gesture is set to the appropriate Qt::GestureStarted state. Reviewed-by: trustme
| * Added simple manualtests for gesturesDenis Dzyubenko2009-09-031-0/+20
| | | | | | | | Reviewed-by: trustme
* | Revert ed00fff3cb.Morten Sorvig2009-09-032-11/+1
|/ | | | | | | This caused dublicate key events in come cases, for example in the Qt Creator quick serach line edit. RevBy: TrustMe
* Make QTreeModel::ensureSorted() stable sort for itemsThorvald Natvig2009-09-021-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Id you have numerous items with the same value in the sort column, whenever you update one of them, they'll be placed at the head of the list instead of staying in place. For example, assume you have items a b(1) b(2) b(3) b(4) c (where all the b have the same value in the sort column) If you now emitDataChanged from b(3), ensureSorted() will be called. It will place b(3) in a list, and stable sort the list. It's just the one item since there was only one item updated. It than takes each item in the list, removes it's place from the "full" list of items, then reinserts it at the earliest point (using qLowerBound). End result: a b(3) b(1) b(2) b(4) c If you update all the items in the list (doing emitDataChanged() for each), this has the effect of reversing all the items with identical sort key. This patch checks if the old row is within the lower and upper bound of where the item might go, and if it is, simply reinserts it in its old place. Reviewed-by: Olivier Goffart Merge-Request: 1393
* fix warnings on mingwThierry Bastian2009-09-024-5/+5
|
* Respect "menus_have_icons" property in GTK+Jens Bache-Wiig2009-09-024-0/+34
| | | | | | | | | | | | The default value is planned to be changed in the next minor update to Gtk+ (2.28), hence we need to read this dynamically now. We also added a helper-function to easily read a gconf bool. Note, as a bonus feature I also added support for "buttons_have_icons". Task-number: 260684 Reviewed-by: joao
* doc: Fixed several qdoc errors.Martin Smith2009-09-027-24/+48
| | | | That's the last of them... for now.
* QApplication: Small commentMarkus Goetz2009-09-021-0/+1
|
* QCompleter could crash when setting the completion prefixThierry Bastian2009-09-021-3/+2
| | | | | | | This fixes the autotest that was crashing Task-number: 246056 Reviewed-by: ogoffart
* Fix the issue where the simplification did not simplify 2 anchors.Jan-Arve Sæther2009-09-021-36/+49
| | | | (It had to be minimum three anchors.)
* Merge branch '4.6' of git@scm.dev.troll.no:qt/qt into 4.6Janne Anttila2009-09-021-4/+4
|\
| * QMainWindow doesn't respect the sizehint of the dockwidgetsThierry Bastian2009-09-021-4/+4
| | | | | | | | | | | | | | It used to compress it because in the layout we were never picking the sizeHint. Now we do. Task-number: 260483
* | Fixes pointer events when using popups and/or modal dialogs.Janne Anttila2009-09-021-21/+46
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit also adds initial support for fading behind modal dialogs. Avoid unnecessary local/global capturing since when having global capture enabled we cannot for example tap icons on statusbar. The logic how pointer events for popups and modal dialogs shall work: - Modal dialogs: * Shall not close when outside dlg is clicked * Shall not allow usage or underlying control with mouse * Achieved with SetGloballyCapturing and SetPointerCapture in enterModal_sys / leaveModal_sys - Popups * Shall close when the outside popup is clicked * Achieved with enabling the SetPointerCapture only for topmost popup and canceling it for all underlyuing ones. * In addition long tap timer needs to be canceled for underlying widgets when opening a pop-up. Otherwise theu get longtap event whcih causes unexpected behaviour. TODOs: - Fading does not work correctly when more than two levels of modal dialogs are opened. - Fading does not work correctly when switching away from app and back to it with fast swap window (using menu works) - Check if fading should be implemented with MAknFadedComponent and TAknPopupFader, in order to support cross-application fading - Should popups closes when application loses the focus? Reviewed-by: Janne Koskinen
* CSS parsing speed-up: reserve CSS symbols prior to parsing.Ariya Hidayat2009-09-021-0/+1
| | | | | | | | Let us be optimistic here and reserve some space in the CSS symbols array before parsing starts. This gives 3% speed-up when loading tiger.svg (tests/benchmarks/qsvgrenderer). Reviewed-by: Olivier Goffart
* Rewrite of DirectFB locking mechanismAnders Bakken2009-09-011-0/+1
| | | | | | | | | | | | | | | | | DirectFB allows you to have a locked subSurface that remains valid while you paint on the unlocked "parent" surface. The only limitation is that when accessing the locked memory you might have to call DirectFB->WaitIdle() in case pending GPU operations aren't finished. After this we keep the locked surface around at all times (from the first time it's requested) until the surface dies. Previous calls to lock() will just call WaitIdle if necessary and previous calls to unlock now just mark the surface as dirty and in need of a WaitIdle if someone needs to access its pixel data. Reviewed-by: Donald Carr <donald.carr@nokia.com>
* Add DirectFB to QScreenDriverFactoryAnders Bakken2009-09-011-2/+7
| | | | Reviewed-by: Donald Carr <donald.carr@nokia.com>
* Add directfb.pri to embedded.priAnders Bakken2009-09-011-0/+4
| | | | Reviewed-by: Thiago Macieira <thiago.macieira@nokia.com>
* Copy directfb.pro to src/gui/embedded/directfb.priAnders Bakken2009-09-011-0/+38
| | | | Reviewed-by: Thiago Macieira <thiago.macieira@nokia.com>
* Doc: Fixed typos in QGraphicsItem and Diagram Scene ExampleGeir Vattekar2009-09-011-14/+13
| | | | | Task-number: 257292 Reviewed-by: Trust Me
* Doc: Fixed outdated docs in QStyle::styleHint().Geir Vattekar2009-09-011-5/+3
| | | | | Task-number: 256745 Reviewed-by: Trust Me
* QTreeView: exapnding nodes just after replacing the model wouldn't workThierry Bastian2009-09-012-3/+15
| | | | | | | | | | | The problem is that deleting the previous model would triggera delayed reset. This reset could happen after the model has changed and nodes are expanded. We can now cancel a reset when reset is called from another place (like when we set a new model). Note: autotest included Task-number: 245654 Reviewed-by: ogoffart
* Merge branch '4.6' of git@scm.dev.nokia.troll.no:qt/qt into 4.6David Boddie2009-09-017-18/+31
|\
| * Fix rounding bug in QGraphicsOpacityEffect.Bjørn Erik Nilsen2009-09-011-4/+5
| | | | | | | | The pixmap was painted at wrong offset.
| * Make sure the BSP is updated when a graphics effect changes bounding rect.Bjørn Erik Nilsen2009-09-014-2/+16
| | | | | | | | | | | | | | | | | | In the case of applying an effect to a QGraphicsItem, we have to notify the scene's BSP that the item's bounding rect has changed. We do this by calling prepareGeometryChange(). In the case of QWidget, it's sub-optimal that we update its parent, but there's no other way to solve it at the moment.
| * Fix reversed progress bars on VistaJens Bache-Wiig2009-08-111-1/+1
| | | | | | | | | | | | | | | | This issue seems to be caused by change a6782030 and was caused by incorrectly applying paranthesis to the expression. Task-number: 259515 Reviewed-by: joao
| * Make QIconloader use resource directory as fallbackJens Bache-Wiig2009-08-112-11/+9
| | | | | | | | | | | | | | | | Instead of using different paths on Mac and Windows we now simply use ":\icons" on all platforms. It is a little more effort to create resources but it is certainly the Qt way to do it. :) Reviewed-by: ogoffart
* | Merge branch '4.6' of git@scm.dev.nokia.troll.no:qt/qt into 4.6David Boddie2009-09-0119-365/+616
|\ \ | |/
| * Merge branch '4.6' of git@scm.dev.nokia.troll.no:qt/qt into 4.6Geir Vattekar2009-09-012-2/+61
| |\
| | * QGraphicsDropShadowEffect convenience; setXOffset() and setYOffset().Bjørn Erik Nilsen2009-09-012-1/+37
| | | | | | | | | | | | Reviewed-by: Andreas
| | * Make sure graphics effects updates properly when changing their properties.Bjørn Erik Nilsen2009-09-012-1/+24
| | | | | | | | | | | | Reviewed-by: Leo
| * | Doc: Said what happens when setFocus() is called on a widget in anGeir Vattekar2009-09-011-0/+2
| |/ | | | | | | | | | | | | inactive window. Task-number: 78707 Reviewed-by: Morten Engvoldsen
| * Microoptimizations in QCleanLooksStyleThorbjørn Lindeijer2009-09-011-140/+224
| | | | | | | | | | | | Shaved 4K off the size of a release build of libQtGui. Reviewed-by: Jens Bache-Wiig
| * doc: Also mention HSLThorbjørn Lindeijer2009-09-011-1/+1
| |
| * Merge branch '4.6' of git:qt/qt into 4.6Thiago Macieira2009-09-012-54/+61
| |\
| | * Added description of visualIndex condition to docs for logicalIndex()Peter Yard2009-09-011-1/+3
| | | | | | | | | | | | Fix for task: 214373
| | * Disable event compression when the tablet events are acceptedBenjamin Poulain2009-08-311-53/+58
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since Qt 4.5, all tablet events are compressed not to overload the widgets with the corresponding mouse event (a mouse event is generated if the tablet event is not accepted). This behavior reduce the precision when drawing on a widget that use the tablet events. All tablet events should be sent to the widget that are accepting the tablet event. With this patch, the tablet event are filtered only if the widget ignore the first tablet event. The mouse events are compressed. There is two special cases for the filtering: First, if a tablet event is for another widget than the one ignoring the tablet, this event should not be filtered. Second, if there is a mouse press event, the mouse move event should be sent to the widget that received the mouse press event. Helped-by: Pierre Rossi Reviewed-by: Thomas Zander Reviewed-by: Bradley T. Hughes
| * | Merge branch '4.5' into 4.6Thiago Macieira2009-08-311-0/+6
| |\ \ | | |/ | |/|
| | * Don't crash when convert Indexed8 without colortable to QPixmapGunnar Sletta2009-08-311-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | This implicitly adds "grayscale" support for indexed 8, but only for the conversion. The alternative would be leave the pixels uninitialized which would be less nice... Reviewed-by: Samuel
| | * Invalidate cached QVectorPath when QPainterPath changesGunnar Sletta2009-08-311-0/+2
| | | | | | | | | | | | Reviewed-by: Samuel
| * | Adapt to libpng 1.4.0beta74 API changeBernhard Rosenkraenzer2009-08-311-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | From libpng changelog: version 1.4.0beta74 [August 8, 2009] Changed png_ptr and info_ptr member "trans" to "trans_alpha". Merge-request: 1317 Reviewed-by: Thiago Macieira <thiago.macieira@nokia.com>
| * | Qt fails to build with libpng 1.4 betasBernhard Rosenkraenzer2009-08-311-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | Qt expects a trans_values member in png_info_struct; this member has been renamed to trans_color in libpng 1.4. Merge-request: 1317 Reviewed-by: Thiago Macieira <thiago.macieira@nokia.com>
| * | fix doc. id maps to QObject::objectName, not QGraphicsObject::setOpacity ;-)Riccardo Iaconelli2009-08-311-1/+1
| | | | | | | | | | | | | | | | | | | | | Signed-off-by: Riccardo Iaconelli <riccardo@kde.org> Merge-request: 1371 Reviewed-by: Thiago Macieira <thiago.macieira@nokia.com>
| * | Make QMargins a proper classJens Bache-Wiig2009-08-314-99/+98
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since we need QMargins for other things then the CSS helper functions in drawutil, we have to make it more generic. It is already useful for QWidget::contentsMargins for example. This ensures we have some flexibility on how to use and modify it in the future. Reviewed-by: mbm