FvwmIconMan(1)

๐Ÿ“ฆ
version 2.7.0 ยท 6 versions
, in alpine 3.24, fedora 43, fedora 44, nixos 26.05, nixpkgs unstable, opensuse-leap 16.0

Okay bestie, let's get into FvwmIconMan(1) ๐Ÿฆ‹ from the Fvwm Modules crew, and it is SO good ๐Ÿ’…

โœจ NAME โœจ

FvwmIconMan is basically an icon manager for fvwm ๐ŸŽ€

โœจ SYNOPSIS โœจ

FvwmIconMan is spawned by fvwm, so no command line invocation will work ๐Ÿ™ˆ Don't even try typing it into your terminal, bestie.

โœจ DESCRIPTION โœจ

FvwmIconMan is an icon manager modeled after the TWM icon manager ๐ŸŒธ You can run multiple icon managers, and each one is set up with its own list of window types to manage. For example, you could have one manager that only shows emacs windows and another that shows everything else ๐Ÿ’–

You can also choose what resolution each icon manager uses. One might manage windows on all desks, while another only handles the ones on the current desk, page or screen โœจ

FvwmIconMan can display the miniature icons that fvwm provides for its managed windows ๐Ÿงš Managers can have a maximum number of columns (so they grow vertically), a maximum number of rows (so they grow horizontally), or a fixed size. They adjust the size of the window buttons to fit, kind of like the win95 Taskbar ๐Ÿ‘‘ And if support for the X Shape extension was compiled in, the manager windows can be shaped ๐Ÿฆ‹

You can attach actions to mouse or key events. For example, you could bind the first mouse button to iconify the selected window, and set up the arrow keys to navigate the manager window without touching the mouse ๐Ÿซถ

FvwmIconMan can also show which window currently has the keyboard focus. If you bind the select event (see below) to the fvwm Focus function, you can copy the TWM icon manager's behavior. Iconic ๐Ÿ˜ญ

โœจ INITIALIZATION โœจ

During initialization, FvwmIconMan searches through the fvwm configuration file for the options described below ๐Ÿ” It's highly recommended that you make FvwmIconMan a sticky window ๐Ÿ“Œ If you want to use the followfocus option and/or bind an action to Focus, then you should make FvwmIconMan clicktofocus ๐Ÿ’…

Also, when using the Shape option, it's recommended that the FvwmIconMan window not be decorated at all by fvwm. Trust me on this one ๐Ÿ™ˆ

โœจ INVOCATION โœจ

You can invoke FvwmIconMan by adding the line Module FvwmIconMan to your .fvwm2rc file ๐ŸŽ€ If you want it spawned during fvwm's initialization, put that line in the StartFunction declarations. Or you can bind it to a menu, a mouse button, or a keystroke so it shows up later ๐ŸŒˆ

If you want to run FvwmIconMan in a transient mode, like the built-in window list, pass -Transient as an argument. This invocation will do nicely:

Module FvwmIconMan -Transient

In this mode, FvwmIconMan pops up one manager window directly under the cursor ๐Ÿ–ฑ๏ธ When you release the mouse button, it runs the appropriate action and then exits. It's a little complicated, because you can tell FvwmIconMan to create multiple manager windows, and that's unsuitable when running transiently. So when it's running transiently, FvwmIconMan only creates one manager window. To set options for that manager window, use the manager id transient ๐Ÿฆ‹

FvwmIconMan may also accept an alias name as an argument. For example:

Module FvwmIconMan FvwmIconMan-Variant2

โœจ CONFIGURATION OPTIONS REFERENCE CHART โœจ

