Search found 110 matches: qss

Searched query: qss

by Gail
Thu Sep 04, 2025 1:18 am
Forum: MP - General Support
Topic: Hide the XnViewMP title bar because the batch convert button is missing.(Lubuntu)
Replies: 0
Views: 412

Hide the XnViewMP title bar because the batch convert button is missing.(Lubuntu)

rc.xml is OpenBox setting,Path is /home/gail/.config/OpenBox,「gail」is my user name。

style_sheet.qss is XnViewMP UI setting,It is the same folder as xnview.ini。

OpenBox的設定檔rc.xml不能直接在"firmware-updater"後面加"firefox",因為今天要添加XnViewMP,網路沒教學,自己研究了一下。

於是rc.xml底部是這樣:
-->
<application name="firmware-updater">
<decor>no</decor>
</application>
<application class="firefox">
<decor>no</decor>
<maximized>true</maximized>
</application>
<application class="XnViewMP">
<decor>no</decor>
<maximized>true</maximized>
</application>
<application class="*">
<focus>yes</focus>
</application>

毋需重新登入,OpenBox開啟然後關閉即可。

之所以要添加XnViewMP,因為之前style_sheet.qss那樣更改,導致XnViewMP好用的「批次轉換」功能的「轉換」按鈕被擠到螢幕之外,我的螢幕解析度是1600*900,得改成1920*1080才找得到「轉換」按鈕,於是重寫style_sheet.qss

*{font-size:19pt;color:white;background-color:#0f3b02}
QStatusBar{max-height:38px;min-height:38px}
QWidget{max-height:900px;max-width:1600px}

但如此一來,狀態列只剩一半,「轉換」按鈕也只剩一半,找了半小時,終於找到原因——標題列~~

好吧!XnViewMP也隱藏標題列吧!反正ESC就可以全部關閉。

所以style_sheet.qss和rc.xml都更動了。

XnViewMP隱藏標題列後,狀態列和「轉換」按鈕都恢復正常了🎇

PS.XnViewMP若背景全黑,按鈕邊框很難察覺到,所以背景色改為深綠色#0f3b02,此方法雖然批次轉換的按鈕回來了,但設定區的「確定」按鈕卻被擠到螢幕外,只能暫時改成1920*1080才找得到~~~~

Windows有一套好用軟體ImageToPDForXPS,單純就是圖片打包成PDF而已;Lubuntu也有一套類似的叫img2pdf,但沒圖形界面,只能終端機下指令 img2pdf *.png -o output.pdf --pagesize 210mmx297mm,後來研究了一下,XnViewMP打包PNG會失敗,要先把PNG轉成JPG,打包成PDF就很容易成功,有可能是圖片透明度的關係。
by Gail
Tue Aug 26, 2025 12:35 pm
Forum: MP - General Support
Topic: Change XnViewMP UI Font Size in Lubuntu
Replies: 0
Views: 422

Change XnViewMP UI Font Size in Lubuntu

找了GTK、找了QT、找了OpenBox,找了SDDM,找不到XnView MP的UI字型放大的設定~~~

雖然網路上有人有教學,但那是舊版,新版要從「設定」,語系下的「預設」改為「自訂」,接著會跳出style_sheet.qss的框框。

style_sheet.qss這個檔案不在UI資料夾,而是和xnview.ini、xnview.sh同一個目錄。也就是說,UI資料夾的qss檔刪除是沒關係的。

研究了一下子,黑底白字並且大字體而且狀態列也清楚的,我參照他人的語法寫了自己的style_sheet.qss語法:

QWidget{font-size:19pt;color:white;background-color:black}
QTabBar{font-size:19pt;color:white;background-color:black}
MyTabBar{font-size:19pt;color:white;background-color:black}
QMenu,QMenuBar{ font-size:19pt;color:white;background-color:black}
QListView{font-size:19pt;color:white;background-color:black}
QTreeView{font-size:19pt;color:white;background-color:black}
QDockWidget > QTreeView{ font-size:19pt;color:white;background-color:black}
QStatusBar{max-height:38px;min-height:38px}

字型大小一律設19pt,狀態列高度設38px,可自行更改。

幸好字太小的問題終於解決,不然差點要改成Gwenview了~~

網頁樣式叫CSS,QT樣式叫QSS,同樣的方法或許也可以解決其他Appimage字太小的問題,例如繪圖軟體Krita……

https://attach.mobile01.com/attach/202508/mobile01-eacd1266ab256cee0d4ad06b8c550524.png

https://attach.mobile01.com/attach/202508/mobile01-54cc343067237798a7d415d5b9d78373.png
by Xn User
Thu Jul 24, 2025 6:08 pm
Forum: MP - General Support
Topic: Theme bug with XnView 1.92
Replies: 0
Views: 217

Theme bug with XnView 1.92

If do this :
in folder c:\Program Files\XnViewMP place this files
and next press F11 for view settings or manage database , so in final will uncorrect theme , before in version 1.80 and same this bug was absent

The cause of the manifestation of the error :
If in c:\Users\Username\AppData\Roaming\XnViewMP\
absent files :

style_sheet.qss
style_sheet_win.qss
xnview.ini

but this files available in folder with XnViewMP , so XnView MP will generate this files in

c:\Users\Username\AppData\Roaming\XnViewMP\

and because theme work not correctly

I offer do so , what if XnView detect files :

xnview.ini
style_sheet.qss
style_sheet_win.qss

in folder where install program , so use only this files and not will try write or use files in )

