summaryrefslogtreecommitdiffstats
path: root/src/gui
Commit message (Collapse)AuthorAgeFilesLines
* Doc: Fixed qdoc warnings.v4.7.0-rc1Jesper Thomschutz2010-08-244-17/+56
| | | | | | | | | | | | | | Reviewed-by: Trust Me (cherry picked from commit cb086eb5340c4c41efaf45373aa05c37e8aa974a) Conflicts: doc/src/index.qdoc src/dbus/qdbusconnection.cpp src/declarative/util/qdeclarativeanimation.cpp src/gui/s60framework/qs60mainapplication.cpp src/gui/s60framework/qs60mainappui.cpp src/network/access/qnetworkrequest.cpp
* Cocoa: revert parts of cc6dc0aeefde881a95f5fea2b26f2f3d7bdc6e15Richard Moe Gustavsen2010-08-191-4/+0
| | | | | | | | The reason is that we tried to fix the stacking order of child windows while we fixed a crash. But the patch turned out to break an auto-test Reviewed-by: prasanth (cherry picked from commit 749ad26d255327c9fa3fe857a30983cc6dfef0d9)
* Revert "Fix the rendering of lines with the X11 paint engine"Samuel Rødal2010-08-191-10/+12
| | | | | | | | | | | | | | | | | This reverts commit ebbab30af417dfbf3df47dec15c0e2f8d6a30fa6, which broke fill / outline consistency, and when trying to fix that by rounding the fill the same way that broke rendering in Creator. Unfortunately the X11 paint engine is too sensitive to changes, there have already been tons of patches to make it as consistent as possible. It's simply not possible to get the same rounding for both fill and outlines and at the same time have consistency between fill and outline (no holes or fill outside the outline), while using the integer based Xlib rendering API. Hopefully in 4.8 we'll switch to raster and the X11 paint engine will be a legacy. Reviewed-by: Trond (cherry picked from commit 041a68007413a20a9a9c97d0f2f04f9e03428f67)
* Revert "Outline / fill inconsistency in X11 paint engine."Samuel Rødal2010-08-191-4/+4
| | | | | | | This reverts commit ff405f5623d7ed18c881c097368e3e9afd2e9443. Reviewed-by: Trond (cherry picked from commit 3014b427aa8700890f9bd8ea2a0300fc152bf3d2)
* Outline / fill inconsistency in X11 paint engine.Samuel Rødal2010-08-191-4/+4
| | | | | | | | | | | Change ebbab30af417dfbf3df47dec15c0e2f8d6a30fa6 broke outline / fill consistency in the X11 engine. Since the positioning of lines is more important we'll round the fill coordinates the same way. The bug was visible in the filltest.qps arthur test. Reviewed-by: Gunnar Sletta (cherry picked from commit ff405f5623d7ed18c881c097368e3e9afd2e9443)
* Cocoa: parent windows shows on screen when they should be hiddenRichard Moe Gustavsen2010-08-191-6/+16
| | | | | | | | | | | | | | | The reason is the cocoa method that adds a window as a child of another, it ends up showing both the parent and the child window regardless. And this could in some cases also cause a crash. So we therefore need to be careful when calling that function, and be sure that the parent is actually visible. In addition, addChildWindow reset the stacking level of the child window, and made e.g. normal child windows pop in front of tool child windows. This could easily be seen in e.g. Designer. Task-number: QTBUG-12866 Reviewed-by: prasanth (cherry picked from commit cc6dc0aeefde881a95f5fea2b26f2f3d7bdc6e15)
* Drawer widget in a MainWindow disappears after returning from full screen mode.Carlos Manuel Duclos Vergara2010-08-181-1/+3
| | | | | | | | | | The problem was in the toggleDrawer function. We were not checking the status of the last transition before setting the new transition, so all the transition were treated as non-intentional. Task-number: QTBUG-11373 Reviewed-by: Prasanth (cherry picked from commit 725d8e061ededee9a5ddf0914aabd0f6aa2ee741)
* Cocoa: Stacking order of modal dialogs is wrongRichard Moe Gustavsen2010-08-161-6/+6
| | | | | | | | | | | | | Modal dialogs were sometimes hidden behind other normal windows on screen. The reason was that, upon going modal for a window, we actually resat the stacking level on the window in a faulty attempt to respect any stays-on-top window flags. This patch makes sure we avoid doing that, and at the same time, ensures we don't reintroduce the original bug as well. Task-number: QTBUG-12841 Reviewed-by: cduclos (cherry picked from commit 6d0d767e63df3c997d6d7a8cb6cd4bf8c0dfc835)
* Multiple "Edit/Special Characters" menu entries on Mac OS X (Cocoa)Prasanth Ullattil2010-08-164-0/+19
| | | | | | | | | | | | Every time [NSApp setMainMenu:] is called, Cocoa will add the 'Special Characters' item to the 'Edit' menu. Before adding a new entry it will make sure that menu items list doesn't contain an item with the selector 'orderFrontCharacterPalette' & a 'nil' target. We need to return the index for the first entry (we have QCocoaMenuLoader as target). Task-number: QTBUG-12842 Reviewed-by: Denis (cherry picked from commit b52da4ab2179079a6aff95891786d2f6598048b5)
* Properly emit geometryChanged() when the position change.Alexis Menard2010-08-131-1/+2
| | | | | | | | Also emit the signal at the very end, so people can rely on the resize event to adjust some stuff in their item. Reviewed-by:yoann (cherry picked from commit 3ee89bc0830f69d44f272eff5a0c886bff33c92e)
* Disable minRightBearing optimization in QTextLayout on MacEskil Abrahamsen Blomfeldt2010-08-121-0/+2
| | | | | | | | | | | | Neither of the Mac font engines have implemented minimum right bearing, which will cause them to return 0 for the minimum value. This will cause the right bearing to never be calculated prior to breaking and thus never be a part of the breaking width. Since actually implementing the functions is too time consuming for right now, we will disable the optimization for the time being. Reviewed-by: Olivier (cherry picked from commit bb696453f6f87cad58982af3455335478fedb8cc)
* Fix scrollbar randomly popping up in QPlainTextEditEskil Abrahamsen Blomfeldt2010-08-121-4/+17
| | | | | | | | | | | | | | When a line break was detected, we would retain the value of the right bearing for the character after the break instead of resetting it to the right bearing of the previous value. This could in some cases cause the bounding rect of the text to be wrong, and could cause unnecessary horizontal scrollbars to pop up. It was especially visible when using WrapAnywhere. Visible e.g. in the compile output in Creator. Done-by: mae Reviewed-by: Eskil Reviewed-by: Lars (cherry picked from commit c5fa9eb1cb02d979502e2c9918d752c6708fb406)
* Fix QTextEngine overflow caused by extremely long textJiang Jiang2010-08-123-33/+87
| | | | | | | | | | | | | Internally, QTextEngine use int to calculate most of the layout data required. If a string longer than 2^24 is passed into either QTextEngine or classes using it (QStackTextEngine, QPainter, QFontMetrics, etc.), overflow will happen because the memory size required to allocate for layout will become too large for int to handle. This patch will prevent these cases and add error handling mechanism for relevant code. Task-number: QT-3658 Reviewed-by: Eskil Abrahamsen Blomfeldt (cherry picked from commit 05bb249c2ad3ee15eb205a806f8546c105683096)
* Fix RightBearing confusion in text layoutmae2010-08-121-1/+1
| | | | | | | | Negative RightBearing was wrongly taken into account when calculating the line wrap Reviewed-by: Eskil Abrahamsen Blomfeldt (cherry picked from commit 975b1913e44128a3e9b9055f9bf2ff40d86adf2a)
* doc: Fixed some qdoc errors.Martin Smith2010-08-092-0/+33
| | | | (cherry picked from commit 30d6f7ed29a2a5723387768cfe82a807a2724b8b)
* doc: Fixed some S60 qdoc errors.Martin Smith2010-08-092-0/+54
| | | | (cherry picked from commit fb6aa3b0769c33685ad38a13fe5ad0ca48679a93)
* Translation work for 4.7Pierre Rossi2010-08-091-1/+1
| | | | | | | | | validating and adding some french translations. Plus all the fixes from Gabriel's extensive review. Doc: Fix a typo Reviewed-by: gabi (cherry picked from commit 209c017333fea9827fd20c7f8d23721bd8a6ee43)
* Don't crash if an item is removed from the scene while it is gaining focus.Martin Jones2010-08-061-0/+5
| | | | | | | | | If the item is removed from the scene in response to the FocusOut event of the previous item don't continue attempting to set focus. Task-number: QTBUG-12620 Reviewed-by: Michael Brasser (cherry picked from commit 7f2c9d716cba375ee3e576513898a39b3f2c39a5)
* Fixed crash in concentric circles exampleGunnar Sletta2010-08-061-1/+1
| | | | | | | | | | | The problem is that the qt_arcs... function will return point_count = 0 when the input rectangle is empty which it is in this case. Because we previously passed 13 there, were passing random memory to downwards in the pipeline, which caused problems. Task: http://bugreports.qt.nokia.com/browse/QTBUG-12516 Reviewed-by: mariusso (cherry picked from commit 08d09a78d3faf8b211e78cb63285c35c5544b5fc)
* Fix crash when setting font decorations on text drawn with QStaticTextEskil Abrahamsen Blomfeldt2010-08-051-1/+6
| | | | | | | | | | | Qt has a run-time assert for implementing drawPolygon() in any subclass of QPaintEngine, which will be hit if set font decorations on the font used by QStaticText. Since we don't care about line decorations or any other shapes drawn in the QTextLayout, we simply leave the implementation empty. Reviewed-by: Gunnar (cherry picked from commit 43f37074391b338b250883dfeb4a16844ca759fd)
* Fix last character being overwritten in password fieldShane Kearns2010-08-051-0/+4
| | | | | | | | | | | The temporary cursor position was not being updated after committing the input (changing the cleartext into a *), as a result of which, the next keypress was mistaken for a multitap input which should replace the last character. Task-number: QTBUG-11673 Reviewed-by: axis (cherry picked from commit 7acf2417bd2ae17c2e3c289c7caed84219e5fecd)
* Crash when pressing the '£' key on Belgian Keyboard layout (Cocoa)Prasanth Ullattil2010-08-041-3/+5
| | | | | | | | | | In some cases the NSKeyDown event won't have fully constructed string in the [NSEvent characters]. So we need to add a guard before accessing the elements of this NSString. Task-number: QTBUG-12474 Reviewed-by: Richard Moe Gustavsen (cherry picked from commit 307601da8d3b64de7b7d83a6de0b5dac290b0eb6)
* Fix Japanese characters not displayed in webkit on Mac Cocoa 64 (Regression)Simon Hausmann2010-08-041-3/+29
| | | | | | | | | | Our stringToCMap implementation for CoreText that bypasses the shaping needs to have basic support for font cascading / glyph substitution. We now use CTFontCreateForString to determine the substitute font for missing glyphs. Task-number: QTBUG-12411 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@nokia.com> (cherry picked from commit 00fb79714162ea3e434cf66a87a70a4fc26b2b86)
* Cocoa: Active QDockWidget does not stay on top of inactive QDockWidgetRichard Moe Gustavsen2010-08-043-0/+24
| | | | | | | | | | | | If a window has several child windows, it was not be possible to click on a child window to make it stack in front of the other children. The reason is that cocoa held a fixed stacking order of the child windows (sub-windows). This patch will release, and then reestablish, the stacking order of the children upon acitvation. Task-number: QTBUG-11780 Reviewed-by: prasanth (cherry picked from commit 44e11692549f1d6a4fed01066a06085dacfaa444)
* Ensure backing store is deleted before top-level windowGareth Stockwell2010-08-041-0/+4
| | | | | | | | | | | | If this is not done, later deletion of the backing store may cause a crash. If the backing store is an EGL surface, its destruction includes a call to eglDestroySurface(), which triggers an exception if the window handle passed as a parameter is no longer valid. Task-number: QTBUG-10643 Task-number: QTBUG-11376 Reviewed-by: Jason Barron (cherry picked from commit cc3c416682791e1a2fd61d9a473ba3b4715c502d)
* Fix the rendering of lines with the X11 paint engineBenjamin Poulain2010-08-031-12/+10
| | | | | | | | | | | | | | On the X11 paint engine, when rendering lines with float coordinates, the lines were one pixel off if the decimal was > 0.5. This fixes the WebKit bug https://bugs.webkit.org/show_bug.cgi?id=42248 Autotest by Yoann Lopes. Reviewed-by: Simon Hausmann Reviewed-by: Yoann Lopes Reviewed-by: Andreas Kling (cherry picked from commit ebbab30af417dfbf3df47dec15c0e2f8d6a30fa6)
* QFileDialog crashes when empty selectedFilter is set on Carbon.Prasanth Ullattil2010-08-021-3/+5
| | | | | | | | | We were making the wrong assumption that the selectedFilter string will be valid always, when calling functions like getSaveFileName(). Task-number: QTBUG-12461 Reviewed-by: Denis (cherry picked from commit fb47a99e1d0020e8dcc4cc4f9c188ccd2fd5ee3e)
* Remove use of shared NOTIFY signals in QGraphicsScaleMartin Jones2010-08-022-3/+9
| | | | | | | | | | Sharing a NOTIFY signal can cause binding loop warnings with no apparent cause. Task-number: QTBUG-12333 Reviewed-by: Aaron Kennedy Reviewed-by: Michael Brasser (cherry picked from commit 5d5feaa86f3933a1e89b53267953b86e2b0459ed)
* Fixed key event handling on Symbian.axis2010-08-022-55/+118
| | | | | | | | | | | | | | | After looking at QTBUG-11338 and Qt's behavior, it became clear that we needed more state tracking in the key event handling code, to be able to handle all the different ways that we can get key events. This inspired having three states for each used scan code, instead of the old code, which only took the current scan code into account. This should make Symbian behave identically to Linux. Task: QTBUG-11338 AutoTest: N/A, platform specific code. There was lots of manual testing on 5800, N97 and N95. RevBy: Jason Barron (cherry picked from commit 041570ca54824ee358593f112b38e26632c3ebbf)
* Cleaned up old comments.axis2010-08-021-12/+0
| | | | (cherry picked from commit 5a3246b198ced3634bd974919e78310d536be27e)
* Refactored the virtual mouse handling code into its own function.axis2010-08-022-171/+181
| | | | | RevBy: Trust me (cherry picked from commit 998ba966215482048f7fa93908212b1ee4a0c357)
* Fixed spelling mistakes in documented functions, classes, etc. Part of ↵Jerome Pasion2010-08-021-3/+3
| | | | | | QTBUG-11938 and QTBUG-10801 (cherry picked from commit 5bdb85e3b21bcf624eb1830aa32d027e0c6870fe)
* QMenu and QStyleSheetStyle: fix setting a border.Olivier Goffart2010-07-291-0/+7
| | | | | | | | | The native border would be drawn over the one drawn by the QStyleSheetStyle Regression since 68a498284e206e2bb000bc35331c966f3790f607 Reviewed-by: Gabriel Task-number: QTBUG-10785 (cherry picked from commit 0318f0d5a43a78831f3bf4cb043d0b2b41cd9987)
* Revert the change in applicationShouldTerminate().Fabien Freling2010-07-281-1/+0
| | | | | | | | | | | It used to fix an issue during logout but it seems to be fine now. Related issue: QTBUG-6296 Task-number: QTBUG-10993 Reviewed-by: Morten Sorvig (cherry picked from commit 4942890f85e5fa74bf8c37cf7f53f6f3eaf40596)
* Check the gesturemanager pointer before accessing it.Denis Dzyubenko2010-07-283-9/+12
| | | | | | | | | This fixes a crash when a static QWidget is destroyed after the QApplication object. Task-number: QTBUG-12025 Reviewed-by: Zeno Albisser (cherry picked from commit 475a3c275ba173cb130a838b6053cb45d405887e)
* Fix signal emission of QDesktopWidget on Symbian.Jason Barron2010-07-281-6/+16
| | | | | | | | | | | | | | | | | | | QDesktopWidget on Symbian was not properly emitting the resized() and the workAreaResized() signals. Qt was properly translating the system event and sending the QResizeEvent to the widget, but the signal emission is determined solely based on changes in the QVectors of QRects outlining the screen dimensions. On Symbian, these vectors were never being set and as a result the signals were never omitted. The fix is to set the rects correctly in the init() function which is called by the resizeEvent() handler. Also modify the accessor functions to return the rectangles stored in the vector instead of querying for them each time. Task-number: QTBUG-11433 Reviewed-by: axis Autotest: PASSES (cherry picked from commit 61908af46700c7c1f2e59ce98daeadc2529fef1b)
* Fix QLineEdit's Highlight color when inactive.Pierre Rossi2010-07-272-1/+12
| | | | | | | | | This commit also updates QPalette's documentation regarding the current ColorGroup and operator==. Task-number: QTBUG-697 Reviewed-by: ogoffart (cherry picked from commit 24cdab32de2abd8669f281dd54c8da1124514915)
* QML focus API updates.Michael Brasser2010-07-262-0/+13
| | | | | | | | | | The wantsFocus property has been renamed to activeFocus, to better reflect its value. Reading and writing the focus property is also now consistent -- this property represents focus within a scope. Other small changes were made to keep things consistent with the new naming. Reviewed-by: Aaron Kennedy (cherry picked from commit 21806ff0921641b4e4d9d39721ab4ebeae74dddc)
* doc: Added missing \since 4.7 to effect propertyu.Martin Smith2010-07-261-0/+1
| | | | | Task-number: QTBUG-12132 (cherry picked from commit d9f5b8742f84124c3c0e2bdbd7b860dce2bc2225)
* Drag & Drop failing in itemviews on Cocoa.Prasanth Ullattil2010-07-231-1/+4
| | | | | | | | | | While generating the QDragMoveEvent, we were always reusing the last drop action set by the user. This is not correct, we should copy the action only if a valid action set before. This is the behavior on Windows. Task-number: QTBUG-9486 Reviewed-by: Denis (cherry picked from commit 88410105978d5fb4344207cd5d296057ced0f27d)
* doc: Fix qdoc errors for text related filesEskil Abrahamsen Blomfeldt2010-07-222-4/+2
| | | | | | | | | QTextBlock::layoutDirection() doesn't exist, and the QStaticText constructor no longer takes a size argument. Task-number: QTBUG-12072 Reviewed-by: Fabien Freling (cherry picked from commit 04bc2b1f37750a2afbb88521001758249a8df383)
* QGraphicsItem: Animation leaves drawing artifacts when clipping is used.Bjørn Erik Nilsen2010-07-221-1/+6
| | | | | | | | | | | | | | | | | | This only happens when the ItemHasNoContents and ItemClipsChildrenToShape flags are set. Problem is that items with no content are threated as 'dummy' items, which means they are never drawn or 'processed' otherwise, so the cached bounding rect is not reliable/usable. This means that in case of changing the geometry of such items, its children always have to take care of invalidating the occupied areas and the update can not be clipped to the item's bounding rect. Regression after commit: c1c7dbf2 Auto test included. Task-number: QTBUG-11504 Reviewed-by: yoann (cherry picked from commit 4df9c96e2c213c39924e22e02621b0c61e83f8fe)
* Fixed a QSplashScreen hanging bug in S60 3.1 devices.axis2010-07-211-6/+14
| | | | | | | | | | | | | | | | | | | QSymbianBitmapDataAccess is used to provide access to the bitmap heap in a manner that locks correctly on all platform versions. The heapWasLocked variable was meant to protect against the case where the heap is locked recursively. However, it failed to take into account the case where the same QSymbianBitmapDataAccess object was used to lock recursively. In this case the variable would be changed to true on the second lock, which means that the lock would never be released again. This was fixed by making the access reference counted instead. Since the bitmap heap lock is global, the refcount was made global as well. Task: QTBUG-11129 RevBy: Jason Barron AutoTest: Works again. It was hanging before this fix. (cherry picked from commit d4cc1dcea5b4116767cfee0ec45bfba72dc011ff)
* Fix a Headerview layout bugPierre Rossi2010-07-211-1/+1
| | | | | | | | | When the sections were moved calling logicalIndex on what was already a logical index messed up the hidden sections. Task-number: QTBUG-12268 Reviewed-by: Gabriel (cherry picked from commit 8517f787b798d9e300438404aab359de2acc0978)
* Windows mobile: hide [X] button in task bar on unmaximizeJoerg Bornemann2010-07-183-0/+19
| | | | | | | | | | When calling showNormal on a window that was maximized, we must remove the [X] button from the task bar. But only if it was added by qt_wince_maximize. Task-number: QTBUG-8408 Reviewed-by: Martin Petersson (cherry picked from commit ad4aff6e2d188d88a2c6b4b692932adb08491d22)
* Windows mobile: the [X] button in the taskbar minimizes the widgetJoerg Bornemann2010-07-181-1/+1
| | | | | | | | | | | | The [X] or cancel button in the task bar shall just "minimize" the widget on Windows mobile. A press on this button results in a WM_COMMAND, IDCANCEL message. Before this patch we just sent a QCloseEvent to the widget, which had basically no effect. Now, we're calling showMinimzed(), which is the desired behaviour. Task-number: QTBUG-8408 Reviewed-by: Martin Petersson (cherry picked from commit 2c1aafa47b8915ea8aae8da229d65086e42543b3)
* Windows mobile: show the [X] button in the taskbar when maximizingJoerg Bornemann2010-07-181-0/+2
| | | | | | | | | | We're now showing the cancel button explicitly in the taskbar on maximize, if the widget does not have the widget flags CancelButtonHint and OKButtonHint. Task-number: QTBUG-8408 Reviewed-by: Martin Petersson (cherry picked from commit 5f76c2b168ded91835d5d161b738a5dc03556cf6)
* Amend previous commit 4e2eb2945dbc3865e2901f12d663ed89e8f0dfbf to fix ↵Olivier Goffart2010-07-174-4/+10
| | | | | | | | | | | | compilation with QT_NO_DEBUG_STREAM Qt in debug need to stay binary compatible with Qt in release. See also commit cbbd7e084c7e46fd906db26b13032b8368c59093 that introduced the problem Task-number: QTBUG-11510 (cherry picked from commit 633349982422fec92df4ed06da5d2becf788c494)
* Revert "Revert "Compile with QT_NO_DEBUG_STREAM""Jason McDonald2010-07-174-6/+8
| | | | | This reverts commit 5488e9213e1163ff7cadffd32cf8c8b94e88dbf1. A fix for the symbian build issue causing the revert is now available.
* Revert "Compile with QT_NO_DEBUG_STREAM"Jason McDonald2010-07-174-8/+6
| | | | | This reverts commit 734d4aff280f7f272a6abe8ed02fe95e2a1b4e6d, which was not accompanied by the necessary .def file update for symbian.