Implement focus-follows-mouse max-scroll-amount

This commit is contained in:
Ivan Molodetskikh
2024-07-05 20:12:56 +04:00
parent 120eaa6c56
commit 1da99f4003
6 changed files with 116 additions and 6 deletions
+19 -1
View File
@@ -68,7 +68,7 @@ input {
// disable-power-key-handling
// warp-mouse-to-focus
// focus-follows-mouse
// focus-follows-mouse max-scroll-amount="0%"
// workspace-auto-back-and-forth
}
```
@@ -207,6 +207,24 @@ input {
}
```
<sup>Since: 0.1.8</sup> You can optionally set `max-scroll-amount`.
Then, focus-follows-mouse won't focus a window if it will result in the view scrolling more than the set amount.
The value is a percentage of the working area width.
```
input {
// Allow focus-follows-mouse when it results in scrolling at most 10% of the screen.
focus-follows-mouse max-scroll-amount="10%"
}
```
```
input {
// Allow focus-follows-mouse only when it will not scroll the view.
focus-follows-mouse max-scroll-amount="0%"
}
```
#### `workspace-auto-back-and-forth`
Normally, switching to the same workspace by index twice will do nothing (since you're already on that workspace).