Unnamed repository; edit this file 'description' to name the repository.
Store theme mode when changed via mode 2031 (#15442)
This allows `:config-reload` to re-use the theme mode potentially modified by mode 2031. Before, `:config-reload` would always reset the theme to the variant detected at editor startup.
Jonas Köhnen 4 months ago
parent b3d6e35 · commit c48b181
-rw-r--r--helix-term/src/application.rs3
1 files changed, 2 insertions, 1 deletions
diff --git a/helix-term/src/application.rs b/helix-term/src/application.rs
index a082a7f7..f3b8f49f 100644
--- a/helix-term/src/application.rs
+++ b/helix-term/src/application.rs
@@ -729,11 +729,12 @@ impl Application {
}) => false,
#[cfg(not(windows))]
termina::Event::Csi(csi::Csi::Mode(csi::Mode::ReportTheme(mode))) => {
+ self.theme_mode = Some(mode.into());
Self::load_configured_theme(
&mut self.editor,
&self.config.load(),
&mut self.terminal,
- Some(mode.into()),
+ self.theme_mode,
);
true
}