Anyone by any chance has snipept that:
- restores classic order of FileMenu->Tab (cascading doen), in MP it is inverted
- simplifies tabs to as sleek as they are in Classic?
Oh wait nevermind, looks like there is no more theme support.
Qt Stylesheet Snippet Repository
Moderators: XnTriq, helmut, xnview
-
- XnThusiast
- Posts: 2231
- Joined: Sat May 09, 2015 9:37 am
Re: Qt Stylesheet Snippet Repository
What happened with themes in XnViewMP ?
Why it can't be done in the same way as other apps do, eg OBS:
../themes/theme_name/resources
../themes/theme_name.qss
Why it can't be done in the same way as other apps do, eg OBS:
../themes/theme_name/resources
../themes/theme_name.qss
-
- Posts: 225
- Joined: Thu Jan 28, 2010 7:30 am
Re: Qt Stylesheet Snippet Repository
What I have been missing in all the topics of this forum (or I might have overlooked something:-) is how we can use a custom theme.
What is this C:\Program Files\XnViewMP\UI\style_sheet.qss file doing and when does changing that file have effect.
Now that I found out, I create this post for anyone who is in the dark about how it works, like me.
Please let me know (Pierre?) if the below text is nonsense, then I will remove the post.
There are four default themes that can be choosen, Default, Light, Dark and Black.
The settings of those themes are hard coded, there are no stylesheets provided with XnViewMP for them. Perhaps they are from Qt itself.
For customisation there is the Old Dark theme, the fifth option in Browser, menu View, Theme.
If that theme is choosen, two files are copied from C:\Program Files\XnViewMP\UI to your profile: style_sheet.qss and style_sheet_win.qss.
Every setting in those two files override the "Default" theme, the other three themes (Light, Dark, Black) cannot be modified that way, they stay hard coded.
The file style_sheet_win.qss only has a setting for combobox, apparently because this setting should only be applied to the Windows version.
The Default theme is white, so that's why you get a white theme if your style_sheet.qss only has a few settings.
Looking at the modified date of the Old Dark stylesheet (style_sheet.qss), ik looks like Pierre updates this file with new options if needed.
So you could use this theme file as a refference how to address the parts of the GUI that you want to change.
Hope this helps.
If all I wrote is correct, it might be good to add these lines to the top of this topic as a reference.
What is this C:\Program Files\XnViewMP\UI\style_sheet.qss file doing and when does changing that file have effect.
Now that I found out, I create this post for anyone who is in the dark about how it works, like me.
Please let me know (Pierre?) if the below text is nonsense, then I will remove the post.
There are four default themes that can be choosen, Default, Light, Dark and Black.
The settings of those themes are hard coded, there are no stylesheets provided with XnViewMP for them. Perhaps they are from Qt itself.
For customisation there is the Old Dark theme, the fifth option in Browser, menu View, Theme.
If that theme is choosen, two files are copied from C:\Program Files\XnViewMP\UI to your profile: style_sheet.qss and style_sheet_win.qss.
Every setting in those two files override the "Default" theme, the other three themes (Light, Dark, Black) cannot be modified that way, they stay hard coded.
The file style_sheet_win.qss only has a setting for combobox, apparently because this setting should only be applied to the Windows version.
The Default theme is white, so that's why you get a white theme if your style_sheet.qss only has a few settings.
Looking at the modified date of the Old Dark stylesheet (style_sheet.qss), ik looks like Pierre updates this file with new options if needed.
So you could use this theme file as a refference how to address the parts of the GUI that you want to change.
Hope this helps.
If all I wrote is correct, it might be good to add these lines to the top of this topic as a reference.
-
- Moderator & Librarian
- Posts: 6457
- Joined: Sun Sep 25, 2005 3:00 am
- Location: Ref Desk
Re: Qt Stylesheet Snippet Repository
Great post, HanVroon!