The default bindings are set such that up and left shrink windows by 10 percantage points in height and width respectively. down and right grow windows.
mode "resize" {
# [...]
bindsym Left resize shrink width 10 px or 10 ppt
bindsym Down resize grow height 10 px or 10 ppt
bindsym Up resize shrink height 10 px or 10 ppt
bindsym Right resize grow width 10 px or 10 ppt
# [...]
}
For example: if the window takes up 25 % of the available width in a container, growing it by 10 ppt will make it take up 35 % (with all other windows shrunken equally). If the window is the left most window in a container it will (and really can) only grow to the right. If the window does not border on the edge of the container (in direction of resizing) it will grow in both directions.
That being said, it is only the default setting. You actually can tell the resize
command to grow and shrink in a specific direction. You just have to use left
or right
instead of width
and up
or down
instead of height
. So you could add something like that to your i3 configuration:
mode "resize" {
# [...]
bindsym Left resize grow left 10 px or 10 ppt
bindsym Shift+Left resize shrink left 10 px or 10 ppt
bindsym Down resize grow down 10 px or 10 ppt
bindsym Shift+Down resize shrink down 10 px or 10 ppt
bindsym Up resize grow up 10 px or 10 ppt
bindsym Shift+Up resize shrink up 10 px or 10 ppt
bindsym Right resize grow right 10 px or 10 ppt
bindsym Shift+Right resize shrink rigth 10 px or 10 ppt
# [...]
}
resize grow left
moves the left border to the left or rather outwards. resize shrink left
moves the left border to the right (!) or rather inwards. (So with resize
the keywords left
, up
, down
and right
really indicate borders with grow
and shrink
indicating direction.)
(You may want to experiment a bit to find bindings that feel natural. While pressing Up to move the top border of a window upwards is quite intuitive, pressing Shift+Up to pull the top border down might not be. Perhaps Shift+Down or separate modes for growing and shrinking would be better.)