FVWMREARRANGE(1)
β¨ NAME β¨
Okay bestie, welcome to FVWMREARRANGE(1) β the manual page for FvwmRearrange, which rearranges fvwm windows. π
πΈ SYNOPSIS πΈ
FvwmRearrange [options] [bounding box] [options]
FvwmRearrange is spawned by fvwm, so no command line invocation will work. Like, it is not a βrun me from your shell and expect magicβ situation, okay? π
π¦ DESCRIPTION π¦
This module can be called to tile or cascade windows.
When tiling the module will tile the windows into a grid (table or matrix) inside the bounding box (the current monitorβs working area by default). Tiling is performed so that windows will not overlap. When moving and resizing windows to fit into the grid, windows are resized to their nearest increment size, specified by the windowβs size hints (this is why sometimes space might appear between tiled windows, common with terminals). Use the ResizeHintOverride style on widows with increment size hints to override this behavior (which removes the gaps).
When cascading the module will cascade the windows inside the bounding box from the top left of the bounding box. Windows will be resized to fit the bounding box and layering is performed so that consecutive windows all have their titles visible underneath the previous window.
The behavior of both tiling and cascading can be configured by the options listed below. This can control the size of the bounding box, if windows are resized, and which windows are affected, and so on.
π INVOCATION π
FvwmRearrange is best invoked from a menu, keybinding, or button. There are a number of command line options which can be used to control how windows will be cascaded/tiled, described below. Invoking FvwmRearrange with no options will auto tile (see -auto_tile) windows on the current monitor:
FvwmRearrange
This tiles all windows in the working area of the current monitor into a grid. This size of the grid will be computed using the number of windows trying to make the grid as square as possible. Windows on the top row will be resized to take up any extra space filling the full working area. Adding additional arguments can change the behavior, for example:
FvwmRearrange -tile -swap 10 10 90 90
This invocation will tile windows in a single column with a bounding box which starts at 10 by 10 percent into and down the monitorβs working area and ends at 90 by 90 percent into and down the working area. Another example:
FvwmRearrange -cascade 10 2 80 70
This invocation will cascade windows starting 10 by 2 percent into and down the monitorβs working area. Windows will be resized so their height and width are 75 percent of the bounding box, which ends at 80 by 70 percent of the working area.
FvwmRearrange can also be run multiple times on the same monitor with different bounding boxes. This way you can better control how windows are tiled. Consider the following example:
FvwmRearrange -tile -swap 0 0 35 100
FvwmRearrange 35 0 100 100
The first command will create a single column of windows located on the left 35% of the monitor, and the second will auto tile the windows on the right 65% of the monitor. This way you can control how windows are tiled in different parts of the monitor independent of each other.
If you want to run FvwmRearrange automatically when new windows are added, use FvwmEvent to trigger FvwmRearrange with an add_window event. If using multiple bounding boxes (like the above example), a ManualPlacement Style would allow you to place a window in the portion of the screen you wanted it to be tiled in.
π OPTIONS π
FvwmRearrange is only configured using command line options. These options can come before or after the bounding box, and all start with a -. Below the options are split into categories, TILING OPTIONS, CASCADING OPTIONS, GENERAL OPTIONS, RESIZING OPTIONS, FILTERING OPTIONS, and ORDERING OPTIONS.
π TILING OPTIONS π
Tiling takes the windows inside the bounding box, creates a grid of equal sized cells based on the number of windows, then resizes and moves the windows to fill the cells, starting at the top left. The cells are then filled one row at a time (from left to right) working downward.
Windows may have minimum size or size increment EMWH hints, so there could be gaps between windows or some windows minimum size might be bigger than the cell. The ResizeHintOverride fvwm Style will override this behavior and make windows fit in their cells better.
-auto_tileβ This is the default behavior which tiles all windows into as close to a square grid as possible. There can be up to one more column than row (or one more row than column with-swap), depending on number of windows. If the option-max_n Nis also provided, then the grid will haveNmore columns than rows (orNmore rows than columns if-swapis included). This option implies-fill_startso all space will be used. If-fill_endoption is provided, the free space is used at the end instead.-tileβ This will tile the windows into a single row (or column if with-swap). If-max_n Nis also provided, there will be at mostNcolumns per row (orNrows per column with-sawp) in the resulting grid. If the grid has more cells than the number of windows, then the additional cells at the end will be left open, unless the-fill_startor-fill_endoptions are included.-max_n Nβ This option alters how the grid is computed. When using-auto_tilethis gives the number of more columns than rows (or more rows than columns with-swap). When using-tilethis gives the max number of columns, before a new row is created (or max number of rows with-swap). Default is0.-swapβ Swaps the rows and columns, and swaps the direction the cells are filled, by starting at the top left cell and filling each column downward (from top to bottom) while working to the right. This use to be called horizontal sort (with the default being vertical sort), and the old option-his an alias for-swap, due to this history.-fill_startβ This will use any unused space in the grid by filling the first row (or first column with-swap) left open in the grid. This is done by growing the windows in the row (or column) to fill the unused space. The rest of the windows will then fill up the rest of the grid.-fill_endβ This will use any unused space in the grid by filling the last row (or last column with-swap) left open in the grid.-gap_x N,-gap_y N,-gap Nβ This will set the gap between the cells the windows are placed in.-gap_xsets the size of the horizontal gap,-gap_ysets the size of the vertical gap, and-gapsets both the size of the horizontal and vertical gap to be the same. The valueNis the number of pixels between cells, or the width of the line between cells. Default:0.
π¦ CASCADING OPTIONS π¦
Cascading takes all windows in the bounding box, places the first window in the upper left corer of the bounding box, then stacks the second window just below the first shifted slightly down and to the right, so the previous window can be seen behind it. This process is repeated placing each window slightly down and to the right of the previous window.
By default the windows are resized such that their height and width are 75% of the bounding boxβs height and width. Though as the windows are cascaded, windows will shrunk so they will stay inside the bounding box. The -nostretch and -noresize options will prevent windows from being stretched or resized.
-cascadeβ Cascade windows inside the bounding box.-cascadew argβ Specifies the width of the cascade windows.argis a percentage of the bounding boxβs width, or a pixel value if apis suffixed. Windows are shrunk if the width pushes them outside the bounding box. Default is75.-cascadeh argβ Specifies the height of the cascade windows.argis a percentage of the bounding boxβs height, or a pixel value if apis suffixed. Windows are shrunk if the height pushes them outside the bounding box. Default is75.-inc_equalβ Make the x and y increment equal to the maximum of the two values. This is useful to get the offset to be equal to the size of the border and title bar in both directions. This can be combined with-incx,-incy,-flatx, and-flaty.-incx argβ Specifies an additional horizontal increment which is successively added to cascaded windows.argis a percentage of bounding boxβs width, or a pixel value if apis suffixed. Default is zero.-incy argβ Specifies an additional vertical increment which is successively added to cascaded windows.argis a percentage of bounding boxβs height, or a pixel value if apis suffixed. Default is zero.-flatxβ Inhibits incrementing the horizontal position by a windows border width (and title width if titles are on the right or left). Useful with-incxto better control the horizontal increment.-flatyβ Inhibits incrementing the vertical position by a windows border width (and title width if titles are on the top or bottom). Useful with-incyto better control the vertical increment.
π GENERAL OPTIONS π
-screen nameβ By default the current monitor is used to determine what windows to cascade/tile, and is used as the base bounding box. This will use the monitor specified by the RandR name instead. Ifnameis equal to"g"the global monitor (bounding box containing all monitors is used). Since this may cause windows to span across multiple monitors, the working area is ignored (seeewmhiwa).-noraiseβ Inhibits window raising, leaving the depth ordering intact.-maximizeβ When moving/resizing a window, put them into a maximized state. This makes soMaximizecan be used to restore the previous size and position.-animateβ When only moving windows (-noresizeis used), useAnimateMoveinstead ofMoveto move windows.-ewmhiwaβ When rearranging windows, make the calculation ignore the working area, such asEwmhBaseStruts; by default,FvwmRearrangewill honour the working area. This option may place windows outside of the current monitor.-win_cmd COMMANDβ Runs the fvwmCOMMANDin the context of every window that is rearranged. This can be used to set the state of all affected windows with theCOMMAND"State n"so they can be matched using the"State n"conditional. TheCOMMANDis sent after the window is moved/resized, so any change in windowβs size, adding removing title bars, etc, will not be used in computing the new position/size of the window.
β¨ RESIZING OPTIONS β¨
So like, by default, both tiling and cascading are gonna resize your windows based on whatever options you handed over. These options here? They put a little leash on that behavior. π¦
-noresizeβ literally just says "no." Inhibits window resizing, so your window sizes stay exactly as they are, untouched, iconic. π-nostretchβ stops windows from growing to fit the grid cell (when you're tiling) or the bounding box (when you're cascading). Windows still get shrunk to fit, but they will NOT be expanded, bestie. Nope. This one is a shortcut that implies both-nostretchxand-nostretchy. β¨-nostretchxβ windows don't grow horizontally to fit, but they'll still get shrunk. So they can still get smaller, just never wider. π-nostretchyβ same energy but vertical: windows don't grow vertically to fit, but they'll still get shrunk. π«Ά
π FILTERING OPTIONS π
These ones decide which windows inside the bounding box actually get tiled or cascaded. The vibe check, basically. πΈ
-allβ makes skipped, sticky, and transient windows also get cascaded/tiled (they're ignored by default, rude of them tbh). This is a shortcut for-skiplist,-stickyand-transient.-someβ don't include maximized windows and windows without title bars (super useful when cascading) when cascading/tiling. Shortcut for-no_maximizedand-no_titled. π-skiplistβ makes windows on the windows skip list (peep theWindowListSkipstyle, iykyk) also get affected. π-stickyβ makes sticky windows also get affected. Shortcut for-sticky_pageand-sticky_desk. π©Ή-sticky_pageβ windows that are sticky across pages also get affected.-sticky_deskβ windows that are sticky across desks also get affected.-transientβ transient windows also get affected. β¨-no_maximizedβ don't include windows in the maximized state when cascading/tiling.-no_titledβ don't include windows with title bars when cascading/tiling.-deskβ makes all windows on the desk get cascaded/tiled, instead of only the windows that intersect the bounding box. Going full send on the whole desk. π₯-on_screenβ makes all windows on the monitor get cascaded/tiled, instead of only the ones that intersect the bounding box. Heads up: this has no effect when you use it together with-desk. π
π ORDERING OPTIONS π
Tiling and cascading happen in a particular order, and that order matters. By default it's based off fvwm's WindowList order (which is usually based off the order windows were last focused). These options let you take the wheel. π
-order_nameβ order windows by their name.-order_iconβ order windows by their icon name.-order_classβ order windows by their class.-order_resourceβ order windows by their resource.-order_xyβ order windows by their (x, y) coordinate position. This is a lexicographic ordering: compare x-coordinates first, and if the x-coordinates are equal, then compare the y-coordinates. This ordering matches the ordering of the-swaptiling option. π-order_yxβ order windows by their (x, y) coordinate position too, but lexicographic the other way: compare y-coordinates first, then if the y-coordinates are equal, compare the x-coordinates. This ordering matches the default positing of tiling windows. πΊοΈ-order_hwβ order windows by their height, and if the heights match, compare by width. This can be useful with-cascadeand-noresizeto stack windows based on their size. π-order_whβ order windows by their width, and if the widths match, compare by height. Also useful with-cascadeand-noresizeto stack windows based on their size.-reverseβ flips the window ordering. Backwards. Opposite day. π
π§ BOUNDING BOX π§
Okay so the bounding box is the area where FvwmRearrange both finds and places windows when cascading/tiling. The base bounding box is the working area of the current monitor β or whichever monitor you specified with the -screen name option. But if you passed -ewmhiwa, then the base bounding box ignores the working area entirely and uses the full monitor instead. π
You can drop up to four numbers on the command line to specify a bounding box relative to the base bounding box of the given monitor. These numbers give the position of the corners of the bounding box, in this specific order (default is "0 0 100 100"):
Left Top Right Bottom
These numbers get treated as a percentage of the base bounding box. So like, the bounding box "10 5 85 80" would start 10% across the working area from the left and end 85% across the working area, while starting 5% down the working area from the top and ending 80% down the working area. And if you slap the letter p on the end of any number, then it's read as a pixel value instead of a percentage. β¨
Also super important: specifying zero for any parameter is the same as not specifying it at all β so "0 0 0 0" is literally the same thing as "0 0 100 100". No cap. π€―
π BUGS π
It is probably not a good idea to delete windows while windows are being rearranged. Just... don't, bestie. That's chaos mode. π
π AUTHORS π
- Andrew Veliath β original
FvwmTileandFvwmCascademodules - Dominik Vogt β merged
FvwmTileandFvwmCascadetoFvwmRearrange - Jaimos Skriletz β updated for fvwm3, including adding the
auto_tileoption
And that's the whole page, bestie, we ate that π β¨ This was FVWMREARRANGE(1), dated 2026-07-31 β fvwm3 era, iconic behavior only. Go tile something cute. ππ¦π
π¦ where this page comes from
- ubuntu stonking: fvwm3 1.1.5+ds-2 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms