From 6320b4d107e2c5cbc01f583568d630767b328abd Mon Sep 17 00:00:00 2001 From: Ottatop Date: Thu, 18 Apr 2024 16:45:31 -0500 Subject: [PATCH] Update default Rust config --- api/rust/examples/default_config/main.rs | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/api/rust/examples/default_config/main.rs b/api/rust/examples/default_config/main.rs index 3fc5319..7fa264c 100644 --- a/api/rust/examples/default_config/main.rs +++ b/api/rust/examples/default_config/main.rs @@ -1,3 +1,4 @@ +use pinnacle_api::input::libinput::LibinputSetting; use pinnacle_api::layout::{ CornerLayout, CornerLocation, CyclingLayoutManager, DwindleLayout, FairLayout, MasterSide, MasterStackLayout, SpiralLayout, @@ -57,6 +58,11 @@ async fn main() { pinnacle.quit(); }); + // `mod_key + alt + r` reloads the config + input.keybind([mod_key, Mod::Alt], 'r', || { + pinnacle.reload_config(); + }); + // `mod_key + alt + c` closes the focused window input.keybind([mod_key, Mod::Alt], 'c', || { if let Some(window) = window.get_focused() { @@ -244,6 +250,8 @@ async fn main() { }); } + input.set_libinput_setting(LibinputSetting::Tap(true)); + // Enable sloppy focus window.connect_signal(WindowSignal::PointerEnter(Box::new(|win| { win.set_focused(true);