Summary: | Pushed button icon doesn't change in Oxygen theme | ||
---|---|---|---|
Product: | [Plasma] Oxygen | Reporter: | steveren <q.kde> |
Component: | style | Assignee: | Hugo Pereira Da Costa <hugo.pereira.da.costa> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | hugo.pereira.da.costa |
Priority: | NOR | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Platform: | unspecified | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: |
Description
steveren
2010-02-19 16:30:09 UTC
Interesting bug. I guess I could write a testcase similar to yours. But if your sources are too big, could you actually post them somewhere so that I'm sure we're comparing identical things ? (in the meanwhile I'll give it a shot on my side) Hugo Complete minimal QT Creator project here: http://www.tallegra.nildram.co.uk/bugtest.tar.gz Thanks a lot for the pointer. In fact since there is nothing in oxygen that plays with the button icon, I rather suspect a bug in kstyle (from which oxygen inherits, and plastique doesn't). Looking into it. SVN commit 1093328 by hpereiradacosta: Check on button state (On/Off) when chosing which icon is to be drawn in a push button. BUG: 227685 M +8 -2 kstyle.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=1093328 Well that was efficient :-) I'm a bit surprised that it wasn't spotted before, though. I'm an experienced programmer, but this was quite literally the first Linux GUI app I've ever written. Am I the only person to use icons on buttons that way, or the only person who uses a kstyle-derived theme? Since Oxygen inherits from KStyle, you are certainly not the only KStyle user :) But icons usually do not have a separate "On" state, so that bug remained unnoticed. actually, in terms of UI design, I always had a hard time understanding checkboxes (as in your example) that use two different icons for On and Off state. Because there is redundant (and sometime misleading) information in that thing: two different icons distinguish the two states of the button, which is already done by the visual on/off rendering (raised/or sunken). When I press on the sunken button with the second icon, do I negate (back to off state) the state corresponding to the second icon ? Or to the first ? (in your case you negate the state corresponding to the first icon, which effectively correspond to checking the state of the second icon, which contradicts the fact that the button goes from sunken to raised) (does that make sense ?) Would have been different if you had a regular button which changes icon each time you press on it ... Anyway: just my two cents, and anyway, this was a (now fixed) bug in kstyle and oxygen. |