diff --git a/komorebi/src/border_manager/mod.rs b/komorebi/src/border_manager/mod.rs index f59deebf..cfe125dd 100644 --- a/komorebi/src/border_manager/mod.rs +++ b/komorebi/src/border_manager/mod.rs @@ -43,7 +43,7 @@ lazy_static! { pub static ref Z_ORDER: AtomicCell = AtomicCell::new(ZOrder::Bottom); pub static ref STYLE: AtomicCell = AtomicCell::new(BorderStyle::System); pub static ref IMPLEMENTATION: AtomicCell = - AtomicCell::new(BorderImplementation::Windows); + AtomicCell::new(BorderImplementation::Komorebi); pub static ref FOCUSED: AtomicU32 = AtomicU32::new(u32::from(Colour::Rgb(Rgb::new(66, 165, 245)))); pub static ref UNFOCUSED: AtomicU32 = diff --git a/komorebi/src/static_config.rs b/komorebi/src/static_config.rs index 65483aae..26c47815 100644 --- a/komorebi/src/static_config.rs +++ b/komorebi/src/static_config.rs @@ -300,7 +300,7 @@ pub struct StaticConfig { /// Active window border z-order (default: System) #[serde(skip_serializing_if = "Option::is_none")] pub border_z_order: Option, - /// Display an active window border (default: false) + /// Active window border implementation (default: Komorebi) #[serde(skip_serializing_if = "Option::is_none")] pub border_implementation: Option, /// Add transparency to unfocused windows (default: false) diff --git a/komorebi/src/window_manager.rs b/komorebi/src/window_manager.rs index 61d3a6b6..8044f477 100644 --- a/komorebi/src/window_manager.rs +++ b/komorebi/src/window_manager.rs @@ -26,6 +26,7 @@ use crate::core::config_generation::MatchingRule; use crate::core::custom_layout::CustomLayout; use crate::core::Arrangement; use crate::core::Axis; +use crate::core::BorderImplementation; use crate::core::BorderStyle; use crate::core::CycleDirection; use crate::core::DefaultLayout; @@ -953,6 +954,7 @@ impl WindowManager { let no_titlebar = NO_TITLEBAR.lock(); let known_transparent_hwnds = transparency_manager::known_hwnds(); + let border_implementation = border_manager::IMPLEMENTATION.load(); for monitor in self.monitors_mut() { for workspace in monitor.workspaces_mut() { @@ -966,7 +968,9 @@ impl WindowManager { window.opaque()?; } - window.remove_accent()?; + if matches!(border_implementation, BorderImplementation::Windows) { + window.remove_accent()?; + } window.restore(); }