There a several ways to control olvwm

Property manager

Snapshot of Property manager

A built-in property manager allows the user to modify some basic Xresources (ie in ~/.Xdefaults)


There are a wide range of Xresources (Xdefaults) for doing all the usual X11 things.

Olvwm recognises and uses Xresources of the form:

OpenWindows resources are recognised by XView programs in general. olwm is for backwards compatability with olwm (which was what olvwm was based on).

Here are some of the more useful Xresources:

OpenWindows.DragRightDistance: 20
Amount you have to move the cursor to bring up a sub-menu 20 is pretty quick, default is 100

OpenWindows.SetInput: followmouse
Determines how windows get the keyboard focus.
Click in the window (default) to type
Move the mouse into the window to type

OpenWindows.KeyboardCommands: Full
Allows you to use the "mouseless model" for OpenLook

olvwm.InputFocusColor: cyan
Highlights the active window with a distinct colored window-border. Default is "none".

olwm.MinimalDecor: xclock xbiff
Removes window-bar from nominated windows.

olvwm.VirtualSticky: xclock xbiff
Makes nominated windows sticky by default.

olvwm.FreeIconSlots: true
Automatically re-arrange icons when an icon space becomes free.

Menu file

The menu file used is the first valid menu file found, in the following heirarchy:

The format of the olvwm menu file is quite simple. The format consists mostly of single-line menu-entries, consisting of a label and a command.

Here is a decription by way of example:

# Comments begin with a '#' like this line
# Each menu (including submenus) begins with an optional TITLE
"My Workspace"	TITLE

# Most entries are simply a label, followed by a command.
# The label must be in quotes if it contains spaces.
# The command is executed using sh(1), unless it is
# a keyword.
xterm		exec xterm
"another xterm"	exec xterm -name "My Example"

# The keyword SEPARATOR can be used to space out menu items

# The default item in a (sub)menu is usually the 1st one,
# unless the keyword DEFAULT appears before the command.
"Let's Surf!"	DEFAULT exec netscape

# Commands can be extended by ending the line with a '\'
# Combined with the fact that sh(1) is used to execute
# the command, you can get pretty fancy...
"Today's Weather"	Netscape=/usr/local/netscape ;\
			XKEYSYMDB=$Netscape/XKeysymDB; export XKEYSYMDB;\
			XNLSPATH=$Netscape/nls; export XNLSPATH ;\
			URL= ;\
			netscape -remote "OpenURL($URL)" || \
			exec $Netscape/netscape $URL

"Color Xterm"		N=`expr $$ % 5` ;\
			case $N in \
				0) BG=moccasin ;;\
				1) BG=lightskyblue1 ;;\
				2) BG=mistyrose ;;\
				3) BG=lavender ;;\
				4) BG=beige ;;\
			esac ;\
			exec xterm -bg $BG

# Sub-menus can be included in the same file using the MENU/END
# keywords as follows (the indentation is just for readability)
"Window Ops"	MENU
	"Stick/Unstick"		STICK_UNSTICK_SELN
	"Back"			BACK_SELN
	"Quit"			QUIT_SELN
"Window Ops"	END PIN

# The optional PIN keyword make the sub-menu pinnable.
# Pinnable menus automatically take on the same title as their label
# Unless, of course, you specify a title explicitly
"Meditation"	MENU
	"Coffee"	TITLE
	flame		exec xlock -remote -nolock -mode flame
	hop		exec xlock -remote -nolock -mode hop
"Meditation"	END PIN

# Sub menus can also be put into seperate files, using either
# the MENU or INCLUDE keywords
# Notice how environment variables can be used to specify sub-menus.
"CD-Player"	MENU	$OPENWINHOME/lib/openwin-menu-cdplay

# There is a subtle difference between MENU and INCLUDE
# A missing or faulty MENU menu is a fatal error.
# A missing or faulty INCLUDE menu is simply greyed-out.
"User Menu"	INCLUDE	my-non-existant-menu

# The keyword DIRMENU can be used to automatically build
# a menu out of a directory of executables
"OpenLook Tool Suite"	DIRMENU /usr/openwin/bin

# The keyword WINMENU automatically builds a menu out of all
# the existing windows, and lets you "warp" to a selected
# window. If the window is on another virtual screen, the view
# is moved to that screen, and the window is opened if iconised.
"Windows"		WINMENU

# The usual text-label can also be replaced by an icon.
# gif's, xbm's, xpm's, and Sun icon files are all valid
<$HOME/html/olvwm_talk/hot_tiny.xpm>	MENU	$HOME/games

"Exit"		EXIT

A sub-menu in a file follows exactly the same syntax as the outlined above.
# The COLUMNS keyword set the menu into a given number of columns
# This goes into the command part of a menu entry.
dummy	COLUMNS 3
</home/ghansper/html/olvwm_talk/cd_prev.button> exec cdplay
</home/ghansper/html/olvwm_talk/cd_pause.button> exec cdpause
</home/ghansper/html/olvwm_talk/cd_play.button> DEFAULT exec cdplay
</home/ghansper/html/olvwm_talk/cd_stop.button> exec cdstop
</home/ghansper/html/olvwm_talk/cd_next.button> exec cdplay
</home/ghansper/html/olvwm_talk/cd_eject.button> exec cdeject

There are a number of other keywords which can be used as commands, including:


olvwmrc file

There is yet another file which is used in the configuration of the olvwm, and this is the file ~/.olvwmrc

This file is used to do more esoteric things, like keyboard mapping and modifying the effects of the WINMENU.

Many of the functions which can be configured from the olvwmrc file are specific to particular windows.

Here are some practical examples. Note that these examples only are not intended to be comprehensive. Please refer to the olvwmrc(5) man page for more information.

# Comments begin with a '#' like this line

# We can define where our windows will appear
# (This is not handled by xtoolplaces)
Screen 2 {
	Netscape, xload
# This will put all new Netscape windows in screen 2
# - not just when started from the ~/.openwin-init

# We can (re)define any key-combination like this:
F1 + Alt {
        Warp: "pine"
	Open: "pine"
	Raise: "pine"
# which will, take us straight to the pine window 
# when we press Alt-F1.

# Some programs require the use of all the F-keys.
# We don't want to surrender our special keys for the sake
# of a single application keys, so we can
# selectively disable olvwm-specific F-keys on a per-window
# basis:
NoVirtualFKey:	x3270
# This seems to duplicate the effect of the Xresource:
#	olwm.Client.x3270.MenuAccelerators: false

# The effect of selecting a window in the WINMENU is normally
# to "warp" the view to that window. However, this can also
# be redefined
	"xconsole" {
		SetSize: full