Add -reload-theme CLI flag to re-apply the current theme file (#860)

* Add -reload-theme CLI flag to re-apply theme via IPC

Sends a reload-theme IPC message to a running instance, causing it to
call fyne.CurrentApp().Settings().SetTheme(m.theme). Follows the same
callback pattern as -show (OnReactivate) and quit (OnExit).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* actually re-read theme file

---------

Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Drew Weymouth
2026-02-17 16:56:51 -08:00
committed by GitHub
co-authored by Claude Sonnet 4.6
parent 497c61e724
commit e21908cd24
8 changed files with 39 additions and 9 deletions
+1
View File
@@ -32,6 +32,7 @@ var (
FlagPauseAfterCurrent = flag.Bool("pause-after-current", false, "pause playback after current track")
FlagStartMinimized = flag.Bool("start-minimized", false, "start app minimized")
FlagShow = flag.Bool("show", false, "show minimized app")
FlagReloadTheme = flag.Bool("reload-theme", false, "reload the current theme")
FlagShuffle = flag.Bool("shuffle", false, "shuffle the tracklist (to be used with either -play-album-by-id or -play-playlist-by-id)")
FlagVersion = flag.Bool("version", false, "print app version and exit")
FlagHelp = flag.Bool("help", false, "print command line options and exit")