mirror of
https://github.com/labwc/labwc.git
synced 2026-02-08 10:06:59 -05:00
interactive: allow snapping to corner edges
In addition to <snapping><range>, <snapping><cornerRange> configures the distance from the screen corner to trigger quater window snapping. Also, new values "up-left", "up-right", "down-left" and "down-right" are allowed for <action name="(Toggle)SnapToEdge" direction="[value]"> and <query tiled="[value]">.
This commit is contained in:
parent
b0ff2911b6
commit
2f183cdcb6
14 changed files with 147 additions and 89 deletions
|
|
@ -95,7 +95,8 @@ Actions are used in menus and keyboard/mouse bindings.
|
|||
*<action name="ToggleSnapToEdge" direction="value" />*++
|
||||
*<action name="SnapToEdge" direction="value" />*
|
||||
Resize window to fill half the output in the given direction. Supports
|
||||
directions "left", "up", "right", "down" and "center".
|
||||
directions "left", "up", "right", "down", "up-left", "up-right", "down-left",
|
||||
"down-right" and "center".
|
||||
|
||||
ToggleSnapToEdge additionally toggles the active window between
|
||||
tiled to the given direction and its untiled position.
|
||||
|
|
@ -474,7 +475,7 @@ Actions that execute other actions. Used in keyboard/mouse bindings.
|
|||
The "left" , "right", "left-occupied" and
|
||||
"right-occupied" directions will not wrap.
|
||||
|
||||
*tiled* [up|right|down|left|center|any]
|
||||
*tiled* [up|right|down|left|top-left|top-right|down-left|down-right|center|any]
|
||||
Whether the client is tiled (snapped) along the the
|
||||
indicated screen edge.
|
||||
|
||||
|
|
|
|||
|
|
@ -412,11 +412,13 @@ activated with SnapToEdge actions or, optionally, by dragging windows to the
|
|||
edges of an output. Edge snapping causes a window to occupy half of its output,
|
||||
extending outward from the snapped edge.
|
||||
|
||||
*<snapping><range>*
|
||||
If an interactive move ends with the cursor a maximum distance *range*,
|
||||
(in pixels) from the edge of an output, the move will trigger a
|
||||
SnapToEdge action for that edge. A *range* of 0 disables snapping via
|
||||
interactive moves. Default is 10.
|
||||
*<snapping><range>*++
|
||||
*<snapping><cornerRange>*
|
||||
If an interactive move ends with the cursor within *<range>* pixels of an
|
||||
output edge, the window is snapped to the edge. If it's also within
|
||||
*<cornerRange>* pixels of an output corner, the window is snapped to the
|
||||
corner instead. A *<range>* of 0 disables snapping.
|
||||
Default is 10 for *<range>* and 50 for *<cornerRange>*.
|
||||
|
||||
*<snapping><overlay><enabled>* [yes|no]
|
||||
Show an overlay when snapping to a window to an edge. Default is yes.
|
||||
|
|
|
|||
|
|
@ -155,6 +155,7 @@
|
|||
<snapping>
|
||||
<!-- Set range to 0 to disable window snapping completely -->
|
||||
<range>10</range>
|
||||
<cornerRange>50</cornerRange>
|
||||
<overlay enabled="yes">
|
||||
<delay inner="500" outer="500" />
|
||||
</overlay>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue