Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 346331 - x11-themes/qgtkstyle-4.7.1-r1: KDE4 apps (e.g. kwrite) crash when GTK style is configured to be default
Summary: x11-themes/qgtkstyle-4.7.1-r1: KDE4 apps (e.g. kwrite) crash when GTK style i...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Qt Bug Alias
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-11-21 17:13 UTC by Sebastian Pipping
Modified: 2011-03-11 00:36 UTC (History)
6 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Sebastian Pipping gentoo-dev 2010-11-21 17:13:35 UTC
Scenario A:
- Run qtconfig
- Select GTK , save, quit
- Run kwrite
- Crash.

Scenario B:
- Run qtconfig
- Select anything but GTK, save, quit
- Run "kwrite -style=gtk"
- No crash.

revdep-rebuilds says nothing to do.
Re-emerging kwrite did not help.
Comment 1 Alex Alexander (RETIRED) gentoo-dev 2010-12-07 16:21:55 UTC
How about selecting GTK from systemsettings? I'm not sure qtconfig is the right place to set the style for KDE. Then again, I don't have KDE installed anywhere to try it myself.

Did this happen with qt-gui[gtk]?
Comment 2 Sebastian Pipping gentoo-dev 2010-12-07 17:12:37 UTC
(In reply to comment #1)
> How about selecting GTK from systemsettings? I'm not sure qtconfig is the right
> place to set the style for KDE. Then again, I don't have KDE installed anywhere
> to try it myself.

I would select it from there if I knew where to find that dialog: I use KDE apps in a XFCE system.


> Did this happen with qt-gui[gtk]?

x11-libs/qt-gui-4.7.1-r1 does not seem to have a use flag "gtk" any more.
Are you referring to my past usage or do you want me to test a particular scenario?
Comment 3 Tiziano Müller (RETIRED) gentoo-dev 2010-12-22 13:44:51 UTC
I can confirm this bug. Setting the style to GTK from within systemsettings gets ignored.
Only KDE-apps seem to crash, pure Qt-Applications run perfectly fine (for example VirtualBox) so far.

@sping: you would have to install the package systemsettings

Here's the start of a traceback for k9copy:

Program received signal SIGSEGV, Segmentation fault.
0x00007ffff5c53d30 in QPalette::setColorGroup (this=0x7fffff7ffab0, cg=QPalette::All, windowText=..., button=<value optimized out>, light=..., dark=..., mid=..., text=..., bright_text=..., base=..., window=...) at kernel/qpalette.cpp:1134
1134	    QBrush alt_base = QBrush(qt_mix_colors(base.color(), button.color()));
(gdb) bt
#0  0x00007ffff5c53d30 in QPalette::setColorGroup (this=0x7fffff7ffab0, cg=QPalette::All, windowText=..., button=<value optimized out>, light=..., dark=..., mid=..., text=..., bright_text=..., base=..., window=...) at kernel/qpalette.cpp:1134
#1  0x00007ffff5c54b57 in QPalette::QPalette (this=0x7fffff7ffab0, windowText=..., window=..., light=<value optimized out>, dark=..., mid=..., text=..., base=...) at kernel/qpalette.cpp:675
#2  0x00007ffff5f10175 in QStyle::standardPalette (this=<value optimized out>) at styles/qstyle.cpp:2242
#3  0x00007ffff5f8d119 in QCleanlooksStyle::standardPalette (this=<value optimized out>) at styles/qcleanlooksstyle.cpp:2377
#4  0x00007fffebebf7ed in QGtkStyle::standardPalette (this=<value optimized out>) at styles/qgtkstyle.cpp:222
#5  0x00007fffebec02c3 in QGtkStyle::polish (this=<value optimized out>, palette=...) at styles/qgtkstyle.cpp:305
#6  0x00007ffff5c273e6 in QApplicationPrivate::setPalette_helper (palette=..., className=0x7fffebf20275 "QMenu", clearWidgetPaletteHash=true) at kernel/qapplication.cpp:1802
#7  0x00007fffebed9257 in QGtkStylePrivate::applyCustomPaletteHash (this=0xe805d0) at styles/qgtkstyle_p.cpp:712
#8  0x00007fffebed9398 in QGtkStyleFilter::eventFilter (this=0xe80740, obj=<value optimized out>, e=<value optimized out>) at styles/qgtkstyle_p.cpp:262
#9  0x00007ffff54f85da in QCoreApplicationPrivate::sendThroughApplicationEventFilters (this=0xe2d0a0, receiver=0x7fffffffd6a0, event=0x7fffff800200) at kernel/qcoreapplication.cpp:828
#10 0x00007ffff5c241c6 in QApplicationPrivate::notify_helper (this=0xe2d0a0, receiver=0x7fffffffd6a0, e=0x7fffff800200) at kernel/qapplication.cpp:4420
#11 0x00007ffff5c28d1a in QApplication::notify (this=<value optimized out>, receiver=0x7fffffffd6a0, e=0x7fffff800200) at kernel/qapplication.cpp:4324
#12 0x00007ffff79c8f86 in KApplication::notify (this=0x7fffffffd6a0, receiver=0x7fffffffd6a0, event=0x7fffff800200) at /var/tmp/paludis/kde-base-kdelibs-4.5.4/work/kdelibs-4.5.4/kdeui/kernel/kapplication.cpp:310
#13 0x00007ffff54f851b in QCoreApplication::notifyInternal (this=0x7fffffffd6a0, receiver=0x7fffffffd6a0, event=0x7fffff800200) at kernel/qcoreapplication.cpp:732
#14 0x00007ffff5c274f0 in sendEvent (palette=..., className=0x7fffebf20275 "QMenu", clearWidgetPaletteHash=<value optimized out>) at ../../include/QtCore/../../src/corelib/kernel/qcoreapplication.h:215
#15 QApplicationPrivate::setPalette_helper (palette=..., className=0x7fffebf20275 "QMenu", clearWidgetPaletteHash=<value optimized out>) at kernel/qapplication.cpp:1825
[...]
Comment 4 Alex Alexander (RETIRED) gentoo-dev 2011-02-14 08:40:55 UTC
I just pushed an experimental version of qgtkstyle to the qting-edge overlay, can you test it please?
Comment 5 Tiziano Müller (RETIRED) gentoo-dev 2011-02-14 09:21:09 UTC
seriously? I don't have that repo/overlay and I don't want it.
So, if you think your commit fixes the problem, please push to the main tree and p.mask it.
Comment 6 Sergey Ilinykh 2011-02-21 11:01:38 UTC
Just tried qgtkstyle from qting-edge.
Qt Assistant crashes in setColorGroup as in trace above.

to reproduce just press ctrl+f

btw it started happening when qgtkstyle was moved into separate package or so.
Comment 7 Sergey Ilinykh 2011-02-25 12:24:08 UTC
I just manually compiled Qt-4.7.2 (from gitorius) and this bug is not reproducible with it (at least assistant doesnt crash). So either its fixed in 4.7.2 or gentoo does something wrong.

moreover my qgtkstyle was not compiled for some reason but plugin was loaded by new qt (the look of qt windows changed to native gtk). So since 4.7.2 loaded gtk plugin from 4.7.1 and everything worked fine I can assume they are binary compatible and the real problem is not in plugin but rather in qt-gui.
Comment 8 Sergey Ilinykh 2011-03-02 13:56:13 UTC
qgtkstyle-4.7.2 from portage still crashes qt apps.
so considering my previous post I think x11-libs/qt-gui needs to be fixed.
Comment 9 Sergey Ilinykh 2011-03-09 08:06:58 UTC
workaround:
remove "-no-gtkstyle" from qt-gui ebuild. this doesn't make gtkstyle plugin compile but Qt apps don't crash anymore.
Comment 10 Sergey Ilinykh 2011-03-09 10:50:19 UTC
I examined the code of qt-gui and I'm sure now that -no-gtkstyle is evil if we are going to use gtk style.
The only solution I see now is to move qgtkstyle back into qt-gui package and resolve cairo (or whatever) dependencies in some different way.
Comment 11 Alex Alexander (RETIRED) gentoo-dev 2011-03-10 00:35:02 UTC
I had a look at this again today and managed to make qt-gui[gtk] build with cairo[qt4] installed :)

So, as soon as the rest of the Qt team reviews my patches [including some eclass changes I'd like more eyes on] we'll ditch qgtkstyle and return to qt-gui with the gtk USE flag.

Thank you for all your input :)
Comment 12 Alex Alexander (RETIRED) gentoo-dev 2011-03-11 00:36:45 UTC
x11-libs/qt-gui-4.7.2 has reclaimed its gtk USE flag and is build-able alongside cairo[qt4].

this should bring an end to this problem :)