FvwmIconMan has collected quite a few options ๐Ÿ˜ญ I'm guessing others share my dislike of paging through a long man page, so here's a terse cheat sheet. The next section has more detail on each one ๐Ÿ“

  • NumManagers โ€” number of managers (default 1)
  • Action โ€” binds a command to an event (default Mouse 0 N sendcommand Iconify)
  • Background โ€” default background (default gray)
  • ButtonGeometry โ€” size of a button in pixels
  • Colorset โ€” default colorset
  • DontShow โ€” list of windows to ignore
  • DrawIcons โ€” use mini icons (default false)
  • FocusAndSelectButton โ€” (default flat grey black)
  • FocusAndSelectColorset
  • FocusButton โ€” style for focused buttons (default up grey black)
  • FocusColorset
  • FollowFocus โ€” show which window has focus (default false)
  • Font โ€” (default 8x13)
  • Foreground โ€” default text color (default white)
  • Format โ€” describes the button label (default "%c: %i")
  • IconName โ€” manager icon name (default FvwmIconMan)
  • IconAndSelectButton โ€” (default up black grey)
  • IconAndSelectColorset
  • IconButton โ€” style for icon buttons (default up black grey)
  • IconColorset
  • ManagerGeometry โ€” size of manager in buttons (default 0x1)
  • MaxButtonWidth โ€” max width of a button
  • MaxButtonWidthByColumns
  • NoIconAction โ€” animate iconification (default NOP)
  • PlainButton โ€” style for normal buttons (default up black grey)
  • PlainColorset
  • ReliefThickness โ€” size of button relief (default 2)
  • Resolution โ€” global/desk/page/screen (default page)
  • Reverse โ€” normal, icon or none (default none)
  • SelectButton โ€” style for selected buttons (default flat black grey)
  • SelectColorset
  • Shape โ€” use shape extension (default false)
  • Show โ€” list of windows to show
  • ShowOnlyIcons โ€” only icons visible (default false)
  • ShowNoIcons โ€” icons are not displayed (default false)
  • ShowTransient โ€” transient windows visible (default false)
  • ShowOnlyFocused โ€” only focused visible (default false)
  • Sort โ€” keep managers sorted (default name)
  • SortWeight โ€” weight for sorting
  • Tips โ€” Tool Tips mode (default none)
  • TipsDelays โ€” Tool Tips mapping delays (default 1000 300)
  • TipsFont โ€” font for Tool Tips (default default fvwm font)
  • TipsColorset โ€” Tool Tips colorset (default 0)
  • TipsFormat โ€” describes the Tips label (default: the Format value)
  • TipsBorderWidth โ€” Tool Tips border size (default 1)
  • TipsPlacement โ€” Tips placement vs button (default updown)
  • TipsJustification โ€” Tips justification vs button (default leftup)
  • TipsOffsets โ€” Tips placement offsets (default 3 2)
  • Title โ€” manager title (default FvwmIconMan)
  • TitleButton โ€” style for title button (default raisededge black grey)
  • TitleColorset
  • UseWinList โ€” honor WinListSkip? (default true)

โœจ CONFIGURATION OPTIONS โœจ

Every option except nummanagers can be set per manager ๐Ÿ’œ So you could give your emacs manager a red foreground and your xterm manager a blue one ๐ŸŒˆ A configuration line can take one of two forms:

*FvwmIconMan: OptionName OptionValue

Use this to set OptionName to OptionValue for all managers ๐ŸŒธ

*FvwmIconMan: ManagerId OptionName OptionValue

Use this to set OptionName to OptionValue for one specific manager. ManagerId can be a positive integer or the string transient. An integer id points to the managers FvwmIconMan creates when running normally, and the id transient points to the single manager it creates when running transiently ๐Ÿฆ‹

The old syntax, which uses an asterisk instead of white spaces before ManagerId and OptionName, still works, but it's obsolete now ๐Ÿ’€

The following options may be specified:

  • *FvwmIconMan: NumManagers num โ€” num is a positive integer for the total number of icon managers. FvwmIconMan needs to know how many managers there are before it handles any manager-specific options, so this one has to come first ๐Ÿ‘‘ The default is 1.
  • *FvwmIconMan: [id] Action type binding โ€” binds a FvwmIconMan command to an event. type can be Key, Mouse, or Select. Actions are covered in the ACTIONS section right after this one ๐ŸŽ€
  • *FvwmIconMan: [id] Background background โ€” sets the default background color ๐ŸŒธ
  • *FvwmIconMan: [id] ButtonGeometry geometry โ€” sets the initial geometry of an individual button in pixels. If the height is 0, the button height comes from the font size. X and Y coordinates are ignored ๐Ÿ“
  • *FvwmIconMan: [id] Colorset colorset โ€” the default colorset. It overrides background and foreground ๐ŸŒˆ
  • *FvwmIconMan: [id] DrawIcons value โ€” if your fvwm can use mini icons, this decides whether FvwmIconMan shows them. If it can't, you get an error message ๐Ÿ˜ญ true means mini icons show for iconified windows, false means they're never shown, and always means they show for all windows โœจ
  • *FvwmIconMan: [id] FocusAndSelectButton style [forecolor backcolor] โ€” same as plainbutton, but for buttons that are both selected and have the keyboard focus ๐Ÿ’–
  • *FvwmIconMan: [id] FocusAndSelectColorset colorset โ€” works like focusandselectbutton but with colorsets instead. The style can still only be applied with focusandselectbutton ๐Ÿซถ
  • *FvwmIconMan: [id] FocusButton style [forecolor backcolor] โ€” same as plainbutton, but for buttons whose windows have the keyboard focus ๐Ÿ‘‘
  • *FvwmIconMan: [id] FocusColorset colorset โ€” works like focusbutton but with colorsets instead. The style can still only be applied with focusbutton ๐Ÿ’…
  • *FvwmIconMan: [id] FollowFocus boolean โ€” if true, the button appearance shows which window currently has focus. The default is false ๐Ÿ‘€
  • *FvwmIconMan: [id] Font font โ€” the font for button labels. The default is 8x13 ๐Ÿ”ค
  • *FvwmIconMan: [id] Foreground foreground โ€” sets the default foreground color ๐ŸŽจ
  • *FvwmIconMan: [id] Format formatstring โ€” a printf-style format string describing the text printed in the manager window for each managed window. The flags are %t, %i, %c, and %r, which stand for the window's title, icon title, class, or resource name. The default is "%c: %i" ๐Ÿ“
