How to change style-folder and colors of the theme itself?

Ask for help and post your question on how to use XnView MP.

Moderators: XnTriq, helmut, xnview

Exoner
Posts: 14
Joined: Mon Feb 27, 2023 4:03 pm

How to change style-folder and colors of the theme itself?

Post by Exoner »

Hello,

I use Version 1.6.5. I searched the forum but did not find the right answers. So here are my questions:

1. How can I set a custom folder for the style-files (style_sheet.qss etc.)? I can do this for the database, but how to set this for the styles, too? I want to place them in a folder that is part of my backup-workflow.

2. How can I change a default colour of the Dark theme? I have difficulties to read the black-on-blue colour-setting for a selected item (folder-list, thumbnail-list) and want to change both colours (maybe white on dark-grey).

3. I managed to set the appearence of the info-overlay in fullscreen-view (pressing key <I>). I have set some transparency there. How can I customise the tooltip that appears when hoovering over a thumbnail? I'm looking for some dark gray background (#666666) with some transparency and a white text-colour.

Thank you for your time :D

Keep healthy
User avatar
xnview
Author of XnView
Posts: 43611
Joined: Mon Oct 13, 2003 7:31 am
Location: France

Re: How to change style-folder and colors of the theme itself?

Post by xnview »

Exoner wrote: Sat Mar 30, 2024 2:30 pm 1. How can I set a custom folder for the style-files (style_sheet.qss etc.)? I can do this for the database, but how to set this for the styles, too? I want to place them in a folder that is part of my backup-workflow.
you need to change folderColor* in xnview.ini
2. How can I change a default colour of the Dark theme? I have difficulties to read the black-on-blue colour-setting for a selected item (folder-list, thumbnail-list) and want to change both colours (maybe white on dark-grey).
the blue color can't changed, it's from the system
3. I managed to set the appearence of the info-overlay in fullscreen-view (pressing key <I>). I have set some transparency there. How can I customise the tooltip that appears when hoovering over a thumbnail? I'm looking for some dark gray background (#666666) with some transparency and a white text-colour.
you can change QToolTip
Pierre.
Exoner
Posts: 14
Joined: Mon Feb 27, 2023 4:03 pm

Re: How to change style-folder and colors of the theme itself?

Post by Exoner »

Hello Pierre,

thank you for your answer, but it left me a little bit lost.

You wrote that the background-color of the active items (clicked as active) in listviews and thumbnail-views (currently black on blue in the dark-theme) are defined by WINDOWS itself. I'm on a dark theme in WINDOWS, but by default I get 'white on blue' for active items.

Is there really no chance to give selected items a light text-color, so that the text gets more readable?

I asked how to set a custom folder for the style-files (style_sheet.qss etc.). In fact I meant how to set a custom folder-path for this file like for the database. Sorry for the bad description of my goal. I want to put the styles-files in the same custom folder where my database resides.

I'm looking for a way to customise the appearence of the tooltip when hoovering over a thumbnail in the thumbnail-list-view. I have expanded the tooltip-information for a picture to get a larger tooltip with several lines of text. This works fine.

Currently the thumbnail-tooltip has the same color-settings like any other tooltip (buttons etc.), which currently is dark-grey on light-yellow. Maybe this is set by WINDOWS, too, I don't know.

Your suggestion was 'you can change QToolTip'.

But how do I do that?

I found QToolTip on line 972 in the styles-file 'style_sheet.qss'.

Code: Select all

QToolTip{
      background-color:  qlineargradient(x1:0, y1:0, x2:0, y2:1, stop:0 rgb(180, 180, 180), stop:1 rgb(150, 150, 150));
}
I'm familiar with CSS-code, but have difficulties to understand this color-code.

How do I change it to get

background-color: darkgray
color: white
opacity: 60%

Have a nice day.
Exoner
Posts: 14
Joined: Mon Feb 27, 2023 4:03 pm

Re: How to change style-folder and colors of the theme itself?

Post by Exoner »

Hello Pierre,

maybe I found a solution for the tooltip-colors.

Selecting View->Theme-Old dark opens an editor for the file styles_sheet.qss. Selecting this 'Old dark' theme gives me a basic dark-gray theme as a starting-point - including 'white on dark-grey' thumbnail-tooltips.

But my other questions are still relevant.
User avatar
Hakim Antoine Said
Posts: 187
Joined: Sat Feb 04, 2023 8:39 pm
Location: Earth XD

Re: How to change style-folder and colors of the theme itself?

Post by Hakim Antoine Said »

+1
Always Keep Going :wink: