Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dom0 GUI does not adhere to selected Xfce/Gtk theme #7389

Open
SvenSemmler opened this issue Mar 29, 2022 · 20 comments
Open

Dom0 GUI does not adhere to selected Xfce/Gtk theme #7389

SvenSemmler opened this issue Mar 29, 2022 · 20 comments
Labels
affects-4.1 This issue affects Qubes OS 4.1. affects-4.2 This issue affects Qubes OS 4.2. C: desktop-linux-xfce4 Support for XFCE4 diagnosed Technical diagnosis has been performed (see issue comments). P: major Priority: major. Between "default" and "critical" in severity. regression A bug in which a supported feature that worked in a prior Qubes OS release has stopped working. T: bug Type: bug report. A problem or defect resulting in unintended behavior in something that exists.

Comments

@SvenSemmler
Copy link

SvenSemmler commented Mar 29, 2022

How to file a helpful issue

The problem you're addressing (if any)

Starting with R4.1 some of the Qubes OS GUI uses QT5. One effect of this is, that by default those GUI do not adhere to the theme selected in XFCE. This is particularly an issue for users of dark themes.

The solution you'd like

This is quite easy to fix by installing qt5-qtsyleplugins in dom0 and exporting QT_QPA_PLATFORMTHEME=gtk2

The value to a user, and who that user might be

The XFCE/Gtk2 theme selected by the user applies to the Qubes OS GUI as it does to the rest of dom0

@SvenSemmler SvenSemmler added P: default Priority: default. Default priority for new issues, to be replaced given sufficient information. T: enhancement Type: enhancement. A new feature that does not yet exist or improvement of existing functionality. labels Mar 29, 2022
@DemiMarie DemiMarie added the ux User experience label Mar 29, 2022
@andrewdavidwong andrewdavidwong added the C: desktop-linux-xfce4 Support for XFCE4 label Mar 30, 2022
@andrewdavidwong andrewdavidwong added this to the Release TBD milestone Mar 30, 2022
@andrewdavidwong
Copy link
Member

Which Qubes GUI components are affected? Currently (in 4.1.1), it seems to me that only the Qube Manager is not adopting the selected system theme. (I do not have the new app menu yet.)

Does your solution fix the Qube Manager?

Are you seeing other GUI tools that are affected?

@quantumpacket
Copy link

Are you seeing other GUI tools that are affected?

From the Qubes Tools menu:

Backup Qubes
Create Qubes VM
Qubes Global Settings
Qubes Template Manager
Restore Backup

@andrewdavidwong
Copy link
Member

I see, thanks. Since this is technically a regression from 4.0, I think it might be more accurate to classify this as a bug.

@andrewdavidwong andrewdavidwong added T: bug Type: bug report. A problem or defect resulting in unintended behavior in something that exists. diagnosed Technical diagnosis has been performed (see issue comments). and removed T: enhancement Type: enhancement. A new feature that does not yet exist or improvement of existing functionality. ux User experience labels Jul 21, 2022
@andrewdavidwong andrewdavidwong modified the milestones: Release TBD, Release 4.1 updates Jul 21, 2022
@andrewdavidwong
Copy link
Member

andrewdavidwong commented Jul 21, 2022

This is quite easy to fix by installing qt5-qtsyleplugins in dom0 and exporting QT_QPA_PLATFORMTHEME=gtk2

Unfortunately, this did not work for me on 4.1.1. Various Qubes tools that were not obeying the system theme (including the Qube Manager) are unchanged.

I tried installing the package, then, in dom0:

export QT_QPA_PLATFORMTHEME=gtk2

Then restarting the Qube Manager and starting various tools.

I also tried adding the above to my .bash_profile in dom0 and then logging out and logging back in.

I also tried changing my theme in dom0 to something else and changing it back again.

Tried with the themes "Adwaita-dark," "Arc-Dark," and "Greybird-dark."

Also tried rebooting the whole system. Still no dice.

@SvenSemmler
Copy link
Author

SvenSemmler commented Jul 21, 2022 via email

@andrewdavidwong
Copy link
Member

Did you restart?

Yes. Also tried rebooting the whole system. Still no dice.

@SvenSemmler
Copy link
Author

SvenSemmler commented Jul 21, 2022 via email

@andrewdavidwong
Copy link
Member

Did you export in /etc/environment? Can you check ...

***@***.*** ~]$ cat /etc/environment
QT_QPA_PLATFORMTHEME=gtk2

That was the problem. Thanks!

I had just exported from my home directory. I didn't realize it had to be in /etc/environment.

FWIW, I wasn't familiar with that file, so I tried searching online for how to "export in /etc/environment," and the most helpful thing I found just said to edit it like any other text file, so I just used Vim to type it in manually. I have a feeling that this probably isn't the standard method, but it worked. 🤷

All the Qubes GUI tools are respecting the system theme now! Thanks again for your help. :)

@SvenSemmler
Copy link
Author

SvenSemmler commented Jul 21, 2022 via email

@andrewdavidwong
Copy link
Member

