Fluxbox apps file

Tuesday, December 11, 2007

As you probably know I use Fluxbox as my default Window Manager. The reason I use Fluxbox is because there are almost endless customizations you can do with it. Also it is very lightweight running at about 6.5M. Yes I know not quite as light as some of the others that run in like 1 or 2M but it is also much more powerful then those.

For example....

Fluxbox uses a ~.fluxbox/apps file which is insanely useful. It allows a user to define the specific attributes for a window. It allows you to choose were on the screen the window will appear when the program start. How big the window will be, and others
To use the apps file you need to know a little bit about the syntax.

Example entry for the apps file

[app] (role=buddy_list)
[hidden] {yes}
[position] {1024 0}

this entry will use all windows with the role of "buddy_list" and make them hidden from focus (cannot alt + tab to them) and hidden from the menubar, also it will set he position of the window (for me) on the upper right hand side of the screen. I use a display that is 1280x800 resolution so you may need to change the specific numbers for you.

other useful attributes you can use for the apps file are

[Workspace] {NUMBER} //which workspace to place window
[Dimensions] {Width Height} //size of the window
[Layer] {later number} //number of the according layer you want
2 - AboveDock
4 - Dock
6 - Top
8 - Normal
10 - Bottom
12 - Desktop
[Shaded] {yes or no} //whether you want the window to start shaded
[Tab] {yes or no} //whether you want this to be able to be alt + tabbed
[IconHidden] {yes or no} //hide from the menu bar
[FocusHidden] {yes or no} //hide from focus
[Hidden] {yes or no} //both IconHidden and FocusHidden
[Deco] {NONE|NORMAL|TOOL|TINY|BORDER|TAB} //Decoration attribute
NORMAL - standard decorations
NONE - no decorations
BORDER - like NONE except keep the X window border
TINY - titlebar with an iconify button
TOOL - titlebar only
TAB - like NONE except show external tabs only (in SVN version only)
[Sticky] {yes or no} //to be on all workspaces or not
[Close] {yes or no} //save attributes of the window on exit

Using these you can make a window do almost anything you want on start. the entry above uses the command role=buddy_list which controls the window "Buddy List" for pidgin you need to either use one of the following in that entry
name //the name of the window
class //the class of the window
title //the title of the window
role //the role of the window

To find out each of these for the window you are trying to edit, you need to use a program called "xprop" it will tell you all you need to know about the window of choice.

Also you can use the [group] flag to specify attributes of multiple windows. If you are going to use the [group] flag make sure you do NOT use the [end] flag at the end of each app you specify example of using the [group] flag

# a group that only looks for windows on the current workspace
[group] (workspace)
[app] (firefox-bin) (title=.*Mozilla Firefox.*)
[app] (opera)
[Dimensions] {800 600}
[Position] (UPPERRIGHT) {0 0}

I got the previous entry from http://fluxbox-wiki.org because I do not use Grouping and I wanted an example for you to have.

Well thats it for the apps file, however this is not the end of my Fluxbox parade I will return to talk about the keys,init,and menu.

Thank you