From f2edb497ac2c3ff6f8c004046e216b8bdf7c4347 Mon Sep 17 00:00:00 2001 From: Jens Bache-Wiig Date: Wed, 8 Apr 2009 14:34:18 +0200 Subject: BT: Fix a painting glitch in gtk combo box This improves the look of combo box with gtk style which is somewhat a regression from 4.5.0 since we did not style this part before. Reviewed-by: nrc --- src/gui/styles/qgtkstyle.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/gui/styles/qgtkstyle.cpp b/src/gui/styles/qgtkstyle.cpp index b569b5c..519fed7 100644 --- a/src/gui/styles/qgtkstyle.cpp +++ b/src/gui/styles/qgtkstyle.cpp @@ -2507,6 +2507,10 @@ void QGtkStyle::drawControl(ControlElement element, if (selected) { QRect rect = option->rect.adjusted(0, 0, -1, -1); +#ifndef QT_NO_COMBOBOX + if (qobject_cast(widget)) + rect = option->rect; +#endif gtkPainter.paintBox( gtkMenuItem, "menuitem", rect, GTK_STATE_PRELIGHT, GTK_SHADOW_OUT, style); } -- cgit v0.12