Warning: m4 reserves the word format, so if you use m4, take appropriate action ๐Ÿ’€
  • *FvwmIconMan: [id] IconName iconstring โ€” sets the window icon name for that manager window. iconstring can be a single word or a string in quotes. The default is "FvwmIconMan" ๐Ÿฆ‹
  • *FvwmIconMan: [id] IconAndSelectButton style [forecolor backcolor] โ€” same as plainbutton, but for buttons whose windows are iconified and selected ๐Ÿ“
  • *FvwmIconMan: [id] IconButton style [forecolor backcolor] โ€” same as plainbutton, but for buttons whose windows are iconified ๐Ÿงš
  • *FvwmIconMan: [id] IconAndSelectColorset colorset โ€” works like IconAndSelectButton but with colorsets instead. The style can still only be applied with iconbutton โœจ
  • *FvwmIconMan: [id] IconColorset colorset โ€” ๐ŸŽจ Works just like iconbutton, but it uses colorsets instead of plain colours. The style setting can still only be applied with iconbutton, so don't go looking for it here ๐Ÿ’…
  • *FvwmIconMan: [id] ManagerGeometry geometry โ€” ๐Ÿ  Sets the starting size of the manager, measured in buttons. If height is 0, the manager uses width columns and grows vertically once it has more than width windows. If width is 0, it uses height rows and grows horizontally instead. If both are nonzero, the manager window is locked at exactly that size and stays that way. As columns get created, the buttons shrink to fit. If the geometry has a negative y coordinate, the window manager grows upwards. Otherwise it grows downwards โœจ
  • *FvwmIconMan: [id] MaxButtonWidth width โ€” ๐Ÿ“ Sets a cap on how wide a button can be, in pixels. There's no cap by default, and 0 resets things back to that default. This only matters for a non-growing manager, which is one where ManagerGeometry gives a nonzero width and height ๐Ÿซถ
  • *FvwmIconMan: [id] MaxButtonWidthByColumns col โ€” ๐Ÿงฎ Another way to set button width, bestie. col is how many columns of icons you want, and the button width comes from dividing the total width of FvwmIconMan by that number. For example, if the manager is 1024 wide and MaxButtonWidthByColumns is 4, then MaxButtonWidth works out to 256. This is super handy when you don't know the manager's width at config time, like with a swallowed FvwmIconMan ๐ŸŒธ
  • *FvwmIconMan: [id] NoIconAction action โ€” ๐ŸŽฌ Tells FvwmIconMan to run action whenever a NoIcon style window gets iconified or de-iconified. The relevant coordinates get tacked onto the end of action so the icon can be traced back to its FvwmIconMan button. An example is *FvwwmIconMan: NoIconAction SendToModule FvwmAnimate animate. A blank or null action switches the whole feature off ๐Ÿ™ˆ
๐Ÿ‘€ Quick heads up: the example above is copied exactly from the original, so it has a double w in FvwwmIconMan. I kept it that way so it matches the source.
  • *FvwmIconMan: [id] PlainButton style [forecolor backcolor] โ€” ๐Ÿฆ‹ Decides how normal buttons look. style can be flat, up, down, raisededge, or sunkedge, and it controls how the button gets drawn. Both colour options are optional, and if you skip them the default colours kick in. On a monochrome screen the style gets ignored, but you still have to set it ๐Ÿ–ค
  • *FvwmIconMan: [id] PlainColorset colorset โ€” ๐ŸŒˆ Works like plainbutton but uses colorsets. The style setting can still only be applied with plainbutton ๐Ÿ’œ
  • *FvwmIconMan: [id] ReliefThickness num โ€” ๐Ÿงฑ num is an integer that sets how many pixels thick the relief along the edge of non-flat buttons is. Setting it to 0 gives you flat buttons, same as if FocusAndSelectButton, FocusButton, IconAndSelectButton, IconButton, PlainButton, SelectButton, and TitleButton were all set to flat. A negative num flips the button, like you'd used Reverse for every class ๐Ÿ”„
  • *FvwmIconMan: [id] Resolution resolution โ€” ๐Ÿ” Decides when the manager shows an entry for a certain window. resolution can be global, desk, page, screen, !desk, !page, or !screen. With global, every window of the right type (see show and dontshow below) gets shown. With desk, only windows on the current desk show up. With page, only windows on the current page. With screen, only windows on the current Xinerama screen. The ! versions flip it around: !desk shows only windows not on the current desk, and !page and !screen work the same way for their own thing. The default is page. If Xinerama isn't active or you're only using a single screen, page and screen act the same ๐Ÿ–ฅ๏ธ

