-
Demo app uses theme.DarkTheme(): What would be the proper way to set the dark theme now? i'm on Fedora (SwayWM) and have to set it manually |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
The proper way is not net set it actually. Like the deprecation note says, it is deprecated because it ignores the user's proffered theme and it should be up to the user which theme they want to use, not the developer. We have added support for following the Dark Style Preference which means that a desktop environment supporting that FreeDesktop protocol should result in the application having the correct theme. In Rymdport, I use |
Beta Was this translation helpful? Give feedback.
The proper way is not net set it actually. Like the deprecation note says, it is deprecated because it ignores the user's proffered theme and it should be up to the user which theme they want to use, not the developer. We have added support for following the Dark Style Preference which means that a desktop environment supporting that FreeDesktop protocol should result in the application having the correct theme.
In Rymdport, I use
settings.NewSettings().LoadAppearanceScreen(window)
from"fyne.io/fyne/v2/cmd/fyne_settings/settings"
(see https://github.com/Jacalz/rymdport/blob/aaf2ff2a2d63228f5d4b7486952a4b0bf82e3f70/internal/ui/settings.go#L223C35-L223C79) to integrate the whole theme sect…