Setting the current theme via de D-Bus API #114
Replies: 3 comments
-
Some settings may not be applied immediately and require a restart of Audacious. Could you not do that in your script as some kind of workaround? Audacious itself calls the method below when changing the theme in the settings dialog, but probably not when using the D-Bus approach. audacious/src/libaudqt/prefs-window-qt.cc Lines 240 to 246 in a9d6280 audacious/src/libaudqt/dark-theme.cc Lines 136 to 149 in e2f07fb |
Beta Was this translation helpful? Give feedback.
-
The dbus call seems to go through I guess that I can add a check there and |
Beta Was this translation helpful? Give feedback.
-
This script triggers a couple of times a day automatically (e.g.: I don't run it manually). It would be kinda awkward since the new instance would interrupt whatever I'm doing at the time. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I'm trying to programatically change the theme. I want it to change to light mode at sunrise and dark mode and sundown. For this I am using
darkman
, which can just run a script of my choosing at the right time.To change the theme, I'm calling the D-Bus API exposed by audacious. When I change the theme, the setting gets updated, but the theme remains the same. I will elaborate further.
When running the following command:
If the current theme is the default, it prints
''
.If the current theme is the dark one, it prints
'dark'
This seems to confirm that I'm reading the right setting.
I can edit the setting with any of the following two commands:
When I edit the setting, and the open settings in audacious, the new value is selected in the combo. But the theme does not change. If I try to
ConfigGet
the theme setting, the updated value is also returned, but the theme that audacious is actually using does not match the value.I think that when I change the theme, audacious updates it's internal state of settings, but it doesn't apply the theme itself. Do I have to do something different, or have I stumbled across a bug?
Beta Was this translation helpful? Give feedback.
All reactions