c:\Users\Username\AppData\Roaming\XnViewMP\
by Daimonicon
Tue Jun 24, 2025 1:01 pm
Forum: MP - General Support
Topic: XnViewMP category groups font size
Replies: 6
Views: 400

Re: XnViewMP category groups font size


currently there is some problem with non integer font scaling


Yes, I've heard that before - I think the whole operating system is an annoyance. So there's no option via the settings and because of these problems you don't plan to add this option I guess?

I almost managed to do it via the theme files (style_sheet.qss etc.). Could you maybe think about adding comments to a yxz.qss as an example that you can learn what is what or maybe a tutorial for this ? A suitable naming would also be helpful (style_sheet_default.qss, style_sheet_dark.qss, style_sheet_bright.qss).

In my case I urgently need the theme “hell” *de - presumably bright/light in english. Because this theme had the sharpest font display which is already helpful without changing the font size.
by Daimonicon
Thu Jun 19, 2025 7:56 am
Forum: MP - General Support
Topic: XnViewMP category groups font size
Replies: 6
Views: 400

XnViewMP category groups font size

Hello,

Is there a way to adjust the font size. I use the theme ‘hell’ (german) should be “hell” or ‘light’ in english. I can't get through this confusing mess regarding the stylexx~.qss.
by Primus
Sun Mar 23, 2025 4:48 pm
Forum: MP - General Support
Topic: Finding a color line in QSS
Replies: 0
Views: 240

Finding a color line in QSS

Hi. New to this forum, I've been using XnViewMp for years (Linux Mint) without any problems but I'm having a problem with the interface colors. I have activated the dark theme and I would like to know how to change colors #2 (25, 25, 25) to have color #1 (54, 54, 54).


copie.png


I've tried in the style sheet but can't get anywhere.

Thanks in advance.
by HanVroon
Wed Feb 19, 2025 9:31 am
Forum: MP - Suggestions
Topic: Qt Stylesheet Snippet Repository
Replies: 18
Views: 57863

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.
by HanVroon
Wed Feb 19, 2025 8:59 am
Forum: MP - General Support
Topic: Dark Theme with Custom Font Sizes
Replies: 1
Views: 2057

Re: Dark Theme with Custom Font Sizes

Looking for theme related topics I found this one, I can answer one question.