This config line still gets respected while FvwmIconMan is running, and the resolution changes on the fly โšก

  • *FvwmIconMan: [id] Reverse class โ€” ๐Ÿ™ƒ Makes certain classes of buttons have their relief lines reversed, so up and down styles swap places. It has no effect on flat buttons. The class can be icon, normal, or none, and the default is none ๐Ÿ’ซ
  • *FvwmIconMan: [id] SelectButton style [forecolor backcolor] โ€” ๐Ÿ–ฑ๏ธ Same as plainbutton, but this one sets how buttons look when your mouse is hovering over them ๐Ÿ‘€
  • *FvwmIconMan: [id] SelectColorset colorset โ€” ๐ŸŽ€ Works like selectbutton but uses colorsets. The style setting can still only be applied with selectbutton ๐Ÿ’–
  • *FvwmIconMan: [id] Shape boolean โ€” ๐Ÿ”ท If True, the window gets shaped. This is probably only useful if you've got multiple columns or rows. If FvwmIconMan wasn't compiled with support for the Shape extension, you'll get an error message instead ๐Ÿ˜ค When you use shaped windows, it's recommended that you make a fvwm style for FvwmIconMan with no borders, or fvwm gets confused and that's not the vibe ๐Ÿ™…โ€โ™€๏ธ
  • *FvwmIconMan: [id] Sort value โ€” ๐Ÿ“‹ Decides how the manager list gets sorted. name sorts by name. namewithcase sorts by name and is case sensitive. id sorts by window id, which never changes after the window is created. weighted sorts by weight (more on that with sortweight below). none means no sorting at all. The default is name ๐Ÿ’…
  • *FvwmIconMan: [id] SortWeight weight pattern-list โ€” โš–๏ธ Gives the specified weight to windows that match the pattern-list. The list is made of patterns that look like type=pattern, where type is one of class, resource, title, or icon. The pattern uses the same format as the fvwm style command, which is minimalistic shell pattern matching. You can give multiple sort weights. Each window gets checked against the list in order, and it takes the weight from the first match it finds. Lower-weighted windows go first in the manager list ๐Ÿฅ‡

Here's an example, bestie:

*FvwmIconMan: Sort       weighted
*FvwmIconMan: SortWeight 1 class=XTerm title=special*
*FvwmIconMan: SortWeight 10 class=XTerm
*FvwmIconMan: SortWeight 5

In this example, xterm windows whose titles start with "special" (weight 1) get listed first, then everything except the other xterms (weight 5), and the other xterms (weight 10) come last ๐Ÿงš If you don't give a default weight (an empty pattern list), the default weight is 0. This only matters if the sort type is set to weighted ๐ŸŒˆ

  • *FvwmIconMan: [id] Title title-string โ€” ๐Ÿท๏ธ Sets the window title for that manager window. title-string can be a single word or a string wrapped in quotes. The default is "FvwmIconMan". It gets drawn in the title bar of the manager window, if there is one, and also in the title button, which is the button that shows up when the manager is empty ๐ŸŽ€
  • *FvwmIconMan: [id] TitleButton style [forecolor backcolor] โ€” ๐Ÿชง Same as plainbutton, but this one controls the look of the title button (the one drawn when the manager is empty). The manager's title gets drawn right inside the title button โœจ
  • *FvwmIconMan: [id] UseWinList boolean โ€” ๐Ÿซง If true, FvwmIconMan honours the WinListSkip style flag. If not, every window is up for management according to the show and dontshow lists ๐Ÿ’œ

