rev 10207 - in trunk/packages/qt4-x11/debian: . patches
Fathi Boudra
fabo at alioth.debian.org
Sun Apr 20 16:24:37 UTC 2008
Author: fabo
Date: 2008-04-20 16:24:36 +0000 (Sun, 20 Apr 2008)
New Revision: 10207
Added:
trunk/packages/qt4-x11/debian/patches/0222-statusbar-recursion.diff
trunk/packages/qt4-x11/debian/patches/0223-fix-qpixmap-hasalpha.diff
trunk/packages/qt4-x11/debian/patches/0224-fast-qpixmap-fill.diff
trunk/packages/qt4-x11/debian/patches/0225-invalidate-tabbar-geometry-on-refresh.diff
Removed:
trunk/packages/qt4-x11/debian/patches/0191-listview-alternate-row-colors.diff
trunk/packages/qt4-x11/debian/patches/0192-itemdelegate-palette-state.diff
Modified:
trunk/packages/qt4-x11/debian/changelog
trunk/packages/qt4-x11/debian/patches/series
Log:
* Sync qt-copy patches:
* Remove 0191-listview-alternate-row-colors.diff
* Remove 0192-itemdelegate-palette-state.diff
* Add 0222-statusbar-recursion.diff
* Add 0223-fix-qpixmap-hasalpha.diff
* Add 0224-fast-qpixmap-fill.diff
* Add 0225-invalidate-tabbar-geometry-on-refresh.diff
Modified: trunk/packages/qt4-x11/debian/changelog
===================================================================
--- trunk/packages/qt4-x11/debian/changelog 2008-04-20 15:55:15 UTC (rev 10206)
+++ trunk/packages/qt4-x11/debian/changelog 2008-04-20 16:24:36 UTC (rev 10207)
@@ -4,6 +4,21 @@
* Add libqt4-sql-sqlite dependency to qt4-dev-tools. Qt Assistant and
qhelpgenerator use the sqlite plugin. (Closes: #476986)
+ * Remove qt-copy patches 0191 and 0192. The relevant code has changed
+ such that neither patch seems to have any effect (although listviews
+ still do not use active/inactive roles correctly).
+ * Add qt-copy patches:
+ * 0222-statusbar-recursion
+ This patch fixes random crashes due to paintevent
+ recursion and in once case a 100% startup crash (lyx).
+ * 0223-fix-qpixmap-hasalpha
+ Fix a performance regression in QPixmap::hasAlpha() in Qt 4.4.
+ * 0224-fast-qpixmap-fill
+ This patch avoids the expensive image->pixmap conversion by discarding
+ the old pixmap, creating a new one with the correct format, and doing
+ the fill server side.
+ * 0225-invalidate-tabbar-geometry-on-refresh
+ Fix problem where Konsole's tab bar is not shown immediately on startup.
+++ Changes by Modestas Vainius:
Deleted: trunk/packages/qt4-x11/debian/patches/0191-listview-alternate-row-colors.diff
Deleted: trunk/packages/qt4-x11/debian/patches/0192-itemdelegate-palette-state.diff
Added: trunk/packages/qt4-x11/debian/patches/0222-statusbar-recursion.diff
===================================================================
--- trunk/packages/qt4-x11/debian/patches/0222-statusbar-recursion.diff (rev 0)
+++ trunk/packages/qt4-x11/debian/patches/0222-statusbar-recursion.diff 2008-04-20 16:24:36 UTC (rev 10207)
@@ -0,0 +1,20 @@
+qt-bugs@ issue : N207415
+Trolltech task ID : 207597
+bugs.kde.org number : none
+applied: no
+author: Dirk Mueller <mueller at kde.org>
+
+This patch fixes random crashes due to paintevent
+recursion and in once case a 100% startup crash (lyx).
+
+--- a/src/gui/widgets/qstatusbar.cpp
++++ b/src/gui/widgets/qstatusbar.cpp
+@@ -643,7 +643,7 @@
+ }
+
+ emit messageChanged(d->tempItem);
+- repaint();
++ update();
+ }
+
+ /*!
Added: trunk/packages/qt4-x11/debian/patches/0223-fix-qpixmap-hasalpha.diff
===================================================================
--- trunk/packages/qt4-x11/debian/patches/0223-fix-qpixmap-hasalpha.diff (rev 0)
+++ trunk/packages/qt4-x11/debian/patches/0223-fix-qpixmap-hasalpha.diff 2008-04-20 16:24:36 UTC (rev 10207)
@@ -0,0 +1,26 @@
+qt-bugs@ issue : N206173
+Trolltech task ID : 206174
+bugs.kde.org number : none
+applied: yes
+author: Fredrik Höglund <fredrik at kde.org>
+
+Calling data->mask() in a pixmap that has an alpha channel causes
+the mask to be generated from the alpha channel. This is a very
+expensive operation, and completely unecessary in this case since
+the generated bitmap is immediately discarded.
+
+Fix the issue by reversing the order of the tests in the return
+statement, so the function returns true if the pixmap has an alpha
+channel, without generating the mask.
+
+--- a/src/gui/image/qpixmap.cpp
++++ b/src/gui/image/qpixmap.cpp
+@@ -1661,7 +1661,7 @@
+ */
+ bool QPixmap::hasAlpha() const
+ {
+- return (!data->mask().isNull() || data->hasAlphaChannel());
++ return (data->hasAlphaChannel() || !data->mask().isNull());
+ }
+
+ /*!
Added: trunk/packages/qt4-x11/debian/patches/0224-fast-qpixmap-fill.diff
===================================================================
--- trunk/packages/qt4-x11/debian/patches/0224-fast-qpixmap-fill.diff (rev 0)
+++ trunk/packages/qt4-x11/debian/patches/0224-fast-qpixmap-fill.diff 2008-04-20 16:24:36 UTC (rev 10207)
@@ -0,0 +1,46 @@
+qt-bugs@ issue : None
+Trolltech task ID : None
+bugs.kde.org number : None
+applied: yes
+author: Fredrik Höglund <fredrik at kde.org>
+
+Since there's no way to specify that a QPixmap should have an alpha channel
+when it's created, it's quite common to call pixmap.fill(Qt::transparent)
+immediately after creating it, to force Qt to recreate it with an alpha
+channel. Unfortunately QPixmap::fill() does this by creating a QImage,
+filling it with the specified color, and then converting it to a QPixmap.
+
+This patch avoids the expensive image->pixmap conversion by simply discarding
+the old pixmap, creating a new one with the correct format, and doing the
+fill server side.
+
+--- a/src/gui/image/qpixmap_x11.cpp
++++ b/src/gui/image/qpixmap_x11.cpp
+@@ -1107,7 +1107,26 @@
+ {
+ if (fillColor.alpha() != 255) {
+ #ifndef QT_NO_XRENDER
+- if (picture && d == 32) {
++ if (X11->use_xrender) {
++ if (!picture || d != 32) {
++ if (picture)
++ XRenderFreePicture(X11->display, picture);
++ if (mask_picture)
++ XRenderFreePicture(X11->display, mask_picture);
++ if (x11_mask)
++ XFreePixmap(X11->display, x11_mask);
++ if (hd)
++ XFreePixmap(X11->display, hd);
++ if (hd2)
++ XFreePixmap(X11->display, hd2);
++ XRenderPictFormat *format = XRenderFindStandardFormat(X11->display, PictStandardARGB32);
++ hd = XCreatePixmap(X11->display, RootWindow(X11->display, xinfo.screen()), width(), height(), 32);
++ picture = XRenderCreatePicture(X11->display, hd, format, 0, 0);
++ mask_picture = 0;
++ x11_mask = 0;
++ hd2 = 0;
++ d = 32;
++ }
+ ::Picture src = X11->getSolidFill(xinfo.screen(), fillColor);
+ XRenderComposite(X11->display, PictOpSrc, src, 0, picture,
+ 0, 0, width(), height(),
Added: trunk/packages/qt4-x11/debian/patches/0225-invalidate-tabbar-geometry-on-refresh.diff
===================================================================
--- trunk/packages/qt4-x11/debian/patches/0225-invalidate-tabbar-geometry-on-refresh.diff (rev 0)
+++ trunk/packages/qt4-x11/debian/patches/0225-invalidate-tabbar-geometry-on-refresh.diff 2008-04-20 16:24:36 UTC (rev 10207)
@@ -0,0 +1,33 @@
+qt-bugs@ issue : None
+Trolltech task ID : None
+bugs.kde.org number : 159014
+applied: yes
+author: Robert Knight <robertknight at gmail.com>
+
+When tabs are inserted or removed in a QTabBar, QTabBarPrivate::refresh()
+is called to update the layout. If the tabbar widget is hidden, this
+just sets a boolean variable (layoutDirty) and returns, so the parent widget's layout
+is not notified about the possible geometry change.
+
+Prior to Qt 4.4 this was not a problem because the geometry was recalculated
+in QTabBar::sizeHint() if the layoutDirty variable was set. In Qt 4.4 however the layout
+caches size hint information in QWidgetItemV2. Since the cache information is not invalidated,
+the layout may end up using out-of-date size hint information to compute the widget size.
+
+If the QTabBar is empty when QTabBar::sizeHint() is called, it will return a size with a height
+of 0, which will be kept in the cache and so the tab bar will never be shown.
+
+This patch fixes the problem by calling updateGeometry() whenever the tab bar's layout is refreshed.
+
+--- a/src/gui/widgets/qtabbar.cpp
++++ b/src/gui/widgets/qtabbar.cpp
+@@ -533,8 +533,8 @@
+ layoutTabs();
+ makeVisible(currentIndex);
+ q->update();
+- q->updateGeometry();
+ }
++ q->updateGeometry();
+ }
+
+ /*!
Modified: trunk/packages/qt4-x11/debian/patches/series
===================================================================
--- trunk/packages/qt4-x11/debian/patches/series 2008-04-20 15:55:15 UTC (rev 10206)
+++ trunk/packages/qt4-x11/debian/patches/series 2008-04-20 16:24:36 UTC (rev 10207)
@@ -1,8 +1,6 @@
# qt-copy patches
0167-fix-group-reading.diff
0180-window-role.diff
-0191-listview-alternate-row-colors.diff
-0192-itemdelegate-palette-state.diff
0195-compositing-properties.diff
0203-qtexthtmlparser-link-color.diff
0209-prevent-qt-mixing.diff
@@ -10,6 +8,10 @@
0214-fix-qgraphicsproxywidget-tab-crash.diff
0216-allow-isystem-for-headers.diff
0220-no-x-recursion-in-xerrhandler.diff
+0222-statusbar-recursion.diff
+0223-fix-qpixmap-hasalpha.diff
+0224-fast-qpixmap-fill.diff
+0225-invalidate-tabbar-geometry-on-refresh.diff
# debian patches
01_qmake_for_debian.diff
More information about the pkg-kde-commits
mailing list