Unfortunately, I've found that closing the Qube Manager and reopening it causes it to revert to a light theme. I then have to log out of the desktop environment and log back in to fix it.

@quantumpacket
Copy link

I applied the fix and rebooted. All windows are now following the dark theme. Opening and closing the Qubes Manager still keeps the dark theme for me.

@andrewdavidwong
Copy link
Member

Increasing priority and pinning this issue, as a lot of users seem to be asking about it lately.

@andrewdavidwong andrewdavidwong added P: major Priority: major. Between "default" and "critical" in severity. and removed P: default Priority: default. Default priority for new issues, to be replaced given sufficient information. labels Jul 26, 2022
@andrewdavidwong andrewdavidwong pinned this issue Jul 26, 2022
@qufo418
Copy link

qufo418 commented Aug 4, 2022

Hi, I did a fresh install of 4.1.1 changed the theme etc, but the middle of the panel and some widgets aren't adhering to the dark theme (Adwaita Dark). The only way it works here (on two machines) is when I install 4.1.0 first and then simply apply all the updates.

@qufo418
Copy link

qufo418 commented Aug 4, 2022

Hi, I did a fresh install of 4.1.1 changed the theme etc, but the middle of the panel and some widgets aren't adhering to the dark theme (Adwaita Dark). The only way it works here (on two machines) is when I install 4.1.0 first and then simply apply all the updates.

Not anymore. It worked last week.
Now, the Application Menu, Separator, and the clock are not adhering to Adwaita Dark theme. I checked all the xfce / xfwm configs in dom0. I also compared the configs with my other machine where it still works. I can't find any differences.

@qufo418
Copy link

qufo418 commented Aug 5, 2022

Hi, I think I found the root cause and the fix:

Cause:

  1. xfsettingsd not running, although listed in Session and Startup.
  2. the text file ~/.cache/sessions/xfce-session-dom0:0 is missing.

Fix:

  1. Open terminal to dom0, and then:
  2. echo > ~/.cache/sessions/xfce4-session-dom0:0
  3. start xfsettingsd: xfsettingsd
  4. Logout with saving current session. On the logout dialog at the button tick the box.
  5. Login again; dark theme should be applied.

@andrewdavidwong andrewdavidwong added the affects-4.1 This issue affects Qubes OS 4.1. label Aug 8, 2023
@andrewdavidwong andrewdavidwong changed the title Make Qubes OS dom0 GUI adhere to selected XFCE/Gtk theme Dom0 GUI does not adhere to selected Xfce/Gtk theme Aug 13, 2023
@andrewdavidwong andrewdavidwong added the regression A bug in which a supported feature that worked in a prior Qubes OS release has stopped working. label Aug 13, 2023
@andrewdavidwong andrewdavidwong removed this from the Release 4.1 updates milestone Aug 13, 2023
@fepitre fepitre unpinned this issue Aug 26, 2023
@andrewdavidwong andrewdavidwong pinned this issue Aug 27, 2023
@Szewcson
Copy link

Szewcson commented Aug 29, 2023

In 4.2 some tools like Qubes Manager or Qubes Template Manager still not following chosen theme. Also workaround by using Qt5-styleplugins seems to be deprecated. Now there is only this error: Cannot mix incompatible Qt library (5.15.5) with this library (5.15.9), but probably there will be more problems in the future. Workaround with manual installing theme for QT applications seems not practical, and third workaround is hard coding theme in the tools...

@andrewdavidwong andrewdavidwong added the affects-4.2 This issue affects Qubes OS 4.2. label Aug 29, 2023
@andrewdavidwong andrewdavidwong unpinned this issue Jan 20, 2024
@jsadecki1
Copy link

I'm having problem getting this to work in Qubes 4.2, Its working for change the colour of dom0 file manger at least, but not the Qubes manager

Is there an updated workaround or method for this?

@quantumpacket
Copy link

quantumpacket commented Feb 10, 2024

@andrewdavidwong Should probably re-pin this as people upgrading to 4.2 are facing this issue.

@andrewdavidwong andrewdavidwong pinned this issue Feb 11, 2024
@bi0shacker001
Copy link

This might be related: changing the GTK theme in KDE does fix qubes manager in XFCE, but is also broken for KDE itself (fonts don't change in the settings app, but background colors do, for instance, which is why I can't use KDE and dark mode together now)
That's used for gtk applications, are we sure qubes-manager is actually using a qt thene, and not falling back to gtk?

@bi0shacker001
Copy link

Never mind, ignore me, I'm dumb, it's an effect of th QTSTYLEPLUGINS environmental variable I set as a workaround. bleh

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
affects-4.1 This issue affects Qubes OS 4.1. affects-4.2 This issue affects Qubes OS 4.2. C: desktop-linux-xfce4 Support for XFCE4 diagnosed Technical diagnosis has been performed (see issue comments). P: major Priority: major. Between "default" and "critical" in severity. regression A bug in which a supported feature that worked in a prior Qubes OS release has stopped working. T: bug Type: bug report. A problem or defect resulting in unintended behavior in something that exists.
Projects
None yet
Development

No branches or pull requests

8 participants