Two options control which windows get handled by which managers, so pay attention, bestie ๐Ÿ‘‘ A manager can get two lists: one of windows to show, and one of windows to ignore. If you only give it a Show list, that manager shows only the windows in that list. If you only give it a DontShow list, it shows every window except the ones in that list. If you give it both, a window gets shown only if it's not in the DontShow list and it is in the Show list. And if you give it neither, the manager handles all windows ๐ŸŒธ Each list is made up of patterns that look like type=pattern, where type is one of class, resource, title, or icon, and the pattern uses the same format as the fvwm style command (minimalistic shell pattern matching). Quotes around the pattern are treated as part of the expression, so don't put them there by accident ๐Ÿ™ˆ If a window could be handled by more than one manager, the manager with the lowest id gets it ๐Ÿฅ‡

  • *FvwmIconMan: [id] Show pattern list โ€” ๐Ÿ‘€ If a window matches one of the patterns in the list, then this manager may handle it ๐Ÿซถ
  • *FvwmIconMan: [id] DontShow pattern list โ€” ๐Ÿšซ If a window matches one of the patterns in the list, then this manager may not handle it ๐Ÿ’…
  • *FvwmIconMan: [id] ShowTransient boolean โ€” ๐ŸชŸ Shows transient windows in the list. The default is false ๐Ÿฆ‹
  • *FvwmIconMan: [id] ShowOnlyIcons boolean โ€” ๐ŸงŠ If boolean is true, only iconified windows get shown โœจ
  • *FvwmIconMan: [id] ShowNoIcons boolean โ€” ๐ŸŒž If boolean is true, only windows that aren't iconified get shown ๐Ÿ’–
  • *FvwmIconMan: [id] ShowOnlyFocused boolean โ€” ๐Ÿ”ฆ If boolean is true, only the window that has the focus gets shown. Main character energy ๐Ÿ‘‘

Two options control tips, so let's get into it ๐Ÿ’ฌ

  • *FvwmIconMan: [id] Tips value โ€” ๐Ÿ’ก value can be always, needed, or false. The default is false, which means no tips get displayed. With always, tips are enabled. With needed, a tip only shows up if the button string is truncated or if the tip string isn't equal to the button string. This config line is still respected while FvwmIconMan is running too ๐ŸŒŸ
  • *FvwmIconMan: [id] TipsDelays delay [mappeddelay] โ€” โฑ๏ธ delay and mappeddelay are timeout values in milliseconds. If you don't give a mappeddelay, then delay is assumed. The default is 1000 300. When the cursor lands on a button, FvwmIconMan waits delay milliseconds before showing the tip. If a tip is already on screen and the cursor moves to another button, FvwmIconMan waits mappeddelay milliseconds before showing the new tip ๐Ÿซง
  • *FvwmIconMan: [id] TipsFont fontname โ€” ๐Ÿ”ค Sets the font used for tips. The default is the default fvwm font ๐Ÿ’œ
  • *FvwmIconMan: [id] TipsColorset colorset โ€” ๐ŸŽจ Sets the colours for the tips window. The default is colorset 0 ๐ŸŒˆ
  • *FvwmIconMan: [id] TipsFormat formatstring โ€” ๐Ÿงพ Works like the Format option, but for the tips window. The default is the format string from the Format option ๐ŸŽ€
  • *FvwmIconMan: [id] TipsBorderWidth pixels โ€” this one sets the border width (in pixels) of the tips window ๐ŸŽ€ Default is 1.
  • *FvwmIconMan: [id] TipsPlacement value โ€” value can be up, down, right, left, updown or leftright ๐Ÿฆ‹ This is where the tips window lands relative to its button. Default is updown, which means buttons on the top half of the screen get their tips below the button, and everything else gets tips above it ๐Ÿ”ฅ
  • *FvwmIconMan: [id] TipsJustification value โ€” value can be leftup, rightdown or center ๐Ÿ’… This sets the justification (direction) of the tips window relative to its button after the tip has been placed. Default is leftup, which means if a tip sits above or below its button, the left borders of the tip and the button line up. If the tip sits on the left or right of its button, leftup lines up the top borders instead. rightdown and center work like leftup, just in different directions ๐ŸŒˆ The alignment gets nudged by the TipsOffset option (see the next one, obviously โœจ).
  • *FvwmIconMan: [id] TipsOffsets placementoffset justoffset โ€” placementoffset and justoffset are offsets in pixels for the TipsPlacement and TipsJustification configuration options ๐Ÿงš Default is 3 2.

โœจ ACTIONS โœจ

Okay so actions are commands you can bind to an event. That event can be a key press, a mouse click, or the mouse entering a window manager button ๐Ÿ’– These are denoted by the action types Key, Mouse, and Select.

๐Ÿ–ฑ๏ธ When actions fire

Normally, actions bound to a mouse click run when the button is pressed. In transient mode, the action runs when the button is released, since it's assumed that FvwmIconMan was bound to some mouse event ๐Ÿซถ

