Merge pull request 'refactor(config)!: rename workspace up/down actions to prev/next' (#12) from refactor/workspace-prev-next into main
20 files · +133 -123
M README.md +8 -8
| @@ -261,14 +261,14 @@ bind.cmd+shift+s = toggle-window-stash | |||
| 261 | 261 | bind.cmd+o = toggle-overview | |
| 262 | 262 | ||
| 263 | 263 | # Workspaces | |
| 264 | - | bind.cmd+pageup = focus-workspace-up | |
| 265 | - | bind.cmd+pagedown = focus-workspace-down | |
| 266 | - | bind.cmd+shift+pageup = move-column-to-workspace-up | |
| 267 | - | bind.cmd+shift+pagedown = move-column-to-workspace-down | |
| 268 | - | bind.cmd+ctrl+shift+up = move-workspace-up | |
| 269 | - | bind.cmd+ctrl+shift+down = move-workspace-down | |
| 270 | - | bind.cmd+ctrl+shift+k = move-workspace-up | |
| 271 | - | bind.cmd+ctrl+shift+j = move-workspace-down | |
| 264 | + | bind.cmd+pageup = focus-workspace-prev | |
| 265 | + | bind.cmd+pagedown = focus-workspace-next | |
| 266 | + | bind.cmd+shift+pageup = move-column-to-workspace-prev | |
| 267 | + | bind.cmd+shift+pagedown = move-column-to-workspace-next | |
| 268 | + | bind.cmd+ctrl+shift+up = move-workspace-prev | |
| 269 | + | bind.cmd+ctrl+shift+down = move-workspace-next | |
| 270 | + | bind.cmd+ctrl+shift+k = move-workspace-prev | |
| 271 | + | bind.cmd+ctrl+shift+j = move-workspace-next | |
| 272 | 272 | bind.cmd+code:2 = focus-workspace 1 | |
| 273 | 273 | bind.cmd+code:3 = focus-workspace 2 | |
| 274 | 274 | bind.cmd+code:4 = focus-workspace 3 | |
| @@ -261,14 +261,14 @@ bind.cmd+shift+s = toggle-window-stash | |||||
| 261 | bind.cmd+o = toggle-overview | 261 | bind.cmd+o = toggle-overview | ||
| 262 | 262 | ||||
| 263 | # Workspaces | 263 | # Workspaces | ||
| 264 | - | bind.cmd+pageup = focus-workspace-up | 264 | + | bind.cmd+pageup = focus-workspace-prev |
| 265 | - | bind.cmd+pagedown = focus-workspace-down | 265 | + | bind.cmd+pagedown = focus-workspace-next |
| 266 | - | bind.cmd+shift+pageup = move-column-to-workspace-up | 266 | + | bind.cmd+shift+pageup = move-column-to-workspace-prev |
| 267 | - | bind.cmd+shift+pagedown = move-column-to-workspace-down | 267 | + | bind.cmd+shift+pagedown = move-column-to-workspace-next |
| 268 | - | bind.cmd+ctrl+shift+up = move-workspace-up | 268 | + | bind.cmd+ctrl+shift+up = move-workspace-prev |
| 269 | - | bind.cmd+ctrl+shift+down = move-workspace-down | 269 | + | bind.cmd+ctrl+shift+down = move-workspace-next |
| 270 | - | bind.cmd+ctrl+shift+k = move-workspace-up | 270 | + | bind.cmd+ctrl+shift+k = move-workspace-prev |
| 271 | - | bind.cmd+ctrl+shift+j = move-workspace-down | 271 | + | bind.cmd+ctrl+shift+j = move-workspace-next |
| 272 | bind.cmd+code:2 = focus-workspace 1 | 272 | bind.cmd+code:2 = focus-workspace 1 | ||
| 273 | bind.cmd+code:3 = focus-workspace 2 | 273 | bind.cmd+code:3 = focus-workspace 2 | ||
| 274 | bind.cmd+code:4 = focus-workspace 3 | 274 | bind.cmd+code:4 = focus-workspace 3 | ||
M docs/config.md +14 -14
| @@ -148,7 +148,7 @@ In scroll and fixed layouts with `natural-scroll = off`, a swipe left shows the | |||
| 148 | 148 | ||
| 149 | 149 | With `animations = off`, nothing moves during the swipe: when the fingers lift, a quick or long enough swipe navigates content or workspaces along the layout's axes. Cascade band swipes stop at the first and last band. | |
| 150 | 150 | ||
| 151 | - | Over the shown stash a sideways swipe slides it with the fingers, with a stop on each window, and moves one window at most. In scroll and fixed layouts where the view cannot scroll (a floating or fullscreen window, fixed overflow, or a named workspace), a quick swipe runs `focus-column-left/right` or `focus-workspace-up/down` when the fingers lift. Cascade keeps horizontal workspace navigation; vertical band swipes do nothing while a floating or fullscreen window has focus. | |
| 151 | + | Over the shown stash a sideways swipe slides it with the fingers, with a stop on each window, and moves one window at most. In scroll and fixed layouts where the view cannot scroll (a floating or fullscreen window, fixed overflow, or a named workspace), a quick swipe runs `focus-column-left/right` or `focus-workspace-prev/next` when the fingers lift. Cascade keeps horizontal workspace navigation; vertical band swipes do nothing while a floating or fullscreen window has focus. | |
| 152 | 152 | ||
| 153 | 153 | Two-finger scroll goes to the window under the pointer with the touchpad's timestamps, so apps with kinetic scrolling keep their inertia. | |
| 154 | 154 | ||
| @@ -194,7 +194,7 @@ Set `layout.overflow = cascade` globally, per output, or on a named workspace. C | |||
| 194 | 194 | ||
| 195 | 195 | Left/right focus follows column order across band boundaries. Up/down visits stacked windows first, then the closest column in the adjacent band. Column width presets and resizing do nothing; window height shares still apply. Maximizing a column hides its same-band siblings until focus moves or maximization ends. | |
| 196 | 196 | ||
| 197 | - | Three-finger vertical swipes scroll bands; horizontal swipes switch workspaces. Scroll and fixed workspaces retain their existing gesture axes. A switch keeps the source workspace's axis throughout its transition; the destination's axes apply to the next gesture. The `focus-workspace-up/down` commands still mean previous/next workspace, even when the transition is horizontal. Four-finger and stash gestures keep their existing behaviour. | |
| 197 | + | Three-finger vertical swipes scroll bands; horizontal swipes switch workspaces. Scroll and fixed workspaces retain their existing gesture axes. A switch keeps the source workspace's axis throughout its transition; the destination's axes apply to the next gesture. The `focus-workspace-prev/next` commands switch to the previous or next workspace, whether the transition is vertical or horizontal. Four-finger and stash gestures keep their existing behaviour. | |
| 198 | 198 | ||
| 199 | 199 | The overview presents bands side by side in one workspace card. Selecting a window reveals its band. Cascade supports dropping onto tiles, but not gap insertion or edge scrolling during a drag. | |
| 200 | 200 | ||
| @@ -219,13 +219,13 @@ The overview presents bands side by side in one workspace card. Selecting a wind | |||
| 219 | 219 | | `set-column-width <+N%\|-N%>` | Widen or narrow the focused column by N% of the usable width (1-100), between 10% and 100%. The new width stays until changed; `cycle-column-width` then restarts at the first preset. Does nothing in fixed overflow | | |
| 220 | 220 | | `set-window-height <+N%\|-N%>` | Give the focused window N% more or less of its column's height; the other rows give or take it in proportion. Each row keeps at least 10%. A window joining or leaving the column resets equal rows. Does nothing past 9 rows | | |
| 221 | 221 | | `consume-or-expel-window-left/right` | A lone window joins the neighbor column; a stacked one leaves for a new column | | |
| 222 | - | | `focus-workspace <N>` / `focus-workspace-up/down` | Show a numbered or neighbor workspace | | |
| 222 | + | | `focus-workspace <N>` / `focus-workspace-prev/next` | Show a numbered or neighbor workspace | | |
| 223 | 223 | | `workspace <name>` | Toggle a named workspace | | |
| 224 | - | | `move-column-to-workspace <N>` / `-up/-down` | Move the focused column | | |
| 225 | - | | `move-window-to-workspace <N>` / `-up/-down` | Move only the focused window | | |
| 224 | + | | `move-column-to-workspace <N>` / `-prev/-next` | Move the focused column | | |
| 225 | + | | `move-window-to-workspace <N>` / `-prev/-next` | Move only the focused window | | |
| 226 | 226 | | `focus-monitor-left/right` / `focus-monitor-up/down` | Focus the neighbor monitor in that direction | | |
| 227 | 227 | | `move-workspace-to-monitor-left/right` / `move-workspace-to-monitor-up/down` | Move the workspace to the neighbor monitor in that direction; it gets a new home | | |
| 228 | - | | `move-workspace-up/down` | Swap the current numbered workspace with its neighbor; the view follows it. It never passes the empty workspace at the end | | |
| 228 | + | | `move-workspace-prev/next` | Swap the current numbered workspace with its neighbor; the view follows it. It never passes the empty workspace at the end | | |
| 229 | 229 | | `scale-up` / `scale-down` | Zoom the whole display; one second after the last press, the scale is saved to `output.<name>.scale` and a notification confirms it (`notify-send`) | | |
| 230 | 230 | | `quit` | Exit NeferWL | | |
| 231 | 231 | ||
| @@ -257,7 +257,7 @@ The drop can be on another monitor; focus follows the window. There, the middle | |||
| 257 | 257 | ||
| 258 | 258 | ### Overview | |
| 259 | 259 | ||
| 260 | - | `toggle-overview` shows scaled previews of the current workspace, including over fullscreen windows, over a background darkened by `floating.dim`. Windows keep their size and previews show their last frames. Covering floats and windows hidden behind a maximized column in `fixed` overflow appear as cards: the on-screen item is in front, hidden columns share one spiral-layout card, up to two cards behind peek above it, and passed cards peek below. Neighbor workspaces show dimmed stacks. Each monitor has one vertical overview. A named workspace appears directly below the numbered workspace from which its `workspace <name>` bind was invoked. Invoking it from another numbered workspace updates this placement; browsing the overview does not. Several named workspaces attached to the same numbered workspace follow configuration order, with horizontal rules separating their group from numbered rows. Named-to-named binds reuse the source's numbered attachment. Unattached named workspaces follow the last occupied numbered row, or the first row if all numbered workspaces are empty. The selected workspace stays centred and its immediate neighbors appear above and below; rows and stash previews keep their full width. Empty workspaces are skipped unless currently selected or serving as the invocation anchor of a visible named row. Named workspaces remain outside the numbered list and normal workspace up/down navigation. Smaller floats, such as dialogs, stay hidden. A fullscreen floating window, or any fullscreen window with `fixed` overflow, is its workspace's front card, with the windows it hides behind it; `scroll` overflow keeps its columns selectable in one card. Choosing the fullscreen window keeps it fullscreen; choosing another window leaves fullscreen. | |
| 260 | + | `toggle-overview` shows scaled previews of the current workspace, including over fullscreen windows, over a background darkened by `floating.dim`. Windows keep their size and previews show their last frames. Covering floats and windows hidden behind a maximized column in `fixed` overflow appear as cards: the on-screen item is in front, hidden columns share one spiral-layout card, up to two cards behind peek above it, and passed cards peek below. Neighbor workspaces show dimmed stacks. Each monitor has one vertical overview. A named workspace appears directly below the numbered workspace from which its `workspace <name>` bind was invoked. Invoking it from another numbered workspace updates this placement; browsing the overview does not. Several named workspaces attached to the same numbered workspace follow configuration order, with horizontal rules separating their group from numbered rows. Named-to-named binds reuse the source's numbered attachment. Unattached named workspaces follow the last occupied numbered row, or the first row if all numbered workspaces are empty. The selected workspace stays centred and its immediate neighbors appear above and below; rows and stash previews keep their full width. Empty workspaces are skipped unless currently selected or serving as the invocation anchor of a visible named row. Named workspaces remain outside the numbered list and normal previous/next workspace navigation. Smaller floats, such as dialogs, stay hidden. A fullscreen floating window, or any fullscreen window with `fixed` overflow, is its workspace's front card, with the windows it hides behind it; `scroll` overflow keeps its columns selectable in one card. Choosing the fullscreen window keeps it fullscreen; choosing another window leaves fullscreen. | |
| 261 | 261 | ||
| 262 | 262 | | Key | Action | | |
| 263 | 263 | | --- | --- | | |
| @@ -266,7 +266,7 @@ The drop can be on another monitor; focus follows the window. There, the middle | |||
| 266 | 266 | | `return` | Show the selected front card; picking a hidden column moves the maximization to it. Other rows shown keep their focus, maximization and float order | | |
| 267 | 267 | | `escape` | Return to the original workspace; every row shown keeps its focus, maximization and float order | | |
| 268 | 268 | ||
| 269 | - | The focus binds (`focus-column-left/right`, `focus-window-up/down`, `cmd+arrows` by default) move the selection like these keys. In the overview, `focus-workspace-up/down` also traverse cards before crossing workspace rows, including named ones, except inside a selected stash pile. | |
| 269 | + | The focus binds (`focus-column-left/right`, `focus-window-up/down`, `cmd+arrows` by default) move the selection like these keys. In the overview, `focus-workspace-prev/next` also traverse cards before crossing workspace rows, including named ones, except inside a selected stash pile. | |
| 270 | 270 | ||
| 271 | 271 | Each workspace's [stash](#stash), hidden or not, shows as a pile of cards on the left of its row, which stays centred unless it would overlap the pile: its selected window in front, up to three others behind it, dimmed. In the pile, `k` / `j` or up/down browse stash cards and stop at either end without changing workspace. Right (`l`) leaves the pile immediately; left (`h`) stays in the pile. On a stash-only workspace, right deselects the pile so up/down can change workspace. Browsing brings the selected card to the front without reordering the stash. `return` or a click on a card closes the overview with the stash shown on that window. | |
| 272 | 272 | ||
| @@ -311,10 +311,10 @@ With `keyboard.cmd = alt`, the `cmd+alt+…` binds have the same keys as `cmd+ | |||
| 311 | 311 | | `cmd+q` | `close-window` | | |
| 312 | 312 | | `ctrl+alt+backspace` | `quit` | | |
| 313 | 313 | | `ctrl+cmd+space` | `spawn fuzzel` | | |
| 314 | - | | `cmd+pageup` | `focus-workspace-up` | | |
| 315 | - | | `cmd+pagedown` | `focus-workspace-down` | | |
| 316 | - | | `cmd+shift+pageup` | `move-column-to-workspace-up` | | |
| 317 | - | | `cmd+shift+pagedown` | `move-column-to-workspace-down` | | |
| 314 | + | | `cmd+pageup` | `focus-workspace-prev` | | |
| 315 | + | | `cmd+pagedown` | `focus-workspace-next` | | |
| 316 | + | | `cmd+shift+pageup` | `move-column-to-workspace-prev` | | |
| 317 | + | | `cmd+shift+pagedown` | `move-column-to-workspace-next` | | |
| 318 | 318 | | `cmd+code:2` | `focus-workspace 1` | | |
| 319 | 319 | | `cmd+code:3` | `focus-workspace 2` | | |
| 320 | 320 | | `cmd+code:4` | `focus-workspace 3` | | |
| @@ -343,7 +343,7 @@ With `keyboard.cmd = alt`, the `cmd+alt+…` binds have the same keys as `cmd+ | |||
| 343 | 343 | | `cmd+ctrl+shift+right` | `move-workspace-to-monitor-right` | | |
| 344 | 344 | | `cmd+ctrl+shift+h` | `move-workspace-to-monitor-left` | | |
| 345 | 345 | | `cmd+ctrl+shift+l` | `move-workspace-to-monitor-right` | | |
| 346 | - | | `cmd+ctrl+shift+up` / `cmd+ctrl+shift+k` | `move-workspace-up` | | |
| 347 | - | | `cmd+ctrl+shift+down` / `cmd+ctrl+shift+j` | `move-workspace-down` | | |
| 346 | + | | `cmd+ctrl+shift+up` / `cmd+ctrl+shift+k` | `move-workspace-prev` | | |
| 347 | + | | `cmd+ctrl+shift+down` / `cmd+ctrl+shift+j` | `move-workspace-next` | | |
| 348 | 348 | | `cmd+code:13` | `scale-up` | | |
| 349 | 349 | | `cmd+code:12` | `scale-down` | | |
| @@ -148,7 +148,7 @@ In scroll and fixed layouts with `natural-scroll = off`, a swipe left shows the | |||||
| 148 | 148 | ||||
| 149 | With `animations = off`, nothing moves during the swipe: when the fingers lift, a quick or long enough swipe navigates content or workspaces along the layout's axes. Cascade band swipes stop at the first and last band. | 149 | With `animations = off`, nothing moves during the swipe: when the fingers lift, a quick or long enough swipe navigates content or workspaces along the layout's axes. Cascade band swipes stop at the first and last band. | ||
| 150 | 150 | ||||
| 151 | - | Over the shown stash a sideways swipe slides it with the fingers, with a stop on each window, and moves one window at most. In scroll and fixed layouts where the view cannot scroll (a floating or fullscreen window, fixed overflow, or a named workspace), a quick swipe runs `focus-column-left/right` or `focus-workspace-up/down` when the fingers lift. Cascade keeps horizontal workspace navigation; vertical band swipes do nothing while a floating or fullscreen window has focus. | 151 | + | Over the shown stash a sideways swipe slides it with the fingers, with a stop on each window, and moves one window at most. In scroll and fixed layouts where the view cannot scroll (a floating or fullscreen window, fixed overflow, or a named workspace), a quick swipe runs `focus-column-left/right` or `focus-workspace-prev/next` when the fingers lift. Cascade keeps horizontal workspace navigation; vertical band swipes do nothing while a floating or fullscreen window has focus. |
| 152 | 152 | ||||
| 153 | Two-finger scroll goes to the window under the pointer with the touchpad's timestamps, so apps with kinetic scrolling keep their inertia. | 153 | Two-finger scroll goes to the window under the pointer with the touchpad's timestamps, so apps with kinetic scrolling keep their inertia. | ||
| 154 | 154 | ||||
| @@ -194,7 +194,7 @@ Set `layout.overflow = cascade` globally, per output, or on a named workspace. C | |||||
| 194 | 194 | ||||
| 195 | Left/right focus follows column order across band boundaries. Up/down visits stacked windows first, then the closest column in the adjacent band. Column width presets and resizing do nothing; window height shares still apply. Maximizing a column hides its same-band siblings until focus moves or maximization ends. | 195 | Left/right focus follows column order across band boundaries. Up/down visits stacked windows first, then the closest column in the adjacent band. Column width presets and resizing do nothing; window height shares still apply. Maximizing a column hides its same-band siblings until focus moves or maximization ends. | ||
| 196 | 196 | ||||
| 197 | - | Three-finger vertical swipes scroll bands; horizontal swipes switch workspaces. Scroll and fixed workspaces retain their existing gesture axes. A switch keeps the source workspace's axis throughout its transition; the destination's axes apply to the next gesture. The `focus-workspace-up/down` commands still mean previous/next workspace, even when the transition is horizontal. Four-finger and stash gestures keep their existing behaviour. | 197 | + | Three-finger vertical swipes scroll bands; horizontal swipes switch workspaces. Scroll and fixed workspaces retain their existing gesture axes. A switch keeps the source workspace's axis throughout its transition; the destination's axes apply to the next gesture. The `focus-workspace-prev/next` commands switch to the previous or next workspace, whether the transition is vertical or horizontal. Four-finger and stash gestures keep their existing behaviour. |
| 198 | 198 | ||||
| 199 | The overview presents bands side by side in one workspace card. Selecting a window reveals its band. Cascade supports dropping onto tiles, but not gap insertion or edge scrolling during a drag. | 199 | The overview presents bands side by side in one workspace card. Selecting a window reveals its band. Cascade supports dropping onto tiles, but not gap insertion or edge scrolling during a drag. | ||
| 200 | 200 | ||||
| @@ -219,13 +219,13 @@ The overview presents bands side by side in one workspace card. Selecting a wind | |||||
| 219 | | `set-column-width <+N%\|-N%>` | Widen or narrow the focused column by N% of the usable width (1-100), between 10% and 100%. The new width stays until changed; `cycle-column-width` then restarts at the first preset. Does nothing in fixed overflow | | 219 | | `set-column-width <+N%\|-N%>` | Widen or narrow the focused column by N% of the usable width (1-100), between 10% and 100%. The new width stays until changed; `cycle-column-width` then restarts at the first preset. Does nothing in fixed overflow | | ||
| 220 | | `set-window-height <+N%\|-N%>` | Give the focused window N% more or less of its column's height; the other rows give or take it in proportion. Each row keeps at least 10%. A window joining or leaving the column resets equal rows. Does nothing past 9 rows | | 220 | | `set-window-height <+N%\|-N%>` | Give the focused window N% more or less of its column's height; the other rows give or take it in proportion. Each row keeps at least 10%. A window joining or leaving the column resets equal rows. Does nothing past 9 rows | | ||
| 221 | | `consume-or-expel-window-left/right` | A lone window joins the neighbor column; a stacked one leaves for a new column | | 221 | | `consume-or-expel-window-left/right` | A lone window joins the neighbor column; a stacked one leaves for a new column | | ||
| 222 | - | | `focus-workspace <N>` / `focus-workspace-up/down` | Show a numbered or neighbor workspace | | 222 | + | | `focus-workspace <N>` / `focus-workspace-prev/next` | Show a numbered or neighbor workspace | |
| 223 | | `workspace <name>` | Toggle a named workspace | | 223 | | `workspace <name>` | Toggle a named workspace | | ||
| 224 | - | | `move-column-to-workspace <N>` / `-up/-down` | Move the focused column | | 224 | + | | `move-column-to-workspace <N>` / `-prev/-next` | Move the focused column | |
| 225 | - | | `move-window-to-workspace <N>` / `-up/-down` | Move only the focused window | | 225 | + | | `move-window-to-workspace <N>` / `-prev/-next` | Move only the focused window | |
| 226 | | `focus-monitor-left/right` / `focus-monitor-up/down` | Focus the neighbor monitor in that direction | | 226 | | `focus-monitor-left/right` / `focus-monitor-up/down` | Focus the neighbor monitor in that direction | | ||
| 227 | | `move-workspace-to-monitor-left/right` / `move-workspace-to-monitor-up/down` | Move the workspace to the neighbor monitor in that direction; it gets a new home | | 227 | | `move-workspace-to-monitor-left/right` / `move-workspace-to-monitor-up/down` | Move the workspace to the neighbor monitor in that direction; it gets a new home | | ||
| 228 | - | | `move-workspace-up/down` | Swap the current numbered workspace with its neighbor; the view follows it. It never passes the empty workspace at the end | | 228 | + | | `move-workspace-prev/next` | Swap the current numbered workspace with its neighbor; the view follows it. It never passes the empty workspace at the end | |
| 229 | | `scale-up` / `scale-down` | Zoom the whole display; one second after the last press, the scale is saved to `output.<name>.scale` and a notification confirms it (`notify-send`) | | 229 | | `scale-up` / `scale-down` | Zoom the whole display; one second after the last press, the scale is saved to `output.<name>.scale` and a notification confirms it (`notify-send`) | | ||
| 230 | | `quit` | Exit NeferWL | | 230 | | `quit` | Exit NeferWL | | ||
| 231 | 231 | ||||
| @@ -257,7 +257,7 @@ The drop can be on another monitor; focus follows the window. There, the middle | |||||
| 257 | 257 | ||||
| 258 | ### Overview | 258 | ### Overview | ||
| 259 | 259 | ||||
| 260 | - | `toggle-overview` shows scaled previews of the current workspace, including over fullscreen windows, over a background darkened by `floating.dim`. Windows keep their size and previews show their last frames. Covering floats and windows hidden behind a maximized column in `fixed` overflow appear as cards: the on-screen item is in front, hidden columns share one spiral-layout card, up to two cards behind peek above it, and passed cards peek below. Neighbor workspaces show dimmed stacks. Each monitor has one vertical overview. A named workspace appears directly below the numbered workspace from which its `workspace <name>` bind was invoked. Invoking it from another numbered workspace updates this placement; browsing the overview does not. Several named workspaces attached to the same numbered workspace follow configuration order, with horizontal rules separating their group from numbered rows. Named-to-named binds reuse the source's numbered attachment. Unattached named workspaces follow the last occupied numbered row, or the first row if all numbered workspaces are empty. The selected workspace stays centred and its immediate neighbors appear above and below; rows and stash previews keep their full width. Empty workspaces are skipped unless currently selected or serving as the invocation anchor of a visible named row. Named workspaces remain outside the numbered list and normal workspace up/down navigation. Smaller floats, such as dialogs, stay hidden. A fullscreen floating window, or any fullscreen window with `fixed` overflow, is its workspace's front card, with the windows it hides behind it; `scroll` overflow keeps its columns selectable in one card. Choosing the fullscreen window keeps it fullscreen; choosing another window leaves fullscreen. | 260 | + | `toggle-overview` shows scaled previews of the current workspace, including over fullscreen windows, over a background darkened by `floating.dim`. Windows keep their size and previews show their last frames. Covering floats and windows hidden behind a maximized column in `fixed` overflow appear as cards: the on-screen item is in front, hidden columns share one spiral-layout card, up to two cards behind peek above it, and passed cards peek below. Neighbor workspaces show dimmed stacks. Each monitor has one vertical overview. A named workspace appears directly below the numbered workspace from which its `workspace <name>` bind was invoked. Invoking it from another numbered workspace updates this placement; browsing the overview does not. Several named workspaces attached to the same numbered workspace follow configuration order, with horizontal rules separating their group from numbered rows. Named-to-named binds reuse the source's numbered attachment. Unattached named workspaces follow the last occupied numbered row, or the first row if all numbered workspaces are empty. The selected workspace stays centred and its immediate neighbors appear above and below; rows and stash previews keep their full width. Empty workspaces are skipped unless currently selected or serving as the invocation anchor of a visible named row. Named workspaces remain outside the numbered list and normal previous/next workspace navigation. Smaller floats, such as dialogs, stay hidden. A fullscreen floating window, or any fullscreen window with `fixed` overflow, is its workspace's front card, with the windows it hides behind it; `scroll` overflow keeps its columns selectable in one card. Choosing the fullscreen window keeps it fullscreen; choosing another window leaves fullscreen. |
| 261 | 261 | ||||
| 262 | | Key | Action | | 262 | | Key | Action | | ||
| 263 | | --- | --- | | 263 | | --- | --- | | ||
| @@ -266,7 +266,7 @@ The drop can be on another monitor; focus follows the window. There, the middle | |||||
| 266 | | `return` | Show the selected front card; picking a hidden column moves the maximization to it. Other rows shown keep their focus, maximization and float order | | 266 | | `return` | Show the selected front card; picking a hidden column moves the maximization to it. Other rows shown keep their focus, maximization and float order | | ||
| 267 | | `escape` | Return to the original workspace; every row shown keeps its focus, maximization and float order | | 267 | | `escape` | Return to the original workspace; every row shown keeps its focus, maximization and float order | | ||
| 268 | 268 | ||||
| 269 | - | The focus binds (`focus-column-left/right`, `focus-window-up/down`, `cmd+arrows` by default) move the selection like these keys. In the overview, `focus-workspace-up/down` also traverse cards before crossing workspace rows, including named ones, except inside a selected stash pile. | 269 | + | The focus binds (`focus-column-left/right`, `focus-window-up/down`, `cmd+arrows` by default) move the selection like these keys. In the overview, `focus-workspace-prev/next` also traverse cards before crossing workspace rows, including named ones, except inside a selected stash pile. |
| 270 | 270 | ||||
| 271 | Each workspace's [stash](#stash), hidden or not, shows as a pile of cards on the left of its row, which stays centred unless it would overlap the pile: its selected window in front, up to three others behind it, dimmed. In the pile, `k` / `j` or up/down browse stash cards and stop at either end without changing workspace. Right (`l`) leaves the pile immediately; left (`h`) stays in the pile. On a stash-only workspace, right deselects the pile so up/down can change workspace. Browsing brings the selected card to the front without reordering the stash. `return` or a click on a card closes the overview with the stash shown on that window. | 271 | Each workspace's [stash](#stash), hidden or not, shows as a pile of cards on the left of its row, which stays centred unless it would overlap the pile: its selected window in front, up to three others behind it, dimmed. In the pile, `k` / `j` or up/down browse stash cards and stop at either end without changing workspace. Right (`l`) leaves the pile immediately; left (`h`) stays in the pile. On a stash-only workspace, right deselects the pile so up/down can change workspace. Browsing brings the selected card to the front without reordering the stash. `return` or a click on a card closes the overview with the stash shown on that window. | ||
| 272 | 272 | ||||
| @@ -311,10 +311,10 @@ With `keyboard.cmd = alt`, the `cmd+alt+…` binds have the same keys as `cmd+ | |||||
| 311 | | `cmd+q` | `close-window` | | 311 | | `cmd+q` | `close-window` | | ||
| 312 | | `ctrl+alt+backspace` | `quit` | | 312 | | `ctrl+alt+backspace` | `quit` | | ||
| 313 | | `ctrl+cmd+space` | `spawn fuzzel` | | 313 | | `ctrl+cmd+space` | `spawn fuzzel` | | ||
| 314 | - | | `cmd+pageup` | `focus-workspace-up` | | 314 | + | | `cmd+pageup` | `focus-workspace-prev` | |
| 315 | - | | `cmd+pagedown` | `focus-workspace-down` | | 315 | + | | `cmd+pagedown` | `focus-workspace-next` | |
| 316 | - | | `cmd+shift+pageup` | `move-column-to-workspace-up` | | 316 | + | | `cmd+shift+pageup` | `move-column-to-workspace-prev` | |
| 317 | - | | `cmd+shift+pagedown` | `move-column-to-workspace-down` | | 317 | + | | `cmd+shift+pagedown` | `move-column-to-workspace-next` | |
| 318 | | `cmd+code:2` | `focus-workspace 1` | | 318 | | `cmd+code:2` | `focus-workspace 1` | | ||
| 319 | | `cmd+code:3` | `focus-workspace 2` | | 319 | | `cmd+code:3` | `focus-workspace 2` | | ||
| 320 | | `cmd+code:4` | `focus-workspace 3` | | 320 | | `cmd+code:4` | `focus-workspace 3` | | ||
| @@ -343,7 +343,7 @@ With `keyboard.cmd = alt`, the `cmd+alt+…` binds have the same keys as `cmd+ | |||||
| 343 | | `cmd+ctrl+shift+right` | `move-workspace-to-monitor-right` | | 343 | | `cmd+ctrl+shift+right` | `move-workspace-to-monitor-right` | | ||
| 344 | | `cmd+ctrl+shift+h` | `move-workspace-to-monitor-left` | | 344 | | `cmd+ctrl+shift+h` | `move-workspace-to-monitor-left` | | ||
| 345 | | `cmd+ctrl+shift+l` | `move-workspace-to-monitor-right` | | 345 | | `cmd+ctrl+shift+l` | `move-workspace-to-monitor-right` | | ||
| 346 | - | | `cmd+ctrl+shift+up` / `cmd+ctrl+shift+k` | `move-workspace-up` | | 346 | + | | `cmd+ctrl+shift+up` / `cmd+ctrl+shift+k` | `move-workspace-prev` | |
| 347 | - | | `cmd+ctrl+shift+down` / `cmd+ctrl+shift+j` | `move-workspace-down` | | 347 | + | | `cmd+ctrl+shift+down` / `cmd+ctrl+shift+j` | `move-workspace-next` | |
| 348 | | `cmd+code:13` | `scale-up` | | 348 | | `cmd+code:13` | `scale-up` | | ||
| 349 | | `cmd+code:12` | `scale-down` | | 349 | | `cmd+code:12` | `scale-down` | | ||
M examples/config +9 -9
| @@ -182,17 +182,17 @@ bind.ctrl+cmd+space = spawn fuzzel | |||
| 182 | 182 | ||
| 183 | 183 | # Workspaces stack vertically; numbers follow their order. An empty one always | |
| 184 | 184 | # waits below the last. cmd+up/down past the column edge also switch workspace. | |
| 185 | - | bind.cmd+pageup = focus-workspace-up | |
| 186 | - | bind.cmd+pagedown = focus-workspace-down | |
| 185 | + | bind.cmd+pageup = focus-workspace-prev | |
| 186 | + | bind.cmd+pagedown = focus-workspace-next | |
| 187 | 187 | # move-column-to-workspace moves the whole column; move-window-to-workspace | |
| 188 | - | # (N, -up, -down) moves only the focused window and has no default bind. | |
| 189 | - | bind.cmd+shift+pageup = move-column-to-workspace-up | |
| 190 | - | bind.cmd+shift+pagedown = move-column-to-workspace-down | |
| 188 | + | # (N, -prev, -next) moves only the focused window and has no default bind. | |
| 189 | + | bind.cmd+shift+pageup = move-column-to-workspace-prev | |
| 190 | + | bind.cmd+shift+pagedown = move-column-to-workspace-next | |
| 191 | 191 | # Reorder workspaces: swap the current one with its neighbor. | |
| 192 | - | bind.cmd+ctrl+shift+up = move-workspace-up | |
| 193 | - | bind.cmd+ctrl+shift+down = move-workspace-down | |
| 194 | - | bind.cmd+ctrl+shift+k = move-workspace-up | |
| 195 | - | bind.cmd+ctrl+shift+j = move-workspace-down | |
| 192 | + | bind.cmd+ctrl+shift+up = move-workspace-prev | |
| 193 | + | bind.cmd+ctrl+shift+down = move-workspace-next | |
| 194 | + | bind.cmd+ctrl+shift+k = move-workspace-prev | |
| 195 | + | bind.cmd+ctrl+shift+j = move-workspace-next | |
| 196 | 196 | bind.cmd+code:2 = focus-workspace 1 | |
| 197 | 197 | bind.cmd+code:3 = focus-workspace 2 | |
| 198 | 198 | bind.cmd+code:4 = focus-workspace 3 | |
| @@ -182,17 +182,17 @@ bind.ctrl+cmd+space = spawn fuzzel | |||||
| 182 | 182 | ||||
| 183 | # Workspaces stack vertically; numbers follow their order. An empty one always | 183 | # Workspaces stack vertically; numbers follow their order. An empty one always | ||
| 184 | # waits below the last. cmd+up/down past the column edge also switch workspace. | 184 | # waits below the last. cmd+up/down past the column edge also switch workspace. | ||
| 185 | - | bind.cmd+pageup = focus-workspace-up | 185 | + | bind.cmd+pageup = focus-workspace-prev |
| 186 | - | bind.cmd+pagedown = focus-workspace-down | 186 | + | bind.cmd+pagedown = focus-workspace-next |
| 187 | # move-column-to-workspace moves the whole column; move-window-to-workspace | 187 | # move-column-to-workspace moves the whole column; move-window-to-workspace | ||
| 188 | - | # (N, -up, -down) moves only the focused window and has no default bind. | 188 | + | # (N, -prev, -next) moves only the focused window and has no default bind. |
| 189 | - | bind.cmd+shift+pageup = move-column-to-workspace-up | 189 | + | bind.cmd+shift+pageup = move-column-to-workspace-prev |
| 190 | - | bind.cmd+shift+pagedown = move-column-to-workspace-down | 190 | + | bind.cmd+shift+pagedown = move-column-to-workspace-next |
| 191 | # Reorder workspaces: swap the current one with its neighbor. | 191 | # Reorder workspaces: swap the current one with its neighbor. | ||
| 192 | - | bind.cmd+ctrl+shift+up = move-workspace-up | 192 | + | bind.cmd+ctrl+shift+up = move-workspace-prev |
| 193 | - | bind.cmd+ctrl+shift+down = move-workspace-down | 193 | + | bind.cmd+ctrl+shift+down = move-workspace-next |
| 194 | - | bind.cmd+ctrl+shift+k = move-workspace-up | 194 | + | bind.cmd+ctrl+shift+k = move-workspace-prev |
| 195 | - | bind.cmd+ctrl+shift+j = move-workspace-down | 195 | + | bind.cmd+ctrl+shift+j = move-workspace-next |
| 196 | bind.cmd+code:2 = focus-workspace 1 | 196 | bind.cmd+code:2 = focus-workspace 1 | ||
| 197 | bind.cmd+code:3 = focus-workspace 2 | 197 | bind.cmd+code:3 = focus-workspace 2 | ||
| 198 | bind.cmd+code:4 = focus-workspace 3 | 198 | bind.cmd+code:4 = focus-workspace 3 | ||
M internal/adapters/config/config.go +14 -14
| @@ -46,10 +46,10 @@ var defaultBinds = []struct{ combo, action string }{ | |||
| 46 | 46 | {"cmd+q", "close-window"}, | |
| 47 | 47 | {"ctrl+alt+backspace", "quit"}, | |
| 48 | 48 | {"ctrl+cmd+space", "spawn fuzzel"}, | |
| 49 | - | {"cmd+pageup", "focus-workspace-up"}, | |
| 50 | - | {"cmd+pagedown", "focus-workspace-down"}, | |
| 51 | - | {"cmd+shift+pageup", "move-column-to-workspace-up"}, | |
| 52 | - | {"cmd+shift+pagedown", "move-column-to-workspace-down"}, | |
| 49 | + | {"cmd+pageup", "focus-workspace-prev"}, | |
| 50 | + | {"cmd+pagedown", "focus-workspace-next"}, | |
| 51 | + | {"cmd+shift+pageup", "move-column-to-workspace-prev"}, | |
| 52 | + | {"cmd+shift+pagedown", "move-column-to-workspace-next"}, | |
| 53 | 53 | {"cmd+ctrl+left", "focus-monitor-left"}, | |
| 54 | 54 | {"cmd+ctrl+right", "focus-monitor-right"}, | |
| 55 | 55 | {"cmd+ctrl+up", "focus-monitor-up"}, | |
| @@ -62,8 +62,8 @@ var defaultBinds = []struct{ combo, action string }{ | |||
| 62 | 62 | {"cmd+alt+right", "set-column-width +10%"}, | |
| 63 | 63 | {"cmd+alt+up", "set-window-height -10%"}, | |
| 64 | 64 | {"cmd+alt+down", "set-window-height +10%"}, | |
| 65 | - | {"cmd+ctrl+shift+up", "move-workspace-up"}, | |
| 66 | - | {"cmd+ctrl+shift+down", "move-workspace-down"}, | |
| 65 | + | {"cmd+ctrl+shift+up", "move-workspace-prev"}, | |
| 66 | + | {"cmd+ctrl+shift+down", "move-workspace-next"}, | |
| 67 | 67 | {"cmd+shift+space", "toggle-floating"}, | |
| 68 | 68 | } | |
| 69 | 69 | var actions = map[string]bool{ | |
| @@ -77,12 +77,12 @@ var actions = map[string]bool{ | |||
| 77 | 77 | "move-workspace-to-monitor-down": true, | |
| 78 | 78 | "scale-up": true, | |
| 79 | 79 | "scale-down": true, | |
| 80 | - | "focus-workspace-up": true, | |
| 81 | - | "focus-workspace-down": true, | |
| 82 | - | "move-column-to-workspace-up": true, | |
| 83 | - | "move-column-to-workspace-down": true, | |
| 84 | - | "move-window-to-workspace-up": true, | |
| 85 | - | "move-window-to-workspace-down": true, | |
| 80 | + | "focus-workspace-prev": true, | |
| 81 | + | "focus-workspace-next": true, | |
| 82 | + | "move-column-to-workspace-prev": true, | |
| 83 | + | "move-column-to-workspace-next": true, | |
| 84 | + | "move-window-to-workspace-prev": true, | |
| 85 | + | "move-window-to-workspace-next": true, | |
| 86 | 86 | "none": true, | |
| 87 | 87 | "consume-or-expel-window-left": true, | |
| 88 | 88 | "consume-or-expel-window-right": true, | |
| @@ -103,8 +103,8 @@ var actions = map[string]bool{ | |||
| 103 | 103 | "quit": true, | |
| 104 | 104 | "move-window-up": true, | |
| 105 | 105 | "move-window-down": true, | |
| 106 | - | "move-workspace-up": true, | |
| 107 | - | "move-workspace-down": true, | |
| 106 | + | "move-workspace-prev": true, | |
| 107 | + | "move-workspace-next": true, | |
| 108 | 108 | "toggle-floating": true, | |
| 109 | 109 | } | |
| 110 | 110 | var components = map[string]bool{"core": true, "wayland": true, "input": true, "drm": true, "seat": true, "render": true, "sync": true, "config": true, "app": true} | |
| @@ -46,10 +46,10 @@ var defaultBinds = []struct{ combo, action string }{ | |||||
| 46 | {"cmd+q", "close-window"}, | 46 | {"cmd+q", "close-window"}, | ||
| 47 | {"ctrl+alt+backspace", "quit"}, | 47 | {"ctrl+alt+backspace", "quit"}, | ||
| 48 | {"ctrl+cmd+space", "spawn fuzzel"}, | 48 | {"ctrl+cmd+space", "spawn fuzzel"}, | ||
| 49 | - | {"cmd+pageup", "focus-workspace-up"}, | 49 | + | {"cmd+pageup", "focus-workspace-prev"}, |
| 50 | - | {"cmd+pagedown", "focus-workspace-down"}, | 50 | + | {"cmd+pagedown", "focus-workspace-next"}, |
| 51 | - | {"cmd+shift+pageup", "move-column-to-workspace-up"}, | 51 | + | {"cmd+shift+pageup", "move-column-to-workspace-prev"}, |
| 52 | - | {"cmd+shift+pagedown", "move-column-to-workspace-down"}, | 52 | + | {"cmd+shift+pagedown", "move-column-to-workspace-next"}, |
| 53 | {"cmd+ctrl+left", "focus-monitor-left"}, | 53 | {"cmd+ctrl+left", "focus-monitor-left"}, | ||
| 54 | {"cmd+ctrl+right", "focus-monitor-right"}, | 54 | {"cmd+ctrl+right", "focus-monitor-right"}, | ||
| 55 | {"cmd+ctrl+up", "focus-monitor-up"}, | 55 | {"cmd+ctrl+up", "focus-monitor-up"}, | ||
| @@ -62,8 +62,8 @@ var defaultBinds = []struct{ combo, action string }{ | |||||
| 62 | {"cmd+alt+right", "set-column-width +10%"}, | 62 | {"cmd+alt+right", "set-column-width +10%"}, | ||
| 63 | {"cmd+alt+up", "set-window-height -10%"}, | 63 | {"cmd+alt+up", "set-window-height -10%"}, | ||
| 64 | {"cmd+alt+down", "set-window-height +10%"}, | 64 | {"cmd+alt+down", "set-window-height +10%"}, | ||
| 65 | - | {"cmd+ctrl+shift+up", "move-workspace-up"}, | 65 | + | {"cmd+ctrl+shift+up", "move-workspace-prev"}, |
| 66 | - | {"cmd+ctrl+shift+down", "move-workspace-down"}, | 66 | + | {"cmd+ctrl+shift+down", "move-workspace-next"}, |
| 67 | {"cmd+shift+space", "toggle-floating"}, | 67 | {"cmd+shift+space", "toggle-floating"}, | ||
| 68 | } | 68 | } | ||
| 69 | var actions = map[string]bool{ | 69 | var actions = map[string]bool{ | ||
| @@ -77,12 +77,12 @@ var actions = map[string]bool{ | |||||
| 77 | "move-workspace-to-monitor-down": true, | 77 | "move-workspace-to-monitor-down": true, | ||
| 78 | "scale-up": true, | 78 | "scale-up": true, | ||
| 79 | "scale-down": true, | 79 | "scale-down": true, | ||
| 80 | - | "focus-workspace-up": true, | 80 | + | "focus-workspace-prev": true, |
| 81 | - | "focus-workspace-down": true, | 81 | + | "focus-workspace-next": true, |
| 82 | - | "move-column-to-workspace-up": true, | 82 | + | "move-column-to-workspace-prev": true, |
| 83 | - | "move-column-to-workspace-down": true, | 83 | + | "move-column-to-workspace-next": true, |
| 84 | - | "move-window-to-workspace-up": true, | 84 | + | "move-window-to-workspace-prev": true, |
| 85 | - | "move-window-to-workspace-down": true, | 85 | + | "move-window-to-workspace-next": true, |
| 86 | "none": true, | 86 | "none": true, | ||
| 87 | "consume-or-expel-window-left": true, | 87 | "consume-or-expel-window-left": true, | ||
| 88 | "consume-or-expel-window-right": true, | 88 | "consume-or-expel-window-right": true, | ||
| @@ -103,8 +103,8 @@ var actions = map[string]bool{ | |||||
| 103 | "quit": true, | 103 | "quit": true, | ||
| 104 | "move-window-up": true, | 104 | "move-window-up": true, | ||
| 105 | "move-window-down": true, | 105 | "move-window-down": true, | ||
| 106 | - | "move-workspace-up": true, | 106 | + | "move-workspace-prev": true, |
| 107 | - | "move-workspace-down": true, | 107 | + | "move-workspace-next": true, |
| 108 | "toggle-floating": true, | 108 | "toggle-floating": true, | ||
| 109 | } | 109 | } | ||
| 110 | var components = map[string]bool{"core": true, "wayland": true, "input": true, "drm": true, "seat": true, "render": true, "sync": true, "config": true, "app": true} | 110 | var components = map[string]bool{"core": true, "wayland": true, "input": true, "drm": true, "seat": true, "render": true, "sync": true, "config": true, "app": true} | ||
M internal/adapters/config/config_test.go +11 -1
| @@ -31,7 +31,7 @@ func TestDefaultsAndLoad(t *testing.T) { | |||
| 31 | 31 | if d.Binds["Cmd+s"] != "toggle-stash-visible" || d.Binds["Cmd+Shift+s"] != "toggle-window-stash" || d.Binds["Cmd+o"] != "toggle-overview" || d.Binds["Cmd+f"] != "maximize-column" || d.Binds["Cmd+Shift+f"] != "toggle-fullscreen" || d.Binds["Cmd+Shift+h"] != "move-column-left" || d.Binds["Cmd+j"] != "focus-window-down" || d.Binds["Cmd+Shift+code:2"] != "move-column-to-workspace 1" || d.Focus.FollowMove { | |
| 32 | 32 | t.Fatal(d.Binds) | |
| 33 | 33 | } | |
| 34 | - | if d.Binds["Cmd+Shift+Up"] != "move-window-up" || d.Binds["Cmd+Shift+j"] != "move-window-down" || d.Binds["Alt+Cmd+Left"] != "set-column-width -10%" || d.Binds["Alt+Cmd+l"] != "set-column-width +10%" || d.Binds["Alt+Cmd+k"] != "set-window-height -10%" || d.Binds["Cmd+Ctrl+Shift+Down"] != "move-workspace-down" || d.Binds["Cmd+Ctrl+Shift+k"] != "move-workspace-up" || d.Binds["Cmd+Shift+space"] != "toggle-floating" { | |
| 34 | + | if d.Binds["Cmd+Shift+Up"] != "move-window-up" || d.Binds["Cmd+Shift+j"] != "move-window-down" || d.Binds["Alt+Cmd+Left"] != "set-column-width -10%" || d.Binds["Alt+Cmd+l"] != "set-column-width +10%" || d.Binds["Alt+Cmd+k"] != "set-window-height -10%" || d.Binds["Cmd+Ctrl+Shift+Down"] != "move-workspace-next" || d.Binds["Cmd+Ctrl+Shift+k"] != "move-workspace-prev" || d.Binds["Cmd+Shift+space"] != "toggle-floating" { | |
| 35 | 35 | t.Fatal(d.Binds) | |
| 36 | 36 | } | |
| 37 | 37 | if d.Binds["Cmd+Ctrl+space"] != "spawn fuzzel" || d.Binds["Alt+Ctrl+BackSpace"] != "quit" { | |
| @@ -283,6 +283,9 @@ func TestWarningsKeepDefaults(t *testing.T) { | |||
| 283 | 283 | {"bind.cmd+ = quit", "missing key"}, | |
| 284 | 284 | {"bind.hyper+x = quit", "unknown modifier"}, | |
| 285 | 285 | {"bind.cmd+x = bogus", "unknown action"}, | |
| 286 | + | {"bind.cmd+x = focus-workspace-up", "unknown action"}, | |
| 287 | + | {"bind.cmd+x = move-workspace-down", "unknown action"}, | |
| 288 | + | {"bind.cmd+x = move-column-to-workspace-up", "unknown action"}, | |
| 286 | 289 | {"bind.cmd+x = set-column-width 10%", "set-column-width needs"}, | |
| 287 | 290 | {"bind.cmd+x = set-column-width +0%", "set-column-width needs"}, | |
| 288 | 291 | {"bind.cmd+x = set-window-height -101%", "set-window-height needs"}, | |
| @@ -304,6 +307,13 @@ func TestWarningsKeepDefaults(t *testing.T) { | |||
| 304 | 307 | } | |
| 305 | 308 | } | |
| 306 | 309 | ||
| 310 | + | func TestWorkspacePrevNextAction(t *testing.T) { | |
| 311 | + | c, w := parseString(t, "bind.cmd+x = focus-workspace-next") | |
| 312 | + | if len(w) != 0 || c.Binds["Cmd+x"] != "focus-workspace-next" { | |
| 313 | + | t.Fatal(c.Binds["Cmd+x"], w) | |
| 314 | + | } | |
| 315 | + | } | |
| 316 | + | ||
| 307 | 317 | func TestXwayland(t *testing.T) { | |
| 308 | 318 | if Defaults().Xwayland != "xwayland-satellite" { | |
| 309 | 319 | t.Fatal(Defaults().Xwayland) | |
| @@ -31,7 +31,7 @@ func TestDefaultsAndLoad(t *testing.T) { | |||||
| 31 | if d.Binds["Cmd+s"] != "toggle-stash-visible" || d.Binds["Cmd+Shift+s"] != "toggle-window-stash" || d.Binds["Cmd+o"] != "toggle-overview" || d.Binds["Cmd+f"] != "maximize-column" || d.Binds["Cmd+Shift+f"] != "toggle-fullscreen" || d.Binds["Cmd+Shift+h"] != "move-column-left" || d.Binds["Cmd+j"] != "focus-window-down" || d.Binds["Cmd+Shift+code:2"] != "move-column-to-workspace 1" || d.Focus.FollowMove { | 31 | if d.Binds["Cmd+s"] != "toggle-stash-visible" || d.Binds["Cmd+Shift+s"] != "toggle-window-stash" || d.Binds["Cmd+o"] != "toggle-overview" || d.Binds["Cmd+f"] != "maximize-column" || d.Binds["Cmd+Shift+f"] != "toggle-fullscreen" || d.Binds["Cmd+Shift+h"] != "move-column-left" || d.Binds["Cmd+j"] != "focus-window-down" || d.Binds["Cmd+Shift+code:2"] != "move-column-to-workspace 1" || d.Focus.FollowMove { | ||
| 32 | t.Fatal(d.Binds) | 32 | t.Fatal(d.Binds) | ||
| 33 | } | 33 | } | ||
| 34 | - | if d.Binds["Cmd+Shift+Up"] != "move-window-up" || d.Binds["Cmd+Shift+j"] != "move-window-down" || d.Binds["Alt+Cmd+Left"] != "set-column-width -10%" || d.Binds["Alt+Cmd+l"] != "set-column-width +10%" || d.Binds["Alt+Cmd+k"] != "set-window-height -10%" || d.Binds["Cmd+Ctrl+Shift+Down"] != "move-workspace-down" || d.Binds["Cmd+Ctrl+Shift+k"] != "move-workspace-up" || d.Binds["Cmd+Shift+space"] != "toggle-floating" { | 34 | + | if d.Binds["Cmd+Shift+Up"] != "move-window-up" || d.Binds["Cmd+Shift+j"] != "move-window-down" || d.Binds["Alt+Cmd+Left"] != "set-column-width -10%" || d.Binds["Alt+Cmd+l"] != "set-column-width +10%" || d.Binds["Alt+Cmd+k"] != "set-window-height -10%" || d.Binds["Cmd+Ctrl+Shift+Down"] != "move-workspace-next" || d.Binds["Cmd+Ctrl+Shift+k"] != "move-workspace-prev" || d.Binds["Cmd+Shift+space"] != "toggle-floating" { |
| 35 | t.Fatal(d.Binds) | 35 | t.Fatal(d.Binds) | ||
| 36 | } | 36 | } | ||
| 37 | if d.Binds["Cmd+Ctrl+space"] != "spawn fuzzel" || d.Binds["Alt+Ctrl+BackSpace"] != "quit" { | 37 | if d.Binds["Cmd+Ctrl+space"] != "spawn fuzzel" || d.Binds["Alt+Ctrl+BackSpace"] != "quit" { | ||
| @@ -283,6 +283,9 @@ func TestWarningsKeepDefaults(t *testing.T) { | |||||
| 283 | {"bind.cmd+ = quit", "missing key"}, | 283 | {"bind.cmd+ = quit", "missing key"}, | ||
| 284 | {"bind.hyper+x = quit", "unknown modifier"}, | 284 | {"bind.hyper+x = quit", "unknown modifier"}, | ||
| 285 | {"bind.cmd+x = bogus", "unknown action"}, | 285 | {"bind.cmd+x = bogus", "unknown action"}, | ||
| 286 | + | {"bind.cmd+x = focus-workspace-up", "unknown action"}, | |||
| 287 | + | {"bind.cmd+x = move-workspace-down", "unknown action"}, | |||
| 288 | + | {"bind.cmd+x = move-column-to-workspace-up", "unknown action"}, | |||
| 286 | {"bind.cmd+x = set-column-width 10%", "set-column-width needs"}, | 289 | {"bind.cmd+x = set-column-width 10%", "set-column-width needs"}, | ||
| 287 | {"bind.cmd+x = set-column-width +0%", "set-column-width needs"}, | 290 | {"bind.cmd+x = set-column-width +0%", "set-column-width needs"}, | ||
| 288 | {"bind.cmd+x = set-window-height -101%", "set-window-height needs"}, | 291 | {"bind.cmd+x = set-window-height -101%", "set-window-height needs"}, | ||
| @@ -304,6 +307,13 @@ func TestWarningsKeepDefaults(t *testing.T) { | |||||
| 304 | } | 307 | } | ||
| 305 | } | 308 | } | ||
| 306 | 309 | ||||
| 310 | + | func TestWorkspacePrevNextAction(t *testing.T) { | |||
| 311 | + | c, w := parseString(t, "bind.cmd+x = focus-workspace-next") | |||
| 312 | + | if len(w) != 0 || c.Binds["Cmd+x"] != "focus-workspace-next" { | |||
| 313 | + | t.Fatal(c.Binds["Cmd+x"], w) | |||
| 314 | + | } | |||
| 315 | + | } | |||
| 316 | + | ||||
| 307 | func TestXwayland(t *testing.T) { | 317 | func TestXwayland(t *testing.T) { | ||
| 308 | if Defaults().Xwayland != "xwayland-satellite" { | 318 | if Defaults().Xwayland != "xwayland-satellite" { | ||
| 309 | t.Fatal(Defaults().Xwayland) | 319 | t.Fatal(Defaults().Xwayland) | ||
M internal/core/action.go +21 -21
| @@ -25,15 +25,15 @@ const ( | |||
| 25 | 25 | ActionToggleOverview Action = "toggle-overview" | |
| 26 | 26 | ActionCloseWindow Action = "close-window" | |
| 27 | 27 | ActionQuit Action = "quit" | |
| 28 | - | // Workspaces stack vertically; up/down stop at the ends. | |
| 29 | - | ActionFocusWorkspaceUp Action = "focus-workspace-up" | |
| 30 | - | ActionFocusWorkspaceDown Action = "focus-workspace-down" | |
| 31 | - | // Move the focused column, or only the focused window, one workspace | |
| 32 | - | // up or down. | |
| 33 | - | ActionMoveColumnToWorkspaceUp Action = "move-column-to-workspace-up" | |
| 34 | - | ActionMoveColumnToWorkspaceDown Action = "move-column-to-workspace-down" | |
| 35 | - | ActionMoveWindowToWorkspaceUp Action = "move-window-to-workspace-up" | |
| 36 | - | ActionMoveWindowToWorkspaceDown Action = "move-window-to-workspace-down" | |
| 28 | + | // Workspaces stack vertically; prev/next stop at the ends. | |
| 29 | + | ActionFocusWorkspacePrev Action = "focus-workspace-prev" | |
| 30 | + | ActionFocusWorkspaceNext Action = "focus-workspace-next" | |
| 31 | + | // Move the focused column, or only the focused window, to the previous | |
| 32 | + | // or next workspace. | |
| 33 | + | ActionMoveColumnToWorkspacePrev Action = "move-column-to-workspace-prev" | |
| 34 | + | ActionMoveColumnToWorkspaceNext Action = "move-column-to-workspace-next" | |
| 35 | + | ActionMoveWindowToWorkspacePrev Action = "move-window-to-workspace-prev" | |
| 36 | + | ActionMoveWindowToWorkspaceNext Action = "move-window-to-workspace-next" | |
| 37 | 37 | // Monitors act on the neighbor in that direction of the global layout | |
| 38 | 38 | // (ADR 011). | |
| 39 | 39 | ActionFocusMonitorLeft Action = "focus-monitor-left" | |
| @@ -54,8 +54,8 @@ const ( | |||
| 54 | 54 | ActionMoveWindowUp Action = "move-window-up" | |
| 55 | 55 | ActionMoveWindowDown Action = "move-window-down" | |
| 56 | 56 | // Swap the active numbered workspace with its neighbor. | |
| 57 | - | ActionMoveWorkspaceUp Action = "move-workspace-up" | |
| 58 | - | ActionMoveWorkspaceDown Action = "move-workspace-down" | |
| 57 | + | ActionMoveWorkspacePrev Action = "move-workspace-prev" | |
| 58 | + | ActionMoveWorkspaceNext Action = "move-workspace-next" | |
| 59 | 59 | // Turn the focused tile into a free floating window, or back. | |
| 60 | 60 | ActionToggleFloating Action = "toggle-floating" | |
| 61 | 61 | ) | |
| @@ -349,17 +349,17 @@ func (m *Monitor) Apply(a Action) Effect { | |||
| 349 | 349 | return Effect{} | |
| 350 | 350 | } | |
| 351 | 351 | } | |
| 352 | - | case ActionFocusWorkspaceUp, ActionFocusWorkspaceDown: | |
| 353 | - | if m.shown == nil && a == ActionFocusWorkspaceUp { | |
| 352 | + | case ActionFocusWorkspacePrev, ActionFocusWorkspaceNext: | |
| 353 | + | if m.shown == nil && a == ActionFocusWorkspacePrev { | |
| 354 | 354 | m.Focus(m.Active - 1) | |
| 355 | 355 | } else if m.shown == nil { | |
| 356 | 356 | m.Focus(m.Active + 1) | |
| 357 | 357 | } | |
| 358 | 358 | return Effect{} | |
| 359 | - | case ActionMoveWorkspaceUp: | |
| 359 | + | case ActionMoveWorkspacePrev: | |
| 360 | 360 | m.MoveWorkspace(-1) | |
| 361 | 361 | return Effect{} | |
| 362 | - | case ActionMoveWorkspaceDown: | |
| 362 | + | case ActionMoveWorkspaceNext: | |
| 363 | 363 | m.MoveWorkspace(1) | |
| 364 | 364 | return Effect{} | |
| 365 | 365 | } | |
| @@ -372,8 +372,8 @@ func movesToWorkspace(a Action) bool { | |||
| 372 | 372 | return op != FocusWorkspace | |
| 373 | 373 | } | |
| 374 | 374 | switch a { | |
| 375 | - | case ActionMoveColumnToWorkspaceUp, ActionMoveColumnToWorkspaceDown, | |
| 376 | - | ActionMoveWindowToWorkspaceUp, ActionMoveWindowToWorkspaceDown: | |
| 375 | + | case ActionMoveColumnToWorkspacePrev, ActionMoveColumnToWorkspaceNext, | |
| 376 | + | ActionMoveWindowToWorkspacePrev, ActionMoveWindowToWorkspaceNext: | |
| 377 | 377 | return true | |
| 378 | 378 | } | |
| 379 | 379 | return false | |
| @@ -390,10 +390,10 @@ func (m *Monitor) moveDest(a Action) (i int, column, ok bool) { | |||
| 390 | 390 | return 0, false, false | |
| 391 | 391 | } | |
| 392 | 392 | switch a { | |
| 393 | - | case ActionMoveColumnToWorkspaceUp, ActionMoveWindowToWorkspaceUp: | |
| 394 | - | return m.Active - 1, a == ActionMoveColumnToWorkspaceUp, m.Active > 0 | |
| 395 | - | case ActionMoveColumnToWorkspaceDown, ActionMoveWindowToWorkspaceDown: | |
| 396 | - | return min(m.Active+1, len(m.Workspaces)-1), a == ActionMoveColumnToWorkspaceDown, true | |
| 393 | + | case ActionMoveColumnToWorkspacePrev, ActionMoveWindowToWorkspacePrev: | |
| 394 | + | return m.Active - 1, a == ActionMoveColumnToWorkspacePrev, m.Active > 0 | |
| 395 | + | case ActionMoveColumnToWorkspaceNext, ActionMoveWindowToWorkspaceNext: | |
| 396 | + | return min(m.Active+1, len(m.Workspaces)-1), a == ActionMoveColumnToWorkspaceNext, true | |
| 397 | 397 | } | |
| 398 | 398 | return 0, false, false | |
| 399 | 399 | } | |
| @@ -25,15 +25,15 @@ const ( | |||||
| 25 | ActionToggleOverview Action = "toggle-overview" | 25 | ActionToggleOverview Action = "toggle-overview" | ||
| 26 | ActionCloseWindow Action = "close-window" | 26 | ActionCloseWindow Action = "close-window" | ||
| 27 | ActionQuit Action = "quit" | 27 | ActionQuit Action = "quit" | ||
| 28 | - | // Workspaces stack vertically; up/down stop at the ends. | 28 | + | // Workspaces stack vertically; prev/next stop at the ends. |
| 29 | - | ActionFocusWorkspaceUp Action = "focus-workspace-up" | 29 | + | ActionFocusWorkspacePrev Action = "focus-workspace-prev" |
| 30 | - | ActionFocusWorkspaceDown Action = "focus-workspace-down" | 30 | + | ActionFocusWorkspaceNext Action = "focus-workspace-next" |
| 31 | - | // Move the focused column, or only the focused window, one workspace | 31 | + | // Move the focused column, or only the focused window, to the previous |
| 32 | - | // up or down. | 32 | + | // or next workspace. |
| 33 | - | ActionMoveColumnToWorkspaceUp Action = "move-column-to-workspace-up" | 33 | + | ActionMoveColumnToWorkspacePrev Action = "move-column-to-workspace-prev" |
| 34 | - | ActionMoveColumnToWorkspaceDown Action = "move-column-to-workspace-down" | 34 | + | ActionMoveColumnToWorkspaceNext Action = "move-column-to-workspace-next" |
| 35 | - | ActionMoveWindowToWorkspaceUp Action = "move-window-to-workspace-up" | 35 | + | ActionMoveWindowToWorkspacePrev Action = "move-window-to-workspace-prev" |
| 36 | - | ActionMoveWindowToWorkspaceDown Action = "move-window-to-workspace-down" | 36 | + | ActionMoveWindowToWorkspaceNext Action = "move-window-to-workspace-next" |
| 37 | // Monitors act on the neighbor in that direction of the global layout | 37 | // Monitors act on the neighbor in that direction of the global layout | ||
| 38 | // (ADR 011). | 38 | // (ADR 011). | ||
| 39 | ActionFocusMonitorLeft Action = "focus-monitor-left" | 39 | ActionFocusMonitorLeft Action = "focus-monitor-left" | ||
| @@ -54,8 +54,8 @@ const ( | |||||
| 54 | ActionMoveWindowUp Action = "move-window-up" | 54 | ActionMoveWindowUp Action = "move-window-up" | ||
| 55 | ActionMoveWindowDown Action = "move-window-down" | 55 | ActionMoveWindowDown Action = "move-window-down" | ||
| 56 | // Swap the active numbered workspace with its neighbor. | 56 | // Swap the active numbered workspace with its neighbor. | ||
| 57 | - | ActionMoveWorkspaceUp Action = "move-workspace-up" | 57 | + | ActionMoveWorkspacePrev Action = "move-workspace-prev" |
| 58 | - | ActionMoveWorkspaceDown Action = "move-workspace-down" | 58 | + | ActionMoveWorkspaceNext Action = "move-workspace-next" |
| 59 | // Turn the focused tile into a free floating window, or back. | 59 | // Turn the focused tile into a free floating window, or back. | ||
| 60 | ActionToggleFloating Action = "toggle-floating" | 60 | ActionToggleFloating Action = "toggle-floating" | ||
| 61 | ) | 61 | ) | ||
| @@ -349,17 +349,17 @@ func (m *Monitor) Apply(a Action) Effect { | |||||
| 349 | return Effect{} | 349 | return Effect{} | ||
| 350 | } | 350 | } | ||
| 351 | } | 351 | } | ||
| 352 | - | case ActionFocusWorkspaceUp, ActionFocusWorkspaceDown: | 352 | + | case ActionFocusWorkspacePrev, ActionFocusWorkspaceNext: |
| 353 | - | if m.shown == nil && a == ActionFocusWorkspaceUp { | 353 | + | if m.shown == nil && a == ActionFocusWorkspacePrev { |
| 354 | m.Focus(m.Active - 1) | 354 | m.Focus(m.Active - 1) | ||
| 355 | } else if m.shown == nil { | 355 | } else if m.shown == nil { | ||
| 356 | m.Focus(m.Active + 1) | 356 | m.Focus(m.Active + 1) | ||
| 357 | } | 357 | } | ||
| 358 | return Effect{} | 358 | return Effect{} | ||
| 359 | - | case ActionMoveWorkspaceUp: | 359 | + | case ActionMoveWorkspacePrev: |
| 360 | m.MoveWorkspace(-1) | 360 | m.MoveWorkspace(-1) | ||
| 361 | return Effect{} | 361 | return Effect{} | ||
| 362 | - | case ActionMoveWorkspaceDown: | 362 | + | case ActionMoveWorkspaceNext: |
| 363 | m.MoveWorkspace(1) | 363 | m.MoveWorkspace(1) | ||
| 364 | return Effect{} | 364 | return Effect{} | ||
| 365 | } | 365 | } | ||
| @@ -372,8 +372,8 @@ func movesToWorkspace(a Action) bool { | |||||
| 372 | return op != FocusWorkspace | 372 | return op != FocusWorkspace | ||
| 373 | } | 373 | } | ||
| 374 | switch a { | 374 | switch a { | ||
| 375 | - | case ActionMoveColumnToWorkspaceUp, ActionMoveColumnToWorkspaceDown, | 375 | + | case ActionMoveColumnToWorkspacePrev, ActionMoveColumnToWorkspaceNext, |
| 376 | - | ActionMoveWindowToWorkspaceUp, ActionMoveWindowToWorkspaceDown: | 376 | + | ActionMoveWindowToWorkspacePrev, ActionMoveWindowToWorkspaceNext: |
| 377 | return true | 377 | return true | ||
| 378 | } | 378 | } | ||
| 379 | return false | 379 | return false | ||
| @@ -390,10 +390,10 @@ func (m *Monitor) moveDest(a Action) (i int, column, ok bool) { | |||||
| 390 | return 0, false, false | 390 | return 0, false, false | ||
| 391 | } | 391 | } | ||
| 392 | switch a { | 392 | switch a { | ||
| 393 | - | case ActionMoveColumnToWorkspaceUp, ActionMoveWindowToWorkspaceUp: | 393 | + | case ActionMoveColumnToWorkspacePrev, ActionMoveWindowToWorkspacePrev: |
| 394 | - | return m.Active - 1, a == ActionMoveColumnToWorkspaceUp, m.Active > 0 | 394 | + | return m.Active - 1, a == ActionMoveColumnToWorkspacePrev, m.Active > 0 |
| 395 | - | case ActionMoveColumnToWorkspaceDown, ActionMoveWindowToWorkspaceDown: | 395 | + | case ActionMoveColumnToWorkspaceNext, ActionMoveWindowToWorkspaceNext: |
| 396 | - | return min(m.Active+1, len(m.Workspaces)-1), a == ActionMoveColumnToWorkspaceDown, true | 396 | + | return min(m.Active+1, len(m.Workspaces)-1), a == ActionMoveColumnToWorkspaceNext, true |
| 397 | } | 397 | } | ||
| 398 | return 0, false, false | 398 | return 0, false, false | ||
| 399 | } | 399 | } | ||
M internal/core/core.go +2 -2
| @@ -242,8 +242,8 @@ func (c *Core) apply(cfg ports.Config) error { | |||
| 242 | 242 | continue | |
| 243 | 243 | } | |
| 244 | 244 | switch Action(a) { | |
| 245 | - | case "none", ActionSpawnTerminal, ActionFocusColumnLeft, ActionFocusColumnRight, ActionFocusWindowUp, ActionFocusWindowDown, ActionMoveColumnLeft, ActionMoveColumnRight, ActionCycleColumnWidth, ActionMaximizeColumn, ActionToggleFullscreen, ActionToggleWindowStash, ActionToggleStashVisible, ActionToggleOverview, ActionCloseWindow, ActionQuit, ActionFocusWorkspaceUp, ActionFocusWorkspaceDown, ActionMoveColumnToWorkspaceUp, ActionMoveColumnToWorkspaceDown, ActionMoveWindowToWorkspaceUp, ActionMoveWindowToWorkspaceDown, ActionFocusMonitorLeft, ActionFocusMonitorRight, ActionFocusMonitorUp, ActionFocusMonitorDown, ActionMoveWorkspaceLeft, ActionMoveWorkspaceRight, ActionMoveWorkspaceToMonitorUp, ActionMoveWorkspaceToMonitorDown, ActionConsumeOrExpelLeft, ActionConsumeOrExpelRight, | |
| 246 | - | ActionMoveWindowUp, ActionMoveWindowDown, ActionMoveWorkspaceUp, ActionMoveWorkspaceDown, ActionToggleFloating: | |
| 245 | + | case "none", ActionSpawnTerminal, ActionFocusColumnLeft, ActionFocusColumnRight, ActionFocusWindowUp, ActionFocusWindowDown, ActionMoveColumnLeft, ActionMoveColumnRight, ActionCycleColumnWidth, ActionMaximizeColumn, ActionToggleFullscreen, ActionToggleWindowStash, ActionToggleStashVisible, ActionToggleOverview, ActionCloseWindow, ActionQuit, ActionFocusWorkspacePrev, ActionFocusWorkspaceNext, ActionMoveColumnToWorkspacePrev, ActionMoveColumnToWorkspaceNext, ActionMoveWindowToWorkspacePrev, ActionMoveWindowToWorkspaceNext, ActionFocusMonitorLeft, ActionFocusMonitorRight, ActionFocusMonitorUp, ActionFocusMonitorDown, ActionMoveWorkspaceLeft, ActionMoveWorkspaceRight, ActionMoveWorkspaceToMonitorUp, ActionMoveWorkspaceToMonitorDown, ActionConsumeOrExpelLeft, ActionConsumeOrExpelRight, | |
| 246 | + | ActionMoveWindowUp, ActionMoveWindowDown, ActionMoveWorkspacePrev, ActionMoveWorkspaceNext, ActionToggleFloating: | |
| 247 | 247 | default: | |
| 248 | 248 | return fmt.Errorf("invalid action %q", a) | |
| 249 | 249 | } | |
| @@ -242,8 +242,8 @@ func (c *Core) apply(cfg ports.Config) error { | |||||
| 242 | continue | 242 | continue | ||
| 243 | } | 243 | } | ||
| 244 | switch Action(a) { | 244 | switch Action(a) { | ||
| 245 | - | case "none", ActionSpawnTerminal, ActionFocusColumnLeft, ActionFocusColumnRight, ActionFocusWindowUp, ActionFocusWindowDown, ActionMoveColumnLeft, ActionMoveColumnRight, ActionCycleColumnWidth, ActionMaximizeColumn, ActionToggleFullscreen, ActionToggleWindowStash, ActionToggleStashVisible, ActionToggleOverview, ActionCloseWindow, ActionQuit, ActionFocusWorkspaceUp, ActionFocusWorkspaceDown, ActionMoveColumnToWorkspaceUp, ActionMoveColumnToWorkspaceDown, ActionMoveWindowToWorkspaceUp, ActionMoveWindowToWorkspaceDown, ActionFocusMonitorLeft, ActionFocusMonitorRight, ActionFocusMonitorUp, ActionFocusMonitorDown, ActionMoveWorkspaceLeft, ActionMoveWorkspaceRight, ActionMoveWorkspaceToMonitorUp, ActionMoveWorkspaceToMonitorDown, ActionConsumeOrExpelLeft, ActionConsumeOrExpelRight, | 245 | + | case "none", ActionSpawnTerminal, ActionFocusColumnLeft, ActionFocusColumnRight, ActionFocusWindowUp, ActionFocusWindowDown, ActionMoveColumnLeft, ActionMoveColumnRight, ActionCycleColumnWidth, ActionMaximizeColumn, ActionToggleFullscreen, ActionToggleWindowStash, ActionToggleStashVisible, ActionToggleOverview, ActionCloseWindow, ActionQuit, ActionFocusWorkspacePrev, ActionFocusWorkspaceNext, ActionMoveColumnToWorkspacePrev, ActionMoveColumnToWorkspaceNext, ActionMoveWindowToWorkspacePrev, ActionMoveWindowToWorkspaceNext, ActionFocusMonitorLeft, ActionFocusMonitorRight, ActionFocusMonitorUp, ActionFocusMonitorDown, ActionMoveWorkspaceLeft, ActionMoveWorkspaceRight, ActionMoveWorkspaceToMonitorUp, ActionMoveWorkspaceToMonitorDown, ActionConsumeOrExpelLeft, ActionConsumeOrExpelRight, |
| 246 | - | ActionMoveWindowUp, ActionMoveWindowDown, ActionMoveWorkspaceUp, ActionMoveWorkspaceDown, ActionToggleFloating: | 246 | + | ActionMoveWindowUp, ActionMoveWindowDown, ActionMoveWorkspacePrev, ActionMoveWorkspaceNext, ActionToggleFloating: |
| 247 | default: | 247 | default: | ||
| 248 | return fmt.Errorf("invalid action %q", a) | 248 | return fmt.Errorf("invalid action %q", a) | ||
| 249 | } | 249 | } | ||
M internal/core/gesture.go +2 -2
| @@ -412,9 +412,9 @@ func (c *Core) swipeEnd(e ports.SwipeEnd) (shown bool) { | |||
| 412 | 412 | a = ActionFocusColumnLeft | |
| 413 | 413 | } | |
| 414 | 414 | if workspace { | |
| 415 | - | a = ActionFocusWorkspaceDown | |
| 415 | + | a = ActionFocusWorkspaceNext | |
| 416 | 416 | if step < 0 { | |
| 417 | - | a = ActionFocusWorkspaceUp | |
| 417 | + | a = ActionFocusWorkspacePrev | |
| 418 | 418 | } | |
| 419 | 419 | } else if p.wraps { | |
| 420 | 420 | // A content swipe cannot escape the last band to another workspace. | |
| @@ -412,9 +412,9 @@ func (c *Core) swipeEnd(e ports.SwipeEnd) (shown bool) { | |||||
| 412 | a = ActionFocusColumnLeft | 412 | a = ActionFocusColumnLeft | ||
| 413 | } | 413 | } | ||
| 414 | if workspace { | 414 | if workspace { | ||
| 415 | - | a = ActionFocusWorkspaceDown | 415 | + | a = ActionFocusWorkspaceNext |
| 416 | if step < 0 { | 416 | if step < 0 { | ||
| 417 | - | a = ActionFocusWorkspaceUp | 417 | + | a = ActionFocusWorkspacePrev |
| 418 | } | 418 | } | ||
| 419 | } else if p.wraps { | 419 | } else if p.wraps { | ||
| 420 | // A content swipe cannot escape the last band to another workspace. | 420 | // A content swipe cannot escape the last band to another workspace. | ||
M internal/core/layout_buffers_test.go +4 -4
| @@ -57,10 +57,10 @@ func layoutVariants(t *testing.T) map[string]*Monitor { | |||
| 57 | 57 | v["fullscreen"] = m | |
| 58 | 58 | ||
| 59 | 59 | m = base(OverflowScroll, 3) | |
| 60 | - | m.Apply(ActionFocusWorkspaceDown) | |
| 60 | + | m.Apply(ActionFocusWorkspaceNext) | |
| 61 | 61 | m.AddWindow(20) | |
| 62 | 62 | m.AddWindow(21) | |
| 63 | - | m.Apply(ActionFocusWorkspaceUp) | |
| 63 | + | m.Apply(ActionFocusWorkspacePrev) | |
| 64 | 64 | v["two-workspaces"] = m | |
| 65 | 65 | ||
| 66 | 66 | m = base(OverflowScroll, 3) | |
| @@ -69,9 +69,9 @@ func layoutVariants(t *testing.T) map[string]*Monitor { | |||
| 69 | 69 | v["overview"] = m | |
| 70 | 70 | ||
| 71 | 71 | m = base(OverflowScroll, 3) | |
| 72 | - | m.Apply(ActionFocusWorkspaceDown) | |
| 72 | + | m.Apply(ActionFocusWorkspaceNext) | |
| 73 | 73 | m.AddWindow(20) | |
| 74 | - | m.Apply(ActionFocusWorkspaceUp) | |
| 74 | + | m.Apply(ActionFocusWorkspacePrev) | |
| 75 | 75 | m.switchView.off = 0.4 | |
| 76 | 76 | v["slide"] = m | |
| 77 | 77 | ||
| @@ -57,10 +57,10 @@ func layoutVariants(t *testing.T) map[string]*Monitor { | |||||
| 57 | v["fullscreen"] = m | 57 | v["fullscreen"] = m | ||
| 58 | 58 | ||||
| 59 | m = base(OverflowScroll, 3) | 59 | m = base(OverflowScroll, 3) | ||
| 60 | - | m.Apply(ActionFocusWorkspaceDown) | 60 | + | m.Apply(ActionFocusWorkspaceNext) |
| 61 | m.AddWindow(20) | 61 | m.AddWindow(20) | ||
| 62 | m.AddWindow(21) | 62 | m.AddWindow(21) | ||
| 63 | - | m.Apply(ActionFocusWorkspaceUp) | 63 | + | m.Apply(ActionFocusWorkspacePrev) |
| 64 | v["two-workspaces"] = m | 64 | v["two-workspaces"] = m | ||
| 65 | 65 | ||||
| 66 | m = base(OverflowScroll, 3) | 66 | m = base(OverflowScroll, 3) | ||
| @@ -69,9 +69,9 @@ func layoutVariants(t *testing.T) map[string]*Monitor { | |||||
| 69 | v["overview"] = m | 69 | v["overview"] = m | ||
| 70 | 70 | ||||
| 71 | m = base(OverflowScroll, 3) | 71 | m = base(OverflowScroll, 3) | ||
| 72 | - | m.Apply(ActionFocusWorkspaceDown) | 72 | + | m.Apply(ActionFocusWorkspaceNext) |
| 73 | m.AddWindow(20) | 73 | m.AddWindow(20) | ||
| 74 | - | m.Apply(ActionFocusWorkspaceUp) | 74 | + | m.Apply(ActionFocusWorkspacePrev) |
| 75 | m.switchView.off = 0.4 | 75 | m.switchView.off = 0.4 | ||
| 76 | v["slide"] = m | 76 | v["slide"] = m | ||
| 77 | 77 | ||||
M internal/core/monitor_test.go +10 -10
| @@ -154,12 +154,12 @@ func TestMonitorActions(t *testing.T) { | |||
| 154 | 154 | t.Fatal(m.Active) | |
| 155 | 155 | } | |
| 156 | 156 | // Up at the top workspace stays. | |
| 157 | - | m.Apply(ActionFocusWorkspaceUp) | |
| 157 | + | m.Apply(ActionFocusWorkspacePrev) | |
| 158 | 158 | if m.Active != 0 { | |
| 159 | 159 | t.Fatal(m.Active) | |
| 160 | 160 | } | |
| 161 | 161 | // Move the focused window (2) down: focus stays on workspace 1. | |
| 162 | - | m.Apply(ActionMoveWindowToWorkspaceDown) | |
| 162 | + | m.Apply(ActionMoveWindowToWorkspaceNext) | |
| 163 | 163 | if !reflect.DeepEqual(windows(m), [][]WindowID{{1}, {2}, {}}) || m.Active != 0 { | |
| 164 | 164 | t.Fatal(windows(m), m.Active) | |
| 165 | 165 | } | |
| @@ -235,7 +235,7 @@ func TestMoveColumnToWorkspace(t *testing.T) { | |||
| 235 | 235 | }) | |
| 236 | 236 | t.Run("window only", func(t *testing.T) { | |
| 237 | 237 | m := stack() | |
| 238 | - | m.Apply(ActionMoveWindowToWorkspaceDown) | |
| 238 | + | m.Apply(ActionMoveWindowToWorkspaceNext) | |
| 239 | 239 | if got := windows(m); !reflect.DeepEqual(got, [][]WindowID{{1, 2}, {3}, {}}) { | |
| 240 | 240 | t.Fatal(got) | |
| 241 | 241 | } | |
| @@ -243,7 +243,7 @@ func TestMoveColumnToWorkspace(t *testing.T) { | |||
| 243 | 243 | t.Run("follow shows the target", func(t *testing.T) { | |
| 244 | 244 | m := stack() | |
| 245 | 245 | m.SetFollowMove(true) | |
| 246 | - | m.Apply(ActionMoveColumnToWorkspaceDown) | |
| 246 | + | m.Apply(ActionMoveColumnToWorkspaceNext) | |
| 247 | 247 | if id, _ := m.Focused(); m.Active != 1 || id != 3 { | |
| 248 | 248 | t.Fatal(m.Active, id) | |
| 249 | 249 | } | |
| @@ -255,7 +255,7 @@ func TestMoveColumnToWorkspace(t *testing.T) { | |||
| 255 | 255 | m := stack() | |
| 256 | 256 | c := &m.Current().Columns[1] | |
| 257 | 257 | c.Slot, c.Focus = 2, 0 | |
| 258 | - | m.Apply(ActionMoveWindowToWorkspaceDown) | |
| 258 | + | m.Apply(ActionMoveWindowToWorkspaceNext) | |
| 259 | 259 | if c := m.Current().Columns[1]; c.Slot != 0 || c.Windows[0] != 3 { | |
| 260 | 260 | t.Fatal(c) | |
| 261 | 261 | } | |
| @@ -265,7 +265,7 @@ func TestMoveColumnToWorkspace(t *testing.T) { | |||
| 265 | 265 | m.SetFollowMove(true) | |
| 266 | 266 | m.AddFloating(9, 10, 10) | |
| 267 | 267 | m.Current().FocusID(9) | |
| 268 | - | m.Apply(ActionMoveWindowToWorkspaceDown) | |
| 268 | + | m.Apply(ActionMoveWindowToWorkspaceNext) | |
| 269 | 269 | if id, _ := m.Focused(); m.Active != 1 || id != 9 { | |
| 270 | 270 | t.Fatal(m.Active, id) | |
| 271 | 271 | } | |
| @@ -273,7 +273,7 @@ func TestMoveColumnToWorkspace(t *testing.T) { | |||
| 273 | 273 | t.Run("slot column loses its slot", func(t *testing.T) { | |
| 274 | 274 | m := stack() | |
| 275 | 275 | m.Current().Columns[1].Slot = 2 | |
| 276 | - | m.Apply(ActionMoveColumnToWorkspaceDown) | |
| 276 | + | m.Apply(ActionMoveColumnToWorkspaceNext) | |
| 277 | 277 | if c := m.Workspaces[1].Columns[0]; c.Slot != 0 { | |
| 278 | 278 | t.Fatal(c) | |
| 279 | 279 | } | |
| @@ -344,7 +344,7 @@ func TestHiddenWorkspaceToggle(t *testing.T) { | |||
| 344 | 344 | } | |
| 345 | 345 | m.AddWindow(2) | |
| 346 | 346 | // Up/down do not leave a hidden workspace. | |
| 347 | - | m.Apply(ActionFocusWorkspaceDown) | |
| 347 | + | m.Apply(ActionFocusWorkspaceNext) | |
| 348 | 348 | m.Apply(ActionFocusWindowDown) | |
| 349 | 349 | if m.Current().Name != "dev" { | |
| 350 | 350 | t.Fatal("left the hidden workspace") | |
| @@ -367,8 +367,8 @@ func TestHiddenWorkspaceToggle(t *testing.T) { | |||
| 367 | 367 | } | |
| 368 | 368 | // Moving a window up/down from a hidden workspace does nothing. | |
| 369 | 369 | m.Apply("workspace dev") | |
| 370 | - | m.Apply(ActionMoveWindowToWorkspaceDown) | |
| 371 | - | m.Apply(ActionMoveWindowToWorkspaceUp) | |
| 370 | + | m.Apply(ActionMoveWindowToWorkspaceNext) | |
| 371 | + | m.Apply(ActionMoveWindowToWorkspacePrev) | |
| 372 | 372 | if id, _ := m.Focused(); id != 2 || m.Current().Name != "dev" { | |
| 373 | 373 | t.Fatal(id, windows(m)) | |
| 374 | 374 | } | |
| @@ -154,12 +154,12 @@ func TestMonitorActions(t *testing.T) { | |||||
| 154 | t.Fatal(m.Active) | 154 | t.Fatal(m.Active) | ||
| 155 | } | 155 | } | ||
| 156 | // Up at the top workspace stays. | 156 | // Up at the top workspace stays. | ||
| 157 | - | m.Apply(ActionFocusWorkspaceUp) | 157 | + | m.Apply(ActionFocusWorkspacePrev) |
| 158 | if m.Active != 0 { | 158 | if m.Active != 0 { | ||
| 159 | t.Fatal(m.Active) | 159 | t.Fatal(m.Active) | ||
| 160 | } | 160 | } | ||
| 161 | // Move the focused window (2) down: focus stays on workspace 1. | 161 | // Move the focused window (2) down: focus stays on workspace 1. | ||
| 162 | - | m.Apply(ActionMoveWindowToWorkspaceDown) | 162 | + | m.Apply(ActionMoveWindowToWorkspaceNext) |
| 163 | if !reflect.DeepEqual(windows(m), [][]WindowID{{1}, {2}, {}}) || m.Active != 0 { | 163 | if !reflect.DeepEqual(windows(m), [][]WindowID{{1}, {2}, {}}) || m.Active != 0 { | ||
| 164 | t.Fatal(windows(m), m.Active) | 164 | t.Fatal(windows(m), m.Active) | ||
| 165 | } | 165 | } | ||
| @@ -235,7 +235,7 @@ func TestMoveColumnToWorkspace(t *testing.T) { | |||||
| 235 | }) | 235 | }) | ||
| 236 | t.Run("window only", func(t *testing.T) { | 236 | t.Run("window only", func(t *testing.T) { | ||
| 237 | m := stack() | 237 | m := stack() | ||
| 238 | - | m.Apply(ActionMoveWindowToWorkspaceDown) | 238 | + | m.Apply(ActionMoveWindowToWorkspaceNext) |
| 239 | if got := windows(m); !reflect.DeepEqual(got, [][]WindowID{{1, 2}, {3}, {}}) { | 239 | if got := windows(m); !reflect.DeepEqual(got, [][]WindowID{{1, 2}, {3}, {}}) { | ||
| 240 | t.Fatal(got) | 240 | t.Fatal(got) | ||
| 241 | } | 241 | } | ||
| @@ -243,7 +243,7 @@ func TestMoveColumnToWorkspace(t *testing.T) { | |||||
| 243 | t.Run("follow shows the target", func(t *testing.T) { | 243 | t.Run("follow shows the target", func(t *testing.T) { | ||
| 244 | m := stack() | 244 | m := stack() | ||
| 245 | m.SetFollowMove(true) | 245 | m.SetFollowMove(true) | ||
| 246 | - | m.Apply(ActionMoveColumnToWorkspaceDown) | 246 | + | m.Apply(ActionMoveColumnToWorkspaceNext) |
| 247 | if id, _ := m.Focused(); m.Active != 1 || id != 3 { | 247 | if id, _ := m.Focused(); m.Active != 1 || id != 3 { | ||
| 248 | t.Fatal(m.Active, id) | 248 | t.Fatal(m.Active, id) | ||
| 249 | } | 249 | } | ||
| @@ -255,7 +255,7 @@ func TestMoveColumnToWorkspace(t *testing.T) { | |||||
| 255 | m := stack() | 255 | m := stack() | ||
| 256 | c := &m.Current().Columns[1] | 256 | c := &m.Current().Columns[1] | ||
| 257 | c.Slot, c.Focus = 2, 0 | 257 | c.Slot, c.Focus = 2, 0 | ||
| 258 | - | m.Apply(ActionMoveWindowToWorkspaceDown) | 258 | + | m.Apply(ActionMoveWindowToWorkspaceNext) |
| 259 | if c := m.Current().Columns[1]; c.Slot != 0 || c.Windows[0] != 3 { | 259 | if c := m.Current().Columns[1]; c.Slot != 0 || c.Windows[0] != 3 { | ||
| 260 | t.Fatal(c) | 260 | t.Fatal(c) | ||
| 261 | } | 261 | } | ||
| @@ -265,7 +265,7 @@ func TestMoveColumnToWorkspace(t *testing.T) { | |||||
| 265 | m.SetFollowMove(true) | 265 | m.SetFollowMove(true) | ||
| 266 | m.AddFloating(9, 10, 10) | 266 | m.AddFloating(9, 10, 10) | ||
| 267 | m.Current().FocusID(9) | 267 | m.Current().FocusID(9) | ||
| 268 | - | m.Apply(ActionMoveWindowToWorkspaceDown) | 268 | + | m.Apply(ActionMoveWindowToWorkspaceNext) |
| 269 | if id, _ := m.Focused(); m.Active != 1 || id != 9 { | 269 | if id, _ := m.Focused(); m.Active != 1 || id != 9 { | ||
| 270 | t.Fatal(m.Active, id) | 270 | t.Fatal(m.Active, id) | ||
| 271 | } | 271 | } | ||
| @@ -273,7 +273,7 @@ func TestMoveColumnToWorkspace(t *testing.T) { | |||||
| 273 | t.Run("slot column loses its slot", func(t *testing.T) { | 273 | t.Run("slot column loses its slot", func(t *testing.T) { | ||
| 274 | m := stack() | 274 | m := stack() | ||
| 275 | m.Current().Columns[1].Slot = 2 | 275 | m.Current().Columns[1].Slot = 2 | ||
| 276 | - | m.Apply(ActionMoveColumnToWorkspaceDown) | 276 | + | m.Apply(ActionMoveColumnToWorkspaceNext) |
| 277 | if c := m.Workspaces[1].Columns[0]; c.Slot != 0 { | 277 | if c := m.Workspaces[1].Columns[0]; c.Slot != 0 { | ||
| 278 | t.Fatal(c) | 278 | t.Fatal(c) | ||
| 279 | } | 279 | } | ||
| @@ -344,7 +344,7 @@ func TestHiddenWorkspaceToggle(t *testing.T) { | |||||
| 344 | } | 344 | } | ||
| 345 | m.AddWindow(2) | 345 | m.AddWindow(2) | ||
| 346 | // Up/down do not leave a hidden workspace. | 346 | // Up/down do not leave a hidden workspace. | ||
| 347 | - | m.Apply(ActionFocusWorkspaceDown) | 347 | + | m.Apply(ActionFocusWorkspaceNext) |
| 348 | m.Apply(ActionFocusWindowDown) | 348 | m.Apply(ActionFocusWindowDown) | ||
| 349 | if m.Current().Name != "dev" { | 349 | if m.Current().Name != "dev" { | ||
| 350 | t.Fatal("left the hidden workspace") | 350 | t.Fatal("left the hidden workspace") | ||
| @@ -367,8 +367,8 @@ func TestHiddenWorkspaceToggle(t *testing.T) { | |||||
| 367 | } | 367 | } | ||
| 368 | // Moving a window up/down from a hidden workspace does nothing. | 368 | // Moving a window up/down from a hidden workspace does nothing. | ||
| 369 | m.Apply("workspace dev") | 369 | m.Apply("workspace dev") | ||
| 370 | - | m.Apply(ActionMoveWindowToWorkspaceDown) | 370 | + | m.Apply(ActionMoveWindowToWorkspaceNext) |
| 371 | - | m.Apply(ActionMoveWindowToWorkspaceUp) | 371 | + | m.Apply(ActionMoveWindowToWorkspacePrev) |
| 372 | if id, _ := m.Focused(); id != 2 || m.Current().Name != "dev" { | 372 | if id, _ := m.Focused(); id != 2 || m.Current().Name != "dev" { | ||
| 373 | t.Fatal(id, windows(m)) | 373 | t.Fatal(id, windows(m)) | ||
| 374 | } | 374 | } | ||
M internal/core/overview.go +4 -4
| @@ -192,8 +192,8 @@ func overviewBlocks(a Action) bool { | |||
| 192 | 192 | ActionToggleStashVisible, ActionConsumeOrExpelLeft, | |
| 193 | 193 | ActionConsumeOrExpelRight, ActionMoveWorkspaceLeft, ActionMoveWorkspaceRight, | |
| 194 | 194 | ActionMoveWorkspaceToMonitorUp, ActionMoveWorkspaceToMonitorDown, | |
| 195 | - | ActionMoveWindowUp, ActionMoveWindowDown, ActionMoveWorkspaceUp, | |
| 196 | - | ActionMoveWorkspaceDown, ActionToggleFloating: | |
| 195 | + | ActionMoveWindowUp, ActionMoveWindowDown, ActionMoveWorkspacePrev, | |
| 196 | + | ActionMoveWorkspaceNext, ActionToggleFloating: | |
| 197 | 197 | return true | |
| 198 | 198 | } | |
| 199 | 199 | return false | |
| @@ -921,9 +921,9 @@ func (m *Monitor) overviewFocus(a Action) bool { | |||
| 921 | 921 | m.OverviewMove(-1, 0) | |
| 922 | 922 | case ActionFocusColumnRight: | |
| 923 | 923 | m.OverviewMove(1, 0) | |
| 924 | - | case ActionFocusWindowUp, ActionFocusWorkspaceUp: | |
| 924 | + | case ActionFocusWindowUp, ActionFocusWorkspacePrev: | |
| 925 | 925 | m.OverviewMove(0, -1) | |
| 926 | - | case ActionFocusWindowDown, ActionFocusWorkspaceDown: | |
| 926 | + | case ActionFocusWindowDown, ActionFocusWorkspaceNext: | |
| 927 | 927 | m.OverviewMove(0, 1) | |
| 928 | 928 | default: | |
| 929 | 929 | return false | |
| @@ -192,8 +192,8 @@ func overviewBlocks(a Action) bool { | |||||
| 192 | ActionToggleStashVisible, ActionConsumeOrExpelLeft, | 192 | ActionToggleStashVisible, ActionConsumeOrExpelLeft, | ||
| 193 | ActionConsumeOrExpelRight, ActionMoveWorkspaceLeft, ActionMoveWorkspaceRight, | 193 | ActionConsumeOrExpelRight, ActionMoveWorkspaceLeft, ActionMoveWorkspaceRight, | ||
| 194 | ActionMoveWorkspaceToMonitorUp, ActionMoveWorkspaceToMonitorDown, | 194 | ActionMoveWorkspaceToMonitorUp, ActionMoveWorkspaceToMonitorDown, | ||
| 195 | - | ActionMoveWindowUp, ActionMoveWindowDown, ActionMoveWorkspaceUp, | 195 | + | ActionMoveWindowUp, ActionMoveWindowDown, ActionMoveWorkspacePrev, |
| 196 | - | ActionMoveWorkspaceDown, ActionToggleFloating: | 196 | + | ActionMoveWorkspaceNext, ActionToggleFloating: |
| 197 | return true | 197 | return true | ||
| 198 | } | 198 | } | ||
| 199 | return false | 199 | return false | ||
| @@ -921,9 +921,9 @@ func (m *Monitor) overviewFocus(a Action) bool { | |||||
| 921 | m.OverviewMove(-1, 0) | 921 | m.OverviewMove(-1, 0) | ||
| 922 | case ActionFocusColumnRight: | 922 | case ActionFocusColumnRight: | ||
| 923 | m.OverviewMove(1, 0) | 923 | m.OverviewMove(1, 0) | ||
| 924 | - | case ActionFocusWindowUp, ActionFocusWorkspaceUp: | 924 | + | case ActionFocusWindowUp, ActionFocusWorkspacePrev: |
| 925 | m.OverviewMove(0, -1) | 925 | m.OverviewMove(0, -1) | ||
| 926 | - | case ActionFocusWindowDown, ActionFocusWorkspaceDown: | 926 | + | case ActionFocusWindowDown, ActionFocusWorkspaceNext: |
| 927 | m.OverviewMove(0, 1) | 927 | m.OverviewMove(0, 1) | ||
| 928 | default: | 928 | default: | ||
| 929 | return false | 929 | return false | ||
M internal/core/overview_behavior_test.go +3 -3
| @@ -15,15 +15,15 @@ func TestOverviewVerticalBoundariesAndInputs(t *testing.T) { | |||
| 15 | 15 | if m.stackFront(w) != (stackItem{stackFloat, 9}) { | |
| 16 | 16 | t.Fatal("screen front") | |
| 17 | 17 | } | |
| 18 | - | m.overviewFocus(ActionFocusWorkspaceUp) | |
| 18 | + | m.overviewFocus(ActionFocusWorkspacePrev) | |
| 19 | 19 | if m.stackFront(w).kind != stackColumns || m.Active != 0 { | |
| 20 | 20 | t.Fatal("swipe did not visit card") | |
| 21 | 21 | } | |
| 22 | - | m.overviewFocus(ActionFocusWorkspaceUp) | |
| 22 | + | m.overviewFocus(ActionFocusWorkspacePrev) | |
| 23 | 23 | if m.Active != 0 { | |
| 24 | 24 | t.Fatal("up at top crossed workspace boundary") | |
| 25 | 25 | } | |
| 26 | - | m.overviewFocus(ActionFocusWorkspaceDown) | |
| 26 | + | m.overviewFocus(ActionFocusWorkspaceNext) | |
| 27 | 27 | if m.stackFront(w).kind != stackFloat || m.Active != 0 { | |
| 28 | 28 | t.Fatal("down did not return to front") | |
| 29 | 29 | } | |
| @@ -15,15 +15,15 @@ func TestOverviewVerticalBoundariesAndInputs(t *testing.T) { | |||||
| 15 | if m.stackFront(w) != (stackItem{stackFloat, 9}) { | 15 | if m.stackFront(w) != (stackItem{stackFloat, 9}) { | ||
| 16 | t.Fatal("screen front") | 16 | t.Fatal("screen front") | ||
| 17 | } | 17 | } | ||
| 18 | - | m.overviewFocus(ActionFocusWorkspaceUp) | 18 | + | m.overviewFocus(ActionFocusWorkspacePrev) |
| 19 | if m.stackFront(w).kind != stackColumns || m.Active != 0 { | 19 | if m.stackFront(w).kind != stackColumns || m.Active != 0 { | ||
| 20 | t.Fatal("swipe did not visit card") | 20 | t.Fatal("swipe did not visit card") | ||
| 21 | } | 21 | } | ||
| 22 | - | m.overviewFocus(ActionFocusWorkspaceUp) | 22 | + | m.overviewFocus(ActionFocusWorkspacePrev) |
| 23 | if m.Active != 0 { | 23 | if m.Active != 0 { | ||
| 24 | t.Fatal("up at top crossed workspace boundary") | 24 | t.Fatal("up at top crossed workspace boundary") | ||
| 25 | } | 25 | } | ||
| 26 | - | m.overviewFocus(ActionFocusWorkspaceDown) | 26 | + | m.overviewFocus(ActionFocusWorkspaceNext) |
| 27 | if m.stackFront(w).kind != stackFloat || m.Active != 0 { | 27 | if m.stackFront(w).kind != stackFloat || m.Active != 0 { | ||
| 28 | t.Fatal("down did not return to front") | 28 | t.Fatal("down did not return to front") | ||
| 29 | } | 29 | } | ||
M internal/core/overview_cover_test.go +1 -1
| @@ -173,7 +173,7 @@ func TestOverviewCoverActsOnSelection(t *testing.T) { | |||
| 173 | 173 | t.Fatalf("behind close %d", e.Close) | |
| 174 | 174 | } | |
| 175 | 175 | w := m.Current() | |
| 176 | - | m.Apply(ActionMoveWindowToWorkspaceDown) | |
| 176 | + | m.Apply(ActionMoveWindowToWorkspaceNext) | |
| 177 | 177 | if got, _ := m.find(1); got == w || !w.has(2) { | |
| 178 | 178 | t.Fatalf("moved the wrong window: %v", windows(m)) | |
| 179 | 179 | } | |
| @@ -173,7 +173,7 @@ func TestOverviewCoverActsOnSelection(t *testing.T) { | |||||
| 173 | t.Fatalf("behind close %d", e.Close) | 173 | t.Fatalf("behind close %d", e.Close) | ||
| 174 | } | 174 | } | ||
| 175 | w := m.Current() | 175 | w := m.Current() | ||
| 176 | - | m.Apply(ActionMoveWindowToWorkspaceDown) | 176 | + | m.Apply(ActionMoveWindowToWorkspaceNext) |
| 177 | if got, _ := m.find(1); got == w || !w.has(2) { | 177 | if got, _ := m.find(1); got == w || !w.has(2) { | ||
| 178 | t.Fatalf("moved the wrong window: %v", windows(m)) | 178 | t.Fatalf("moved the wrong window: %v", windows(m)) | ||
| 179 | } | 179 | } | ||
M internal/core/overview_move_test.go +13 -13
| @@ -15,11 +15,11 @@ func TestOverviewMove(t *testing.T) { | |||
| 15 | 15 | // row is the workspace index current after the move. | |
| 16 | 16 | row int | |
| 17 | 17 | }{ | |
| 18 | - | {"column down", ActionMoveColumnToWorkspaceDown, false, 0}, | |
| 19 | - | {"window down", ActionMoveWindowToWorkspaceDown, false, 0}, | |
| 18 | + | {"column next", ActionMoveColumnToWorkspaceNext, false, 0}, | |
| 19 | + | {"window next", ActionMoveWindowToWorkspaceNext, false, 0}, | |
| 20 | 20 | {"column numbered", "move-column-to-workspace 2", false, 0}, | |
| 21 | 21 | {"window numbered", "move-window-to-workspace 2", false, 0}, | |
| 22 | - | {"follows", ActionMoveColumnToWorkspaceDown, true, 1}, | |
| 22 | + | {"follows", ActionMoveColumnToWorkspaceNext, true, 1}, | |
| 23 | 23 | } | |
| 24 | 24 | for _, tt := range tests { | |
| 25 | 25 | t.Run(tt.name, func(t *testing.T) { | |
| @@ -67,7 +67,7 @@ func TestOverviewMoveWindowFromStack(t *testing.T) { | |||
| 67 | 67 | if m.overviewTarget() != 2 { | |
| 68 | 68 | t.Fatalf("selection %d", m.overviewTarget()) | |
| 69 | 69 | } | |
| 70 | - | m.Apply(ActionMoveWindowToWorkspaceDown) | |
| 70 | + | m.Apply(ActionMoveWindowToWorkspaceNext) | |
| 71 | 71 | if !slices.Equal(w.windows(), []WindowID{1, 3}) || !slices.Contains(m.Workspaces[1].windows(), 2) { | |
| 72 | 72 | t.Fatalf("windows %v", windows(m)) | |
| 73 | 73 | } | |
| @@ -82,7 +82,7 @@ func TestOverviewMoveSelectedUnderFloat(t *testing.T) { | |||
| 82 | 82 | if id == 0 || id == 9 { | |
| 83 | 83 | t.Fatalf("selection %d", id) | |
| 84 | 84 | } | |
| 85 | - | m.Apply(ActionMoveColumnToWorkspaceDown) | |
| 85 | + | m.Apply(ActionMoveColumnToWorkspaceNext) | |
| 86 | 86 | if !slices.Contains(m.Workspaces[1].windows(), id) || m.Workspaces[1].isFloat(9) { | |
| 87 | 87 | t.Fatalf("moved the wrong window: %v floats %v", windows(m), m.Workspaces[0].Floats) | |
| 88 | 88 | } | |
| @@ -107,20 +107,20 @@ func TestOverviewMoveNoop(t *testing.T) { | |||
| 107 | 107 | t.Fatal("no stash card selected") | |
| 108 | 108 | } | |
| 109 | 109 | return m | |
| 110 | - | }, ActionMoveColumnToWorkspaceDown}, | |
| 110 | + | }, ActionMoveColumnToWorkspaceNext}, | |
| 111 | 111 | {"hidden small float", func() *Monitor { | |
| 112 | 112 | m := newMonitor("", "") | |
| 113 | 113 | m.SetOutput(300, 200) | |
| 114 | 114 | m.AddFloating(9, 50, 50) | |
| 115 | 115 | m.ToggleOverview() | |
| 116 | 116 | return m | |
| 117 | - | }, ActionMoveWindowToWorkspaceDown}, | |
| 117 | + | }, ActionMoveWindowToWorkspaceNext}, | |
| 118 | 118 | {"up from first", func() *Monitor { | |
| 119 | 119 | m := overviewMonitor() | |
| 120 | 120 | m.ToggleOverview() | |
| 121 | 121 | m.OverviewMove(-1, 0) | |
| 122 | 122 | return m | |
| 123 | - | }, ActionMoveColumnToWorkspaceUp}, | |
| 123 | + | }, ActionMoveColumnToWorkspacePrev}, | |
| 124 | 124 | {"to its own row", func() *Monitor { | |
| 125 | 125 | m := overviewMonitor() | |
| 126 | 126 | m.ToggleOverview() | |
| @@ -132,7 +132,7 @@ func TestOverviewMoveNoop(t *testing.T) { | |||
| 132 | 132 | m.ToggleNamed("game") | |
| 133 | 133 | m.ToggleOverview() | |
| 134 | 134 | return m | |
| 135 | - | }, ActionMoveColumnToWorkspaceDown}, | |
| 135 | + | }, ActionMoveColumnToWorkspaceNext}, | |
| 136 | 136 | {"fixed maximize kept", func() *Monitor { | |
| 137 | 137 | m := overviewMonitor() | |
| 138 | 138 | w := m.Current() | |
| @@ -142,7 +142,7 @@ func TestOverviewMoveNoop(t *testing.T) { | |||
| 142 | 142 | m.ToggleOverview() | |
| 143 | 143 | m.OverviewMove(0, -1) | |
| 144 | 144 | return m | |
| 145 | - | }, ActionMoveColumnToWorkspaceUp}, | |
| 145 | + | }, ActionMoveColumnToWorkspacePrev}, | |
| 146 | 146 | } | |
| 147 | 147 | for _, tt := range tests { | |
| 148 | 148 | t.Run(tt.name, func(t *testing.T) { | |
| @@ -163,7 +163,7 @@ func TestOverviewMoveDestinationKeepsFocus(t *testing.T) { | |||
| 163 | 163 | m.OverviewMove(0, 1) | |
| 164 | 164 | m.OverviewMove(0, -1) | |
| 165 | 165 | m.OverviewMove(-1, 0) | |
| 166 | - | m.Apply(ActionMoveColumnToWorkspaceDown) | |
| 166 | + | m.Apply(ActionMoveColumnToWorkspaceNext) | |
| 167 | 167 | m.ToggleOverview() | |
| 168 | 168 | if id, _ := m.Workspaces[1].Focused(); id != 2 { | |
| 169 | 169 | t.Fatalf("destination focus %d, want 2", id) | |
| @@ -179,7 +179,7 @@ func TestOverviewMoveDropsMaximizeHistory(t *testing.T) { | |||
| 179 | 179 | w.FocusID(3) | |
| 180 | 180 | w.ToggleFullWidth() | |
| 181 | 181 | m.ToggleOverview() | |
| 182 | - | m.Apply(ActionMoveColumnToWorkspaceDown) | |
| 182 | + | m.Apply(ActionMoveColumnToWorkspaceNext) | |
| 183 | 183 | if w.has(3) { | |
| 184 | 184 | t.Fatal("3 not moved") | |
| 185 | 185 | } | |
| @@ -209,7 +209,7 @@ func TestOverviewMoveFromFullscreenRow(t *testing.T) { | |||
| 209 | 209 | if m.overviewTarget() != 2 { | |
| 210 | 210 | t.Fatalf("follow %v: selection %d", follow, m.overviewTarget()) | |
| 211 | 211 | } | |
| 212 | - | m.Apply(ActionMoveColumnToWorkspaceDown) | |
| 212 | + | m.Apply(ActionMoveColumnToWorkspaceNext) | |
| 213 | 213 | if !slices.Equal(w.windows(), []WindowID{1, 3, 4}) || !slices.Equal(m.Workspaces[1].windows(), []WindowID{2}) { | |
| 214 | 214 | t.Fatalf("follow %v: windows %v", follow, windows(m)) | |
| 215 | 215 | } | |
| @@ -15,11 +15,11 @@ func TestOverviewMove(t *testing.T) { | |||||
| 15 | // row is the workspace index current after the move. | 15 | // row is the workspace index current after the move. | ||
| 16 | row int | 16 | row int | ||
| 17 | }{ | 17 | }{ | ||
| 18 | - | {"column down", ActionMoveColumnToWorkspaceDown, false, 0}, | 18 | + | {"column next", ActionMoveColumnToWorkspaceNext, false, 0}, |
| 19 | - | {"window down", ActionMoveWindowToWorkspaceDown, false, 0}, | 19 | + | {"window next", ActionMoveWindowToWorkspaceNext, false, 0}, |
| 20 | {"column numbered", "move-column-to-workspace 2", false, 0}, | 20 | {"column numbered", "move-column-to-workspace 2", false, 0}, | ||
| 21 | {"window numbered", "move-window-to-workspace 2", false, 0}, | 21 | {"window numbered", "move-window-to-workspace 2", false, 0}, | ||
| 22 | - | {"follows", ActionMoveColumnToWorkspaceDown, true, 1}, | 22 | + | {"follows", ActionMoveColumnToWorkspaceNext, true, 1}, |
| 23 | } | 23 | } | ||
| 24 | for _, tt := range tests { | 24 | for _, tt := range tests { | ||
| 25 | t.Run(tt.name, func(t *testing.T) { | 25 | t.Run(tt.name, func(t *testing.T) { | ||
| @@ -67,7 +67,7 @@ func TestOverviewMoveWindowFromStack(t *testing.T) { | |||||
| 67 | if m.overviewTarget() != 2 { | 67 | if m.overviewTarget() != 2 { | ||
| 68 | t.Fatalf("selection %d", m.overviewTarget()) | 68 | t.Fatalf("selection %d", m.overviewTarget()) | ||
| 69 | } | 69 | } | ||
| 70 | - | m.Apply(ActionMoveWindowToWorkspaceDown) | 70 | + | m.Apply(ActionMoveWindowToWorkspaceNext) |
| 71 | if !slices.Equal(w.windows(), []WindowID{1, 3}) || !slices.Contains(m.Workspaces[1].windows(), 2) { | 71 | if !slices.Equal(w.windows(), []WindowID{1, 3}) || !slices.Contains(m.Workspaces[1].windows(), 2) { | ||
| 72 | t.Fatalf("windows %v", windows(m)) | 72 | t.Fatalf("windows %v", windows(m)) | ||
| 73 | } | 73 | } | ||
| @@ -82,7 +82,7 @@ func TestOverviewMoveSelectedUnderFloat(t *testing.T) { | |||||
| 82 | if id == 0 || id == 9 { | 82 | if id == 0 || id == 9 { | ||
| 83 | t.Fatalf("selection %d", id) | 83 | t.Fatalf("selection %d", id) | ||
| 84 | } | 84 | } | ||
| 85 | - | m.Apply(ActionMoveColumnToWorkspaceDown) | 85 | + | m.Apply(ActionMoveColumnToWorkspaceNext) |
| 86 | if !slices.Contains(m.Workspaces[1].windows(), id) || m.Workspaces[1].isFloat(9) { | 86 | if !slices.Contains(m.Workspaces[1].windows(), id) || m.Workspaces[1].isFloat(9) { | ||
| 87 | t.Fatalf("moved the wrong window: %v floats %v", windows(m), m.Workspaces[0].Floats) | 87 | t.Fatalf("moved the wrong window: %v floats %v", windows(m), m.Workspaces[0].Floats) | ||
| 88 | } | 88 | } | ||
| @@ -107,20 +107,20 @@ func TestOverviewMoveNoop(t *testing.T) { | |||||
| 107 | t.Fatal("no stash card selected") | 107 | t.Fatal("no stash card selected") | ||
| 108 | } | 108 | } | ||
| 109 | return m | 109 | return m | ||
| 110 | - | }, ActionMoveColumnToWorkspaceDown}, | 110 | + | }, ActionMoveColumnToWorkspaceNext}, |
| 111 | {"hidden small float", func() *Monitor { | 111 | {"hidden small float", func() *Monitor { | ||
| 112 | m := newMonitor("", "") | 112 | m := newMonitor("", "") | ||
| 113 | m.SetOutput(300, 200) | 113 | m.SetOutput(300, 200) | ||
| 114 | m.AddFloating(9, 50, 50) | 114 | m.AddFloating(9, 50, 50) | ||
| 115 | m.ToggleOverview() | 115 | m.ToggleOverview() | ||
| 116 | return m | 116 | return m | ||
| 117 | - | }, ActionMoveWindowToWorkspaceDown}, | 117 | + | }, ActionMoveWindowToWorkspaceNext}, |
| 118 | {"up from first", func() *Monitor { | 118 | {"up from first", func() *Monitor { | ||
| 119 | m := overviewMonitor() | 119 | m := overviewMonitor() | ||
| 120 | m.ToggleOverview() | 120 | m.ToggleOverview() | ||
| 121 | m.OverviewMove(-1, 0) | 121 | m.OverviewMove(-1, 0) | ||
| 122 | return m | 122 | return m | ||
| 123 | - | }, ActionMoveColumnToWorkspaceUp}, | 123 | + | }, ActionMoveColumnToWorkspacePrev}, |
| 124 | {"to its own row", func() *Monitor { | 124 | {"to its own row", func() *Monitor { | ||
| 125 | m := overviewMonitor() | 125 | m := overviewMonitor() | ||
| 126 | m.ToggleOverview() | 126 | m.ToggleOverview() | ||
| @@ -132,7 +132,7 @@ func TestOverviewMoveNoop(t *testing.T) { | |||||
| 132 | m.ToggleNamed("game") | 132 | m.ToggleNamed("game") | ||
| 133 | m.ToggleOverview() | 133 | m.ToggleOverview() | ||
| 134 | return m | 134 | return m | ||
| 135 | - | }, ActionMoveColumnToWorkspaceDown}, | 135 | + | }, ActionMoveColumnToWorkspaceNext}, |
| 136 | {"fixed maximize kept", func() *Monitor { | 136 | {"fixed maximize kept", func() *Monitor { | ||
| 137 | m := overviewMonitor() | 137 | m := overviewMonitor() | ||
| 138 | w := m.Current() | 138 | w := m.Current() | ||
| @@ -142,7 +142,7 @@ func TestOverviewMoveNoop(t *testing.T) { | |||||
| 142 | m.ToggleOverview() | 142 | m.ToggleOverview() | ||
| 143 | m.OverviewMove(0, -1) | 143 | m.OverviewMove(0, -1) | ||
| 144 | return m | 144 | return m | ||
| 145 | - | }, ActionMoveColumnToWorkspaceUp}, | 145 | + | }, ActionMoveColumnToWorkspacePrev}, |
| 146 | } | 146 | } | ||
| 147 | for _, tt := range tests { | 147 | for _, tt := range tests { | ||
| 148 | t.Run(tt.name, func(t *testing.T) { | 148 | t.Run(tt.name, func(t *testing.T) { | ||
| @@ -163,7 +163,7 @@ func TestOverviewMoveDestinationKeepsFocus(t *testing.T) { | |||||
| 163 | m.OverviewMove(0, 1) | 163 | m.OverviewMove(0, 1) | ||
| 164 | m.OverviewMove(0, -1) | 164 | m.OverviewMove(0, -1) | ||
| 165 | m.OverviewMove(-1, 0) | 165 | m.OverviewMove(-1, 0) | ||
| 166 | - | m.Apply(ActionMoveColumnToWorkspaceDown) | 166 | + | m.Apply(ActionMoveColumnToWorkspaceNext) |
| 167 | m.ToggleOverview() | 167 | m.ToggleOverview() | ||
| 168 | if id, _ := m.Workspaces[1].Focused(); id != 2 { | 168 | if id, _ := m.Workspaces[1].Focused(); id != 2 { | ||
| 169 | t.Fatalf("destination focus %d, want 2", id) | 169 | t.Fatalf("destination focus %d, want 2", id) | ||
| @@ -179,7 +179,7 @@ func TestOverviewMoveDropsMaximizeHistory(t *testing.T) { | |||||
| 179 | w.FocusID(3) | 179 | w.FocusID(3) | ||
| 180 | w.ToggleFullWidth() | 180 | w.ToggleFullWidth() | ||
| 181 | m.ToggleOverview() | 181 | m.ToggleOverview() | ||
| 182 | - | m.Apply(ActionMoveColumnToWorkspaceDown) | 182 | + | m.Apply(ActionMoveColumnToWorkspaceNext) |
| 183 | if w.has(3) { | 183 | if w.has(3) { | ||
| 184 | t.Fatal("3 not moved") | 184 | t.Fatal("3 not moved") | ||
| 185 | } | 185 | } | ||
| @@ -209,7 +209,7 @@ func TestOverviewMoveFromFullscreenRow(t *testing.T) { | |||||
| 209 | if m.overviewTarget() != 2 { | 209 | if m.overviewTarget() != 2 { | ||
| 210 | t.Fatalf("follow %v: selection %d", follow, m.overviewTarget()) | 210 | t.Fatalf("follow %v: selection %d", follow, m.overviewTarget()) | ||
| 211 | } | 211 | } | ||
| 212 | - | m.Apply(ActionMoveColumnToWorkspaceDown) | 212 | + | m.Apply(ActionMoveColumnToWorkspaceNext) |
| 213 | if !slices.Equal(w.windows(), []WindowID{1, 3, 4}) || !slices.Equal(m.Workspaces[1].windows(), []WindowID{2}) { | 213 | if !slices.Equal(w.windows(), []WindowID{1, 3, 4}) || !slices.Equal(m.Workspaces[1].windows(), []WindowID{2}) { | ||
| 214 | t.Fatalf("follow %v: windows %v", follow, windows(m)) | 214 | t.Fatalf("follow %v: windows %v", follow, windows(m)) | ||
| 215 | } | 215 | } | ||
M internal/core/overview_named_test.go +4 -4
| @@ -319,7 +319,7 @@ func TestOverviewNamedNeighborPick(t *testing.T) { | |||
| 319 | 319 | } | |
| 320 | 320 | ||
| 321 | 321 | func TestOverviewNamedFocusBinds(t *testing.T) { | |
| 322 | - | for _, action := range []Action{ActionFocusWindowDown, ActionFocusWorkspaceDown} { | |
| 322 | + | for _, action := range []Action{ActionFocusWindowDown, ActionFocusWorkspaceNext} { | |
| 323 | 323 | t.Run(string(action), func(t *testing.T) { | |
| 324 | 324 | m := namedOverviewMonitor() | |
| 325 | 325 | m.ToggleOverview() | |
| @@ -343,12 +343,12 @@ func TestOverviewNamedFocusBinds(t *testing.T) { | |||
| 343 | 343 | ||
| 344 | 344 | func TestOverviewNamedOutsideNavigationUnchanged(t *testing.T) { | |
| 345 | 345 | m := namedOverviewMonitor() | |
| 346 | - | m.Apply(ActionFocusWorkspaceDown) | |
| 346 | + | m.Apply(ActionFocusWorkspaceNext) | |
| 347 | 347 | if m.shown != nil || !m.Current().empty() { | |
| 348 | 348 | t.Fatal("outside overview, down no longer reaches numbered spare") | |
| 349 | 349 | } | |
| 350 | 350 | m.ToggleNamed("dev") | |
| 351 | - | m.Apply(ActionFocusWorkspaceUp) | |
| 351 | + | m.Apply(ActionFocusWorkspacePrev) | |
| 352 | 352 | if m.Current().Name != "dev" { | |
| 353 | 353 | t.Fatal("outside overview, named workspace entered numbered list") | |
| 354 | 354 | } | |
| @@ -414,7 +414,7 @@ func TestOverviewNamedDividerPublished(t *testing.T) { | |||
| 414 | 414 | func TestOverviewNamedScrollAndSwipe(t *testing.T) { | |
| 415 | 415 | m := namedOverviewMonitor() | |
| 416 | 416 | m.ToggleOverview() | |
| 417 | - | m.overviewFocus(ActionFocusWorkspaceDown) | |
| 417 | + | m.overviewFocus(ActionFocusWorkspaceNext) | |
| 418 | 418 | if m.Current().Name != "dev" { | |
| 419 | 419 | t.Fatal("swipe did not cross groups") | |
| 420 | 420 | } | |
| @@ -319,7 +319,7 @@ func TestOverviewNamedNeighborPick(t *testing.T) { | |||||
| 319 | } | 319 | } | ||
| 320 | 320 | ||||
| 321 | func TestOverviewNamedFocusBinds(t *testing.T) { | 321 | func TestOverviewNamedFocusBinds(t *testing.T) { | ||
| 322 | - | for _, action := range []Action{ActionFocusWindowDown, ActionFocusWorkspaceDown} { | 322 | + | for _, action := range []Action{ActionFocusWindowDown, ActionFocusWorkspaceNext} { |
| 323 | t.Run(string(action), func(t *testing.T) { | 323 | t.Run(string(action), func(t *testing.T) { | ||
| 324 | m := namedOverviewMonitor() | 324 | m := namedOverviewMonitor() | ||
| 325 | m.ToggleOverview() | 325 | m.ToggleOverview() | ||
| @@ -343,12 +343,12 @@ func TestOverviewNamedFocusBinds(t *testing.T) { | |||||
| 343 | 343 | ||||
| 344 | func TestOverviewNamedOutsideNavigationUnchanged(t *testing.T) { | 344 | func TestOverviewNamedOutsideNavigationUnchanged(t *testing.T) { | ||
| 345 | m := namedOverviewMonitor() | 345 | m := namedOverviewMonitor() | ||
| 346 | - | m.Apply(ActionFocusWorkspaceDown) | 346 | + | m.Apply(ActionFocusWorkspaceNext) |
| 347 | if m.shown != nil || !m.Current().empty() { | 347 | if m.shown != nil || !m.Current().empty() { | ||
| 348 | t.Fatal("outside overview, down no longer reaches numbered spare") | 348 | t.Fatal("outside overview, down no longer reaches numbered spare") | ||
| 349 | } | 349 | } | ||
| 350 | m.ToggleNamed("dev") | 350 | m.ToggleNamed("dev") | ||
| 351 | - | m.Apply(ActionFocusWorkspaceUp) | 351 | + | m.Apply(ActionFocusWorkspacePrev) |
| 352 | if m.Current().Name != "dev" { | 352 | if m.Current().Name != "dev" { | ||
| 353 | t.Fatal("outside overview, named workspace entered numbered list") | 353 | t.Fatal("outside overview, named workspace entered numbered list") | ||
| 354 | } | 354 | } | ||
| @@ -414,7 +414,7 @@ func TestOverviewNamedDividerPublished(t *testing.T) { | |||||
| 414 | func TestOverviewNamedScrollAndSwipe(t *testing.T) { | 414 | func TestOverviewNamedScrollAndSwipe(t *testing.T) { | ||
| 415 | m := namedOverviewMonitor() | 415 | m := namedOverviewMonitor() | ||
| 416 | m.ToggleOverview() | 416 | m.ToggleOverview() | ||
| 417 | - | m.overviewFocus(ActionFocusWorkspaceDown) | 417 | + | m.overviewFocus(ActionFocusWorkspaceNext) |
| 418 | if m.Current().Name != "dev" { | 418 | if m.Current().Name != "dev" { | ||
| 419 | t.Fatal("swipe did not cross groups") | 419 | t.Fatal("swipe did not cross groups") | ||
| 420 | } | 420 | } | ||
M internal/core/overview_stash_input_test.go +2 -2
| @@ -34,9 +34,9 @@ func TestOverviewStashInputNavigation(t *testing.T) { | |||
| 34 | 34 | Vertical: ports.ScrollAxis{Set: dy != 0, Value: float64(dy) * 70, V120: int32(dy * 120)}}) | |
| 35 | 35 | c.scrollStop(ports.PointerAxis{Vertical: ports.ScrollAxis{Stop: true}}) | |
| 36 | 36 | case "bind": | |
| 37 | - | a := ActionFocusWorkspaceDown | |
| 37 | + | a := ActionFocusWorkspaceNext | |
| 38 | 38 | if dy < 0 { | |
| 39 | - | a = ActionFocusWorkspaceUp | |
| 39 | + | a = ActionFocusWorkspacePrev | |
| 40 | 40 | } else if dx > 0 { | |
| 41 | 41 | a = ActionFocusColumnRight | |
| 42 | 42 | } | |
| @@ -34,9 +34,9 @@ func TestOverviewStashInputNavigation(t *testing.T) { | |||||
| 34 | Vertical: ports.ScrollAxis{Set: dy != 0, Value: float64(dy) * 70, V120: int32(dy * 120)}}) | 34 | Vertical: ports.ScrollAxis{Set: dy != 0, Value: float64(dy) * 70, V120: int32(dy * 120)}}) | ||
| 35 | c.scrollStop(ports.PointerAxis{Vertical: ports.ScrollAxis{Stop: true}}) | 35 | c.scrollStop(ports.PointerAxis{Vertical: ports.ScrollAxis{Stop: true}}) | ||
| 36 | case "bind": | 36 | case "bind": | ||
| 37 | - | a := ActionFocusWorkspaceDown | 37 | + | a := ActionFocusWorkspaceNext |
| 38 | if dy < 0 { | 38 | if dy < 0 { | ||
| 39 | - | a = ActionFocusWorkspaceUp | 39 | + | a = ActionFocusWorkspacePrev |
| 40 | } else if dx > 0 { | 40 | } else if dx > 0 { | ||
| 41 | a = ActionFocusColumnRight | 41 | a = ActionFocusColumnRight | ||
| 42 | } | 42 | } | ||
M internal/core/screens_test.go +1 -1
| @@ -380,7 +380,7 @@ func TestMonitorActionsFollowGeometry(t *testing.T) { | |||
| 380 | 380 | {Name: "DP-1"}, | |
| 381 | 381 | {Name: "DP-2", Anchor: ports.OutputAnchor{Relation: ports.RelationBelow, To: "DP-1"}}, | |
| 382 | 382 | } | |
| 383 | - | // Without a default bind; these replace move-workspace-up/down. | |
| 383 | + | // Without a default bind; these replace move-workspace-prev/next. | |
| 384 | 384 | c.Binds["Cmd+Ctrl+Shift+Up"] = string(core.ActionMoveWorkspaceToMonitorUp) | |
| 385 | 385 | c.Binds["Cmd+Ctrl+Shift+Down"] = string(core.ActionMoveWorkspaceToMonitorDown) | |
| 386 | 386 | }, left, right) | |
| @@ -380,7 +380,7 @@ func TestMonitorActionsFollowGeometry(t *testing.T) { | |||||
| 380 | {Name: "DP-1"}, | 380 | {Name: "DP-1"}, | ||
| 381 | {Name: "DP-2", Anchor: ports.OutputAnchor{Relation: ports.RelationBelow, To: "DP-1"}}, | 381 | {Name: "DP-2", Anchor: ports.OutputAnchor{Relation: ports.RelationBelow, To: "DP-1"}}, | ||
| 382 | } | 382 | } | ||
| 383 | - | // Without a default bind; these replace move-workspace-up/down. | 383 | + | // Without a default bind; these replace move-workspace-prev/next. |
| 384 | c.Binds["Cmd+Ctrl+Shift+Up"] = string(core.ActionMoveWorkspaceToMonitorUp) | 384 | c.Binds["Cmd+Ctrl+Shift+Up"] = string(core.ActionMoveWorkspaceToMonitorUp) | ||
| 385 | c.Binds["Cmd+Ctrl+Shift+Down"] = string(core.ActionMoveWorkspaceToMonitorDown) | 385 | c.Binds["Cmd+Ctrl+Shift+Down"] = string(core.ActionMoveWorkspaceToMonitorDown) | ||
| 386 | }, left, right) | 386 | }, left, right) | ||
M internal/core/transition_chain_internal_test.go +1 -1
| @@ -114,7 +114,7 @@ func chainCases() []chainCase { | |||
| 114 | 114 | m.Focus(1) | |
| 115 | 115 | m.AddWindow(2) | |
| 116 | 116 | m.Focus(0) | |
| 117 | - | }, []Action{ActionFocusWorkspaceDown}, []Action{ActionFocusWorkspaceDown}, | |
| 117 | + | }, []Action{ActionFocusWorkspaceNext}, []Action{ActionFocusWorkspaceNext}, | |
| 118 | 118 | func(c *Core) motion { return c.cur().mon.switchView.motion }}, | |
| 119 | 119 | {"rect", func(c *Core) { | |
| 120 | 120 | m := c.cur().mon | |
| @@ -114,7 +114,7 @@ func chainCases() []chainCase { | |||||
| 114 | m.Focus(1) | 114 | m.Focus(1) | ||
| 115 | m.AddWindow(2) | 115 | m.AddWindow(2) | ||
| 116 | m.Focus(0) | 116 | m.Focus(0) | ||
| 117 | - | }, []Action{ActionFocusWorkspaceDown}, []Action{ActionFocusWorkspaceDown}, | 117 | + | }, []Action{ActionFocusWorkspaceNext}, []Action{ActionFocusWorkspaceNext}, |
| 118 | func(c *Core) motion { return c.cur().mon.switchView.motion }}, | 118 | func(c *Core) motion { return c.cur().mon.switchView.motion }}, | ||
| 119 | {"rect", func(c *Core) { | 119 | {"rect", func(c *Core) { | ||
| 120 | m := c.cur().mon | 120 | m := c.cur().mon | ||
M internal/core/transition_unmap_internal_test.go +1 -1
| @@ -339,7 +339,7 @@ func TestUnmapLeavingDroppedByInterruptions(t *testing.T) { | |||
| 339 | 339 | }) | |
| 340 | 340 | t.Run("workspace switch", func(t *testing.T) { | |
| 341 | 341 | c, ic, sc := leaving(t) | |
| 342 | - | act(c, ic, ActionFocusWorkspaceDown) | |
| 342 | + | act(c, ic, ActionFocusWorkspaceNext) | |
| 343 | 343 | gone(t, c, sc, indicatorScene(t, c)) | |
| 344 | 344 | }) | |
| 345 | 345 | } | |
| @@ -339,7 +339,7 @@ func TestUnmapLeavingDroppedByInterruptions(t *testing.T) { | |||||
| 339 | }) | 339 | }) | ||
| 340 | t.Run("workspace switch", func(t *testing.T) { | 340 | t.Run("workspace switch", func(t *testing.T) { | ||
| 341 | c, ic, sc := leaving(t) | 341 | c, ic, sc := leaving(t) | ||
| 342 | - | act(c, ic, ActionFocusWorkspaceDown) | 342 | + | act(c, ic, ActionFocusWorkspaceNext) |
| 343 | gone(t, c, sc, indicatorScene(t, c)) | 343 | gone(t, c, sc, indicatorScene(t, c)) | ||
| 344 | }) | 344 | }) | ||
| 345 | } | 345 | } | ||
M internal/core/window_actions_test.go +8 -8
| @@ -172,25 +172,25 @@ func TestMoveWorkspace(t *testing.T) { | |||
| 172 | 172 | m.FocusNumber(3) | |
| 173 | 173 | m.AddWindow(3) | |
| 174 | 174 | // [1:{1}] [2:{2}] [3:{3}] [4:{}] | |
| 175 | - | m.Apply(ActionMoveWorkspaceUp) | |
| 175 | + | m.Apply(ActionMoveWorkspacePrev) | |
| 176 | 176 | if !reflect.DeepEqual(windows(m), [][]WindowID{{1}, {3}, {2}, {}}) || m.Active != 1 { | |
| 177 | 177 | t.Fatal(windows(m), m.Active) | |
| 178 | 178 | } | |
| 179 | - | m.Apply(ActionMoveWorkspaceUp) | |
| 180 | - | m.Apply(ActionMoveWorkspaceUp) | |
| 179 | + | m.Apply(ActionMoveWorkspacePrev) | |
| 180 | + | m.Apply(ActionMoveWorkspacePrev) | |
| 181 | 181 | if !reflect.DeepEqual(windows(m), [][]WindowID{{3}, {1}, {2}, {}}) || m.Active != 0 { | |
| 182 | 182 | t.Fatal(windows(m), m.Active) | |
| 183 | 183 | } | |
| 184 | - | m.Apply(ActionMoveWorkspaceDown) | |
| 185 | - | m.Apply(ActionMoveWorkspaceDown) | |
| 184 | + | m.Apply(ActionMoveWorkspaceNext) | |
| 185 | + | m.Apply(ActionMoveWorkspaceNext) | |
| 186 | 186 | // Never past the trailing empty workspace. | |
| 187 | - | m.Apply(ActionMoveWorkspaceDown) | |
| 187 | + | m.Apply(ActionMoveWorkspaceNext) | |
| 188 | 188 | if !reflect.DeepEqual(windows(m), [][]WindowID{{1}, {2}, {3}, {}}) || m.Active != 2 { | |
| 189 | 189 | t.Fatal(windows(m), m.Active) | |
| 190 | 190 | } | |
| 191 | 191 | // The trailing empty workspace does not move. | |
| 192 | 192 | m.FocusNumber(4) | |
| 193 | - | m.Apply(ActionMoveWorkspaceUp) | |
| 193 | + | m.Apply(ActionMoveWorkspacePrev) | |
| 194 | 194 | if !reflect.DeepEqual(windows(m), [][]WindowID{{1}, {2}, {3}, {}}) || m.Active != 3 { | |
| 195 | 195 | t.Fatal(windows(m), m.Active) | |
| 196 | 196 | } | |
| @@ -202,7 +202,7 @@ func TestMoveWorkspaceHidden(t *testing.T) { | |||
| 202 | 202 | m.FocusNumber(2) | |
| 203 | 203 | m.AddWindow(2) | |
| 204 | 204 | m.ToggleNamed("dev") | |
| 205 | - | m.Apply(ActionMoveWorkspaceUp) | |
| 205 | + | m.Apply(ActionMoveWorkspacePrev) | |
| 206 | 206 | if !reflect.DeepEqual(windows(m), [][]WindowID{{1}, {2}, {}}) { | |
| 207 | 207 | t.Fatal(windows(m)) | |
| 208 | 208 | } | |
| @@ -172,25 +172,25 @@ func TestMoveWorkspace(t *testing.T) { | |||||
| 172 | m.FocusNumber(3) | 172 | m.FocusNumber(3) | ||
| 173 | m.AddWindow(3) | 173 | m.AddWindow(3) | ||
| 174 | // [1:{1}] [2:{2}] [3:{3}] [4:{}] | 174 | // [1:{1}] [2:{2}] [3:{3}] [4:{}] | ||
| 175 | - | m.Apply(ActionMoveWorkspaceUp) | 175 | + | m.Apply(ActionMoveWorkspacePrev) |
| 176 | if !reflect.DeepEqual(windows(m), [][]WindowID{{1}, {3}, {2}, {}}) || m.Active != 1 { | 176 | if !reflect.DeepEqual(windows(m), [][]WindowID{{1}, {3}, {2}, {}}) || m.Active != 1 { | ||
| 177 | t.Fatal(windows(m), m.Active) | 177 | t.Fatal(windows(m), m.Active) | ||
| 178 | } | 178 | } | ||
| 179 | - | m.Apply(ActionMoveWorkspaceUp) | 179 | + | m.Apply(ActionMoveWorkspacePrev) |
| 180 | - | m.Apply(ActionMoveWorkspaceUp) | 180 | + | m.Apply(ActionMoveWorkspacePrev) |
| 181 | if !reflect.DeepEqual(windows(m), [][]WindowID{{3}, {1}, {2}, {}}) || m.Active != 0 { | 181 | if !reflect.DeepEqual(windows(m), [][]WindowID{{3}, {1}, {2}, {}}) || m.Active != 0 { | ||
| 182 | t.Fatal(windows(m), m.Active) | 182 | t.Fatal(windows(m), m.Active) | ||
| 183 | } | 183 | } | ||
| 184 | - | m.Apply(ActionMoveWorkspaceDown) | 184 | + | m.Apply(ActionMoveWorkspaceNext) |
| 185 | - | m.Apply(ActionMoveWorkspaceDown) | 185 | + | m.Apply(ActionMoveWorkspaceNext) |
| 186 | // Never past the trailing empty workspace. | 186 | // Never past the trailing empty workspace. | ||
| 187 | - | m.Apply(ActionMoveWorkspaceDown) | 187 | + | m.Apply(ActionMoveWorkspaceNext) |
| 188 | if !reflect.DeepEqual(windows(m), [][]WindowID{{1}, {2}, {3}, {}}) || m.Active != 2 { | 188 | if !reflect.DeepEqual(windows(m), [][]WindowID{{1}, {2}, {3}, {}}) || m.Active != 2 { | ||
| 189 | t.Fatal(windows(m), m.Active) | 189 | t.Fatal(windows(m), m.Active) | ||
| 190 | } | 190 | } | ||
| 191 | // The trailing empty workspace does not move. | 191 | // The trailing empty workspace does not move. | ||
| 192 | m.FocusNumber(4) | 192 | m.FocusNumber(4) | ||
| 193 | - | m.Apply(ActionMoveWorkspaceUp) | 193 | + | m.Apply(ActionMoveWorkspacePrev) |
| 194 | if !reflect.DeepEqual(windows(m), [][]WindowID{{1}, {2}, {3}, {}}) || m.Active != 3 { | 194 | if !reflect.DeepEqual(windows(m), [][]WindowID{{1}, {2}, {3}, {}}) || m.Active != 3 { | ||
| 195 | t.Fatal(windows(m), m.Active) | 195 | t.Fatal(windows(m), m.Active) | ||
| 196 | } | 196 | } | ||
| @@ -202,7 +202,7 @@ func TestMoveWorkspaceHidden(t *testing.T) { | |||||
| 202 | m.FocusNumber(2) | 202 | m.FocusNumber(2) | ||
| 203 | m.AddWindow(2) | 203 | m.AddWindow(2) | ||
| 204 | m.ToggleNamed("dev") | 204 | m.ToggleNamed("dev") | ||
| 205 | - | m.Apply(ActionMoveWorkspaceUp) | 205 | + | m.Apply(ActionMoveWorkspacePrev) |
| 206 | if !reflect.DeepEqual(windows(m), [][]WindowID{{1}, {2}, {}}) { | 206 | if !reflect.DeepEqual(windows(m), [][]WindowID{{1}, {2}, {}}) { | ||
| 207 | t.Fatal(windows(m)) | 207 | t.Fatal(windows(m)) | ||
| 208 | } | 208 | } | ||