Bug 164955 - Create a way to use qt style sheets (qss) for theming/styles
Summary: Create a way to use qt style sheets (qss) for theming/styles
Status: RESOLVED INTENTIONAL
Alias: None
Product: kdelibs
Classification: Frameworks and Libraries
Component: kstyle (show other bugs)
Version: unspecified
Platform: Ubuntu Linux
: NOR wishlist
Target Milestone: ---
Assignee: Maksim Orlovich
URL:
Keywords:
: 454484 (view as bug list)
Depends on:
Blocks:
 
Reported: 2008-06-25 20:01 UTC by Iuri Fiedoruk
Modified: 2022-06-01 17:04 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Iuri Fiedoruk 2008-06-25 20:01:24 UTC
Version:            (using KDE 4.0.83)
Installed from:    Ubuntu Packages

Qt 4.2 introduced a new way for theming apps: using a style sheet file (qss) much like css for html: http://doc.trolltech.com/4.3/stylesheet-examples.html

Using this is much easier to create themes than coding a style in C++, and a much broader quantity of people will be able to create themes.

You can already run an application with --stylesheet (file.qss) option and it will theme it using the style sheet, but it does have some issues:
- the qss does not work in some parts because of the current style used in kde overrides it
- you can't set it globally to all launched kde apps without adding the --stylesheet command line option.

So, my wish is that and option in systemsettings->look&feel->style is added in witch user can pick a qss file to theme KDE apps and that kde reverts to some basic theme that does not interfere with the qss.

I do not think it's too hard to implement, but if any developer like the idea but does not have time to implement, I gladly would give a try if you provide me with directions :)
Comment 1 Maksim Orlovich 2008-06-26 00:54:21 UTC
Sorry, I wouldn't support features that are technically broken, no matter how cool.
Comment 2 Iuri Fiedoruk 2008-06-26 02:14:01 UTC
Could you please elaborate?
I'm not complaining about the WONTFIX, but rather I'm curious about the reason.
Thanks anyway.
Comment 3 Maksim Orlovich 2008-06-26 02:19:13 UTC
Essentially, the style API is woefully under-documented, and it's not clear what -exactly- things should be doing. There are no statements of invariants or anything like that. And the CSS stuff puts in an extra style proxy which intercepts some stuff from the native one, but not other stuff. However, there is nothing to guarantee that the rest will keep working. Essentially, I have no way of convincing myself that the system of the CSS proxy style + native style is doing anything sane; and it's impossible for a style writer to write a style that guarantees workability w/o studying all of Qt's widgets and the proxy. And it still might not work right with custom widget. And as a general rule, I do not make changes where I can't make a reasonable argument for correctness.

Comment 4 acidrums4 2013-01-20 15:38:51 UTC
So it's been 4 years and a half. At this very moment, how are things about this? I can't believe Razor-Qt has implemented this thing (http://fav.me/d4k4uar) and seem there's no news about it in KDE. Any plans for this? Will we ever see this?
Comment 5 Christoph Feck 2013-01-27 00:46:48 UTC
This feature will not be implemented, see comment #1 and comment #3.
Comment 6 acidrums4 2013-01-27 12:57:46 UTC
(In reply to comment #5)
Maybe I was not clear enough: Qt5 is on its way. I don't know if things about that CSS layering will still doing the same with native widgets, or rather CSS will be a way to customize widgets from native and not putting an extra layer above of them.
Comment 7 Eric Francis 2014-02-17 17:04:06 UTC
*** This bug has been confirmed by popular vote. ***
Comment 8 Nate Graham 2022-06-01 17:04:10 UTC
*** Bug 454484 has been marked as a duplicate of this bug. ***