aboutsummaryrefslogtreecommitdiff
path: root/example/init
diff options
context:
space:
mode:
authorIsaac Freund <ifreund@ifreund.xyz>2021-07-15 13:22:37 +0200
committerIsaac Freund <ifreund@ifreund.xyz>2021-07-20 10:48:11 +0200
commit2635f3299a77a89f4c09ec36c4110b21db0ea09f (patch)
treedaf9b24d79727a4d3f7d44dbace2843047a7db6f /example/init
parent96e1082156f8606f74c2414f7d7decf1ab6bbcda (diff)
downloadriver-2635f3299a77a89f4c09ec36c4110b21db0ea09f.tar.gz
river-2635f3299a77a89f4c09ec36c4110b21db0ea09f.tar.xz
river-layout: update to v3
- Remove advertise_view and advertise_done events. Using the information provided by these for any purpose would make the layout far less predictable. Futhermore, in the months this has been available for use, to my knowledge nobody has actually used it for anything useful. - Replace the set/mod layout value events with a single user_command event. This simplifies the protocol and is more flexible for clients. - Add a layout_name argument to the commit request. This name is an arbitrary, user-facing string that might, for example, be displayed by a status bar. This was present in early drafts of the protocol, but was removed in favor of river-options. Since river-options itself has since been removed and this feature is nice to have, re-add it. - Rename main factor to main ratio in rivertile. The "factor" name was just legacy from dwm, "ratio" is much more accurate.
Diffstat (limited to 'example/init')
-rwxr-xr-xexample/init20
1 files changed, 10 insertions, 10 deletions
diff --git a/example/init b/example/init
index 07e0347..886beae 100755
--- a/example/init
+++ b/example/init
@@ -40,13 +40,13 @@ riverctl map normal $mod+Shift Comma send-to-output previous
# Mod+Return to bump the focused view to the top of the layout stack
riverctl map normal $mod Return zoom
-# Mod+H and Mod+L to decrease/increase the main_factor value of rivertile by 0.05
-riverctl map normal $mod H mod-layout-value rivertile fixed main_factor -0.05
-riverctl map normal $mod L mod-layout-value rivertile fixed main_factor +0.05
+# Mod+H and Mod+L to decrease/increase the main ratio of rivertile(1)
+riverctl map normal $mod H send-layout-cmd rivertile "mod-main-ratio -0.05"
+riverctl map normal $mod L send-layout-cmd rivertile "mod-main-ratio +0.05"
-# Mod+Shift+H and Mod+Shift+L to increment/decrement the main_count value of rivertile.
-riverctl map normal $mod+Shift H mod-layout-value rivertile int main_count +1
-riverctl map normal $mod+Shift L mod-layout-value rivertile int main_count -1
+# Mod+Shift+H and Mod+Shift+L to increment/decrement the main count of rivertile(1)
+riverctl map normal $mod+Shift H send-layout-cmd rivertile "mod-main-count +1"
+riverctl map normal $mod+Shift L send-layout-cmd rivertile "mod-main-count -1"
# Mod+Alt+{H,J,K,L} to move views
riverctl map normal $mod+Mod1 H move left 100
@@ -102,10 +102,10 @@ riverctl map normal $mod Space toggle-float
riverctl map normal $mod F toggle-fullscreen
# Mod+{Up,Right,Down,Left} to change layout orientation
-riverctl map normal $mod Up set-layout-value rivertile string main_location top
-riverctl map normal $mod Right set-layout-value rivertile string main_location right
-riverctl map normal $mod Down set-layout-value rivertile string main_location bottom
-riverctl map normal $mod Left set-layout-value rivertile string main_location left
+riverctl map normal $mod Up send-layout-cmd rivertile "set-main-location top"
+riverctl map normal $mod Right send-layout-cmd rivertile "set-main-location right"
+riverctl map normal $mod Down send-layout-cmd rivertile "set-main-location bottom"
+riverctl map normal $mod Left send-layout-cmd rivertile "set-main-location left"
# Declare a passthrough mode. This mode has only a single mapping to return to
# normal mode. This makes it useful for testing a nested wayland compositor