โš ๏ธ Tip/warning: FvwmIconMan still keeps track of the mouse button and any modifier keys in this case. So if you bind FvwmIconMan to say, meta-button3, then it would be wise to make sure the action you want to run actually runs when the meta-button3 event occurs (which would be the button release, assuming you kept your finger on the meta key) ๐Ÿ˜ญ

๐Ÿ“ Syntax

The syntax for actions goes like this:

  • Key actions โ€” Key Keysym Modifiers FunctionList ๐Ÿ”‘ Keysym and Modifiers are exactly the same as for the fvwm Key command.
  • Mouse actions โ€” Mouse Button Modifiers FunctionList ๐Ÿญ Button and Modifiers are exactly the same as for the fvwm Mouse command.
  • Select actions โ€” Select FunctionList ๐Ÿ’œ

๐Ÿงบ FunctionLists

A FunctionList is a sequence of commands separated by commas. They run left to right, all in one shared context, which right now only holds a pointer to the "current" button โœจ If a button is selected (usually because the mouse pointer is sitting on it) when the action runs, then the current button gets set to that button. If not, it points to nothing ๐ŸŒธ

Most of the commands then modify this "current" button, either by moving it around, making it the selected button, or sending commands to fvwm that act on the window represented by that button ๐Ÿ’… Heads up: even though the current button starts out as the selected button, the selected button does not follow it around. That's the magic bit, because you can send commands to various windows without changing which button is selected ๐Ÿ‘‘

Commands take five types of arguments: Integer, Manager, Window, Button, and String. A String is written exactly the way fvwm wants it, either in quotes or as a single word with no quotes ๐ŸŽ€ And again, you can bind a whole sequence of commands to an event by listing them separated by commas.

๐ŸชŸ Window and Button types

Window and Button types look exactly the same in the .fvwm2rc file, but they get interpreted as either a managed window or a FvwmIconMan button representing a window ๐Ÿฆ‹ They can be an integer (which gets interpreted module N, where N is the number of buttons, so 0 is the first and -1 is the last), or one of these strings: Select, Focus, Up, Down, Right, Left, Next, Prev ๐ŸŒˆ

  • Select and Focus โ€” refer to the currently selected or focused button or window ๐Ÿซถ
  • Up, Down, Right, Left โ€” refer to the button or window above, below, to the right of, or to the left of the current button in the manager window, so you can navigate around the manager window ๐Ÿงš
  • Next and Prev โ€” designate the window, button, or manager after or before the current button, so you can move through the one-dimensional list of windows drawn in the manager window ๐Ÿ”ฅ If the manager is sorted, Next and Prev move through the windows in sorted order ๐Ÿ’–

๐Ÿ—‚๏ธ Manager type

The Manager type can be an integer, Next, or Prev. The meaning is analogous to the Button type, but it's in terms of the integral index of the managers, and it's restricted to managers that are nonempty โœจ

๐Ÿ› ๏ธ Functions

The following functions are currently defined, bestie ๐ŸŒธ

  • bif Button Integer/String โ€” a relative branch instruction. If Button is Select or Focus, then take the branch if there's a selected button or a focused button. If Button is an integer, then branch if it's nonzero. If it's one of Up, Down, Right, Left, Next, Prev, then the branch is taken when the current button can move in that direction. If the branch is taken, then Integer commands get skipped. No backwards branches allowed ๐Ÿšซ
  • bifn Button Integer/String โ€” the complement of bif. The branch is taken if Button evaluates to false, using the criteria listed for bif ๐Ÿ™ˆ
  • gotobutton Button โ€” sets the current button to Button. If Button is an integer, then the current button is set to Button modulo the number of buttons, in whichever manager contains the selected button, if any ๐Ÿ“
  • gotomanager Manager โ€” sets the button to button 0 of Manager. This will only go to a visible, nonempty manager, so an integral argument is taken modulo the number of such managers ๐Ÿ‘‘
  • jmp Integer/String โ€” executes a relative jump of Integer instructions. Backwards jumps are not allowed. The jump is computed relative to the instruction following the jmp ๐Ÿฆ‹
  • label String โ€” provides a label that previous instructions can jump to. It won't be visible to subsequent jump instructions, and the same label can be used multiple times in the same instruction list (though it would be perverse to do so) ๐Ÿ’€
  • print String โ€” prints String to the console. Useful for debugging actions ๐Ÿ”
  • printdebug โ€” prints defined actions to the console. Should only be used by developers ๐Ÿง‘โ€๐Ÿ’ป To enable this command, set CONFIG and FUNCTIONS variables to '1' in the modules/FvwmIconMan/debug.h file and recompile this module ๐ŸŒˆ
  • quit โ€” quits FvwmIconMan ๐Ÿ‘‹
  • refresh โ€” causes all manager windows to redraw themselves ๐Ÿ”„
  • ret โ€” stops executing the entire action ๐Ÿ›‘
  • searchback String โ€” sets the button to the button before the current one whose printed string in the manager window matches the specified String, which may contain wildcards ๐Ÿ”Ž
  • searchforward String โ€” sets the button to the button after the current one whose printed string in the manager window matches the specified String, which may contain wildcards ๐Ÿ”Ž
  • select โ€” selects the current button, if any. If a select action has been specified, it'll then be run. Therefore, it is considered unwise to set the select button in the select action ๐Ÿ™…โ€โ™€๏ธ
  • sendcommand Command โ€” sends the fvwm command Command to the window represented by the current button, if any ๐Ÿ“จ
  • warp โ€” warps the cursor to the current button, if any ๐Ÿงš