The only custom theme that can be edited by style sheet is "Old Dark".
After selecting this theme, two .qss files are copied from C:\Program Files\XnViewMP\UI to your profile.
Every setting in those two files override the "Default" theme, the other three themes (Light, Dark, Black) cannot be modified, they are hard coded.
The file style_sheet_win.qss only has a setting for combobox, aparently 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.
by HanVroon
Sat Dec 14, 2024 6:22 pm
Forum: MP - General Support
Topic: Change the colour of tabs
Replies: 2
Views: 1134

Re: Change the colour of tabs

Additional question:
There is a default file (I think):
C:\Program Files\XnViewMP\UI\style_sheet.qss

And the same file is in my profile directory (databases path).
To test I modified lots of colour values to see if anything changed, but XnView MP looks the same as before (with the default theme).
Does anyone know (and want to explain) how these stylesheets work?
by HanVroon
Thu Dec 12, 2024 7:29 pm
Forum: MP - General Support
Topic: Change the colour of tabs
Replies: 2
Views: 1134

Change the colour of tabs

Hello,

I thought it was possible to change default colours . I use the Default theme.
I red about stylesheets (*.qss files).
I have a style_sheet.qss and a style_sheet_win.qss in my profile.

I would like the colour of the active tab (for one file open) to be more different in colour that the oter tabs.
I can sometimes hardly see which tab is active.

I randomly tried changing values at several QTabBar::tab: entries, but nothing happens.
How do I change the background colour of the active tab?

Regards,
Han
by Lycus
Mon Jul 15, 2024 12:38 pm
Forum: MP - General [Français]
Topic: Changer couleur bouton groupe de catégories ?
Replies: 0
Views: 2270

Changer couleur bouton groupe de catégories ?

Bonjour,

Dans un premier temps, merci pour ce logiciel que j'utilise quasiment quotidiennement. J'aimerais savoir si il est possible de modifier la couleur de la police d'un bouton "Actif" dans l'onglet groupe de catégories. En effet, la lisibilité entre les boutons actifs et inactifs n'est pas très marqué avec le thème sombre :

Situation actuel : La catégorie fleure est attribuée.
https://i.ibb.co/sCFzrS2/01.png

Situation désiré : Exemple
https://i.ibb.co/2WGbDYw/02.png


J'ai trouvé comment modifier toutes les propriétés des boutons dans le fichier Style_Sheet.qss mais impossible de trouver la propriété qui change la couleur de la police dans un état "Actif".

Pour ceux qui sont intéressés (et google) dans la version 1.7.2, les boutons du "Groupe de catégories" portent le TAG : CategorySetPanel>QToolButton

Exemple : Passe le bouton en vert quand il est survolé par le curseur de la souris.
CategorySetPanel>QToolButton:hover {
background-color: green;
}



Exemple : Passe le bouton en jaune quand il est cliqué
CategorySetPanel>QPushButton:triger {
background-color: yellow;
}


Exemple : Changer la couleur du bouton en teinte RGB, la police en noire et la taille de police en 16 px.
CategorySetPanel>QToolButton {
background-color: rgb(240,240,240);
color: Black;
font-size: 16px;
}




Merci d'avance pour une réponse éventuelle, et bonne journée.
by Exoner
Tue Apr 02, 2024 12:06 pm
Forum: MP - General Support
Topic: How to change style-folder and colors of the theme itself?
Replies: 4
Views: 2462

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

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.
by Exoner
Tue Apr 02, 2024 11:39 am
Forum: MP - General Support
Topic: How to change style-folder and colors of the theme itself?
Replies: 4
Views: 2462

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

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'.

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.
by xnview
Mon Apr 01, 2024 2:37 pm
Forum: MP - General Support
Topic: How to change style-folder and colors of the theme itself?
Replies: 4
Views: 2462

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


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
by Exoner
Sat Mar 30, 2024 2:30 pm
Forum: MP - General Support
Topic: How to change style-folder and colors of the theme itself?
Replies: 4
Views: 2462

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

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