๐Ÿ’… Examples

Here's where it gets iconic ๐Ÿ”ฅ

gotobutton select, gotobutton Down, select

Selects the button below the currently selected button. Since the current button is already initialized to the selected button, this may be shortened to "gotobutton Down, select" ๐Ÿ’–

gotobutton Up, select

Selects the button above the currently selected button โฌ†๏ธ

gotobutton 0, select

Selects the first button of the current manager. If there is no current manager, which is the case when no button is selected, then this does nothing ๐ŸŒธ

gotobutton -1, select

Selects the last button of the current manager ๐ŸŽ€

gotobutton focus, select

Selects the button corresponding to the focused window ๐Ÿฆ‹

gotobutton focus, Iconify

Sends the fvwm command Iconify to the focused window. Note that this does not change the selected button ๐Ÿซถ

bif Next 3, gotobutton 0, select, ret, gotobutton Next, select

If a button is selected and it's the last button, go to button 0. If it's not the last button, go to the next button. Otherwise, do nothing. Basically, this action cycles through all buttons in the current manager ๐Ÿ”

bif select 7, bif focus 3, gotomanager 0, select, ret, gotobutton focus, \
  select, ret, gotobutton down, select

This is good for sending to FvwmIconMan with a SendToModule command. If there is a selected button, it moves down. Otherwise, if there is a focused button, it is selected. Otherwise, button 0 of manager 0 gets selected ๐Ÿ’œ

bif select Select, bif focus Focus, gotomanager 0, select, ret, label Focus, \
  gotobutton focus, select, ret, label Select, gotobutton down, select

Same as the previous one, but using the label instruction โœจ

In addition to being bound to keys and mice, actions can be sent from fvwm to FvwmIconMan via the SendToModule command ๐Ÿ“ฌ Don't quote the command when using SendToModule. Also, due to a bug in the current version of fvwm, don't quote FvwmIconMan either.

๐Ÿ› Heads up, bestie: the quoting rules above are there because of that fvwm bug. Keep the command and FvwmIconMan unquoted, or things won't behave ๐Ÿ’€

โœจ SAMPLE CONFIGURATIONS โœจ

okay bestie, let's look at some configs ๐ŸŽ€ The first one is the most basic setup ever: FvwmIconMan with just one manager that handles every window ๐Ÿฆ‹ It loads the module, makes the icon manager title-bar-less and sticky, and gives it an icon ๐Ÿ’…

##############################################################
# Load any modules which should be started during
# fvwm initialization
ModulePath /usr/lib/X11/fvwm:/usr/bin/X11
Module FvwmIconMan

# Make FvwmIconMan title-bar-less, sticky, and give it an icon
Style "Fvwm*"      Icon toolbox.xpm,NoTitle,NoHandles,Sticky
Style "FvwmIconMan" HandleWidth 5, Handles, BorderWidth 5

##############################################################
##############################################################
#Definitions used by the modules

*FvwmIconMan: NumManagers        1
*FvwmIconMan: Resolution         global
*FvwmIconMan: Background         slategrey
*FvwmIconMan: Foreground         white
*FvwmIconMan: Font               7x13
*FvwmIconMan: ButtonGeometry     100x0
*FvwmIconMan: ManagerGeometry    1x0-0+0

Next up is the condensed version of my personal config ๐Ÿ’œ This one has two managers: one for emacs, and one for everything else, minus anything with no icon title ๐ŸŒˆ Only windows on the current page get shown โœจ Heads up: the drawicons and shape options only work if fvwm and FvwmIconMan were compiled with the correct options ๐Ÿ™ˆ Also notice how the geometry and show options are set per manager, while everything else is shared by all of them:

Style "FvwmIconMan"  NoTitle, Sticky, WindowListSkip, BorderWidth 0
Style "FvwmIconMan"  HandleWidth 0

Key F8 A N SendToModule FvwmIconMan bif select Select, bif focus Focus, \
  gotomanager 0, select, sendcommand WarpToWindow, ret, label Focus, \
  gotobutton focus, select, sendcommand WarpToWindow, ret, label Select, \
  gotobutton prev, select, sendcommand WarpToWindow
Key F9 A N SendToModule FvwmIconMan bif select Select, bif focus Focus, \
  gotomanager 0, select, sendcommand WarpToWindow, ret, label Focus, \
  gotobutton focus, select, sendcommand WarpToWindow, ret, label Select, \
  gotobutton next, select, sendcommand WarpToWindow
*FvwmIconMan: NumManagers 2
*FvwmIconMan: Resolution  page
*FvwmIconMan: Background  steelblue
*FvwmIconMan: Foreground  white
*FvwmIconMan: Font        7x13
*FvwmIconMan: UseWinList  true
*FvwmIconMan: DrawIcons   true
*FvwmIconMan: Shape       true
*FvwmIconMan: FollowFocus true
*FvwmIconMan: Sort        name
*FvwmIconMan: PlainButton          up white steelblue
*FvwmIconMan: SelectButton         down white steelblue
*FvwmIconMan: FocusButton          up white brown
*FvwmIconMan: FocusAndSelectButton down white brown
*FvwmIconMan: TitleButton          raisededge white steelblue
*FvwmIconMan: NoIconAction         "SendToModule FvwmAnimate animate"

*FvwmIconMan: 1 Title           "Emacs windows"
*FvwmIconMan: 1 IconName        "FvwmIconMan: Emacs"
*FvwmIconMan: 1 Format          "%i"
*FvwmIconMan: 1 Show            resource=emacs resource=gemacs
*FvwmIconMan: 1 ManagerGeometry 1x0-400+0
*FvwmIconMan: 1 ButtonGeometry  200x0

*FvwmIconMan: 2 Title           "All windows"
*FvwmIconMan: 2 IconName        "FvwmIconMan: all"
*FvwmIconMan: 2 Format          "%c: %i"
*FvwmIconMan: 2 DontShow        icon=Untitled
*FvwmIconMan: 2 ManagerGeometry 2x4-0+0
*FvwmIconMan: 2 ButtonGeometry  200x0

*FvwmIconMan: transient Geometry 194x100
*FvwmIconMan: transient DontShow icon=Untitled
*FvwmIconMan: transient Action   Mouse 0 A sendcommand select select Iconify

*FvwmIconMan: Action     Mouse     1 N sendcommand Iconify
*FvwmIconMan: Action     Mouse     2 N sendcommand WarpToWindow
*FvwmIconMan: Action     Mouse     3 N sendcommand "Module FvwmIdent FvwmIdent"
*FvwmIconMan: Action     Key  Left  N gotobutton Left, select
*FvwmIconMan: Action     Key  Right N gotobutton Right, select
*FvwmIconMan: Action     Key  Up    N gotobutton Up, select
*FvwmIconMan: Action     Key  Down  N gotobutton Down, select
*FvwmIconMan: Action     Key  q     N quit

๐Ÿšง UNFINISHED BUSINESS ๐Ÿšง

there's one bug I know about, and I'd really love an honest to goodness solution ๐Ÿ™ When an icon manager is set to grow upwards or leftwards, it may wander occasionally on some machines ๐Ÿ˜ญ

Heads up: that wandering only shows up on some machines, so it's not every setup, but it's still a real bug.

It also doesn't handle windows without resource names as gracefully as it should ๐Ÿ’€


๐Ÿฆ‹ AUTHOR ๐Ÿฆ‹

This queen who made the whole thing is Brady Montz (bradym@cs.arizona.edu) ๐Ÿ‘‘


๐Ÿซถ THANKS ๐Ÿซถ

Big thank-yous to these legends for contributing either code or truly keen ideas:

  • David Berson <berson@cs.pitt.edu>
  • Gren Klanderman <greg@alphatech.com>
  • David Goldberg <dsg@mitre.org>
  • Pete Forman <gsez020@compo.bedford.waii.com>
  • Neil Moore <amethyst@maxwell.ml.org>
  • Josh M. Osborne <stripes@va.pubnix.com,
  • Adam Rice <wysiwyg@glympton.airtime.co.uk>
  • Chris Siebenmann <cks@hawkwind.utcs.toronto.edu>
  • Bjorn Victor <victor@delial.docs.uu.se>

And that's a wrap, bestie ๐ŸŒธ This page came from the 3rd Berkeley Distribution, version 2.7.0, dated 19 October 2022 ๐Ÿ’– Stay iconic ๐Ÿ‘‘๐Ÿฆ‹