GWM Manual Contents


Quick Reference


This chapter lists all WOOL objects (functions, variables, and active values) grouped by topics.

WOOL constructs

Object Description

; WOOL comment
(), nilthe nil value
t the logical ``true'' value
', quote prevents evaluation of argument
eval evaluates a WOOL expression
load loads and executes a WOOL file
set variable assignment
:, setq variable assignment
=, equal tests equality of any two objects
eq tests strict equality of any two objects
execute-string executes (parses and evaluates) a WOOL string
hack raw access to GWM internal structures
type type of a WOOL object
with local variable declaration
with-eval local variable declaration (with evaluation)

Flow control

Object Description

progn, {} sequence of instructions
if conditional test
cond conditional test
for iterates through a list of values
mapfor constructs a list by iterating through a list of values
while while loop
tag non-local goto: label
exit non-local goto: branching
end terminates GWM
error-occurred traps errors occuring in expressions
trigger-error triggers a wool error
process-events recursively process all pending events

I/O

Object Description

?, print prints WOOL objects
bell rings the keyboard bell

Atoms

Object Description

atom makes an atom from a string
boundp tests if an atom has already been defined
unbind Un-defines an atom

Namespaces

Object Description

namespace-make creates a namespace
namespace-add adds a state to a namespace
namespace-remove removes a state from a namespace
defname declares a name in a namespace
namespace sets current state of a namespace
namespace-of returns namespace of a symbol
namespace-size number of states in the namespace

Functions

Object Description

defun, de defines a WOOL function evaluating its arguments
defunq, df defines a WOOL function quoting its arguments
lambda defines an unnamed WOOL function evaluating its arguments
lambdaq defines an unnamed WOOL function quoting its arguments

Lists

Object Description

#, nth accesses or modifies an element of a list or a property list
##, replace-nth physically modifies an element of a list or a property list
( ... ) list notation
+ appends lists
length length (number of elements) of a list
list creates a list
member position of element in a list
sublist extracts a sub-list out of a list
delete-nth physically removes an element of a list
copy copies a list
list-make makes a list of a given size
sort sorts a list in place

Strings

Object Description

" ... " string notation
+ concatenates strings
< tests for strict lexicographic inferiority
> tests for strict lexicographic superiority
compare compare two strings for lexicographic order
member position of substring in string
atoi ASCII string to Integer conversion
itoa Integer to ASCII string conversion
atom makes an atom from a string
length length (number of characters) of a string
match general regular expression matching and extracting package

Logical functions

Object Description

() the nil value
t the logical ``true'' value
and logical AND of expressions
not logical negation
or logical OR of expressions

Numbers

Object Description

+ adds numbers
*, %, / arithmetic binary operators
- arithmetic difference or sign inversion
< tests for strict numerical inferiority
> tests for strict numerical superiority
compare compare two numbers
bitwise-and bitwise and operator
bitwise-or bitwise or operator
bitwise-xor bitwise exclusive-or operator
atoi ASCII string to Integer conversion
itoa Integer to ASCII string conversion

Graphical primitives

Object Description

active-label-make makes a label (text in a given font)
bordertile pixmap to tile the border of a wob
foreground color of the foreground
dimensions position and dimensions of a WOOL object
height height of a WOOL object
width width of a WOOL object
label-horizontal-margin margins around labels
label-vertical-margin margins around labels
active-label-make makes a graphic string object refreshing itself on exposures
label-make makes a pixmap by drawing a string
pixmap-make builds a pixmap (color image)
pixmap-load builds a pixmap from an XPM file description
tile background pixmap for creating a wob
wob-tile, wob-pixmap gets/sets the graphic displayed in a wob
draw-line draws a line in a pixmap
draw-rectangle draws a (filled) rectangle in a pixmap
draw-text draws a string of characters in a pixmap

System interface

Object Description

! executes a shell command
getenv gets the value of a shell variable
restart restarts GWM
elapsed-time gets time used by GWM in milliseconds
hostname name of the machine on which GWM is running

Events

Object Description

any matches any modifier or button
button makes a button event
buttonpress makes a buttonpress event
buttonrelease makes a buttonrelease event
current-event-code code of the last event
current-event-modifier modifier of the last event
current-event-from-grab tests if last event was generated by a grab
current-event-window-coords relative position of the last event
current-event-x absolute position of the last event
current-event-y absolute position of the last event
current-event-relative-x relative position of the last event
current-event-relative-y relative position of the last event
current-event-time time in milliseconds of the last event
current-user-event name of the last user event
double-button makes a double-click button event
double-buttonpress makes a double-click buttonpress event
double-click-delay maximum time between double clicks
enter-window event generated when the pointer crosses the border of a wob
leave-window event generated when the pointer crosses the border of a wob
enter-window-not-from-grab event generated when the pointer actually crosses the border of a wob
leave-window-not-from-grab event generated when the pointer actually crosses the border of a wob
focus-in event received when input focus changes on the client window
focus-out event received when input focus changes on the client window
geometry-change event generated when window changes size
key makes a key event
keypress makes a keypress event
keyrelease makes a keyrelease event
key-make makes a key symbol out of a descriptive name
last-key last key pressed
name-change event generated when window changes its name
property-change event generated when a client window changes a property
window-icon-pixmap-change pixmap to be used in icon has changed
send-user-event sends a GWM ``user'' event to another wob
user-event event internal to GWM
set-grabs grabs events occurring in the window
unset-grabs removes grabs set by set-grabs
map-notify event sent when window is mapped
visibilty... events sent when window visibility changes

Keyboard modifiers

Object Description

alone specifies that no modifier key is used
any matches any modifier or button
together combines keyboard modifiers
with-shift shift key was depressed for the event
with-control control key was depressed for the event
with-alt alt key was depressed for the event
with-lock lock key was depressed for the event
with-modifier-N modifier N key was depressed for the event
with-button-N button N was depressed for the event

Access to X11 primitives

Object Description

screen-type returns visual type of screen
current-mouse-position queries server for current mouse position
wob-at-coords wob containing coordinates
display-name name of the X server
get-x-property gets an X property on the client window
set-x-property sets an X property on a client window
grab-server grabs the server
ungrab-server releases grab on the X server
replayable-event makes a replayable event from a normal event
allow-event-processing un-freezes the server after catching a replayable event
ungrab-server-and-replay-event releases grab on the X server and replay grabbing event
refresh refreshes the screen
resource-get searches GWM database for a resource
resource-put puts a resource in GWM database
set-focus sets input focus on a window
set-colormap-focus sets the window whose colormap is installed
set-subwindow-colormap-focus installs the colormap of a subwindow
set-key-binding redefines keyboard for all applications
keycode-to-keysym converts a key code to its symbolic code
keysym-to-keycode converts a symbolic code to a key code
set-screen-saver sets screen-saver parameters
set-acceleration sets mouse speed
set-threshold sets mouse acceleration threshold
process-exposes treats all pending expose events
warp-pointer warps the mouse pointer to a location
xid-to-wob translates X ID to wob object

Global variables controlling GWM behavior

Object Description

describe-screen user function called to describe a screen
describe-window user function called to decorate a new window
freeze-server stops processing other clients during grabs
grab-keyboard-also grab-server grabs also keyboard events
confine-grabs cursor stays confined in grabbing wobs
confine-windows forces windows to stay on-screen
reenter-on-opening process events on the queue just before mapping a new window
invert-cursors inverts the bitmaps used for making cursors
move-grid-style style of grid for move
resize-grid-style style of grid for resize
resize-style style of interactive resize
check-input-focus-flag follows input hint for setting focus
print-errors-flag controls printing of error messages
print-level controls printing depth of lists
gwm-quiet silent startup
never-warp-pointer disables any pointer warping
border-on-shaped keep borders on shaped windows
map-on-raise should the window be mapped when raised?

Colors

Object Description

color-make allocates a pixel color by name
color-make-rgb creates a color from RGB values
color-free de-allocates a pixel
color-components gives RGB color decomposition of a pixel
background color of the background
borderpixel color of the border of a wob
foreground color of the foreground
grid-color color to draw (xor) the grids with
invert-color color to invert (xor) the wobs with

Wobs

Object Description

borderpixel color of the border of a wob
bordertile pixmap to tile the border of a wob
borderwidth width in pixels of the border of a wob
dimensions position and size of a WOOL object
height height of a WOOL object
width width of a WOOL object
menu menu associated with wob
root-window the root window
wob-property WOOL property associated to a wob
wob-status state of the window
wob-x x position in pixels
wob-y y position in pixels
wob-height wob height in pixels
wob-width wob width in pixels
wob current wob
wob-at-coords wob containing screen coordinates
wob-borderpixel color of border
wob-borderwidth width of the border of a wob
wob-fsm gets or sets the fsm associated with current wob
wob-invert quick and dirty inversion of a wob
wob-menu gets or sets the menu associated with current wob
menu-wob returns wob associated with menu
wob-parent finds the parent of a wob
wob-tile graphic displayed in a wob
wob-pixmap graphic displayed in a wob
wob-cursor cursor displayed when pointer is in a wob

Plugs

Object Description

plug-make makes a plug
wob-tile graphic displayed in a wob
wob-pixmap graphic displayed in a wob

Bars

Object Description

bar-make makes a bar descriptor
bar-min-width minimum transversal width of a bar
bar-max-width maximum transversal width of a bar
background color of the background
plug-separator inter-plug space within bars
wob-background (solid) background color of wob
wob-tile graphic displayed in a wob
wob-pixmap graphic displayed in a wob

Menus

Object Description

direction direction of menus
bar-separator number of pixels between consecutive bars in menus
horizontal direction of menus
vertical direction of menus
menu menu associated with wob
menu-make makes a menu
place-menu maps a menu as a normal client window
pop-menu pops a menu
unpop-menu makes a popped menu disappear
wob-menu gets or sets the menu associated with current wob

Windows

Object Description

describe-window user function called to decorate a new window
circulate-windows-down circulates mapped windows
circulate-windows-up circulates mapped windows
grid-color color to draw (xor) the grids with
iconify-window iconifies or de-iconifies a window
inner-borderwidth borderwidth of the client window
kill-window destroys a client
list-of-windows returns the list of all windows
lower-window lowers a window below another window
map-window maps window
move-window moves window
raise-window raises a window on top of other windows
re-decorate-window re-decorates the client window by GWM
resize-window resizes the window
root-window the root window
unmap-window unmaps (make invisible) a window
window current window id
window-make makes a template to decorate a window with
window-property WOOL property associated to a wob
window-size client window size specified in resize increments

Window characteristics

Object Description

window-client-borderwidth inner window borderwidth in pixels
window-client-class client application class
window-client-name client application name
window-client-height inner window height in pixels
window-client-width inner window width in pixels
window-client-x inner window x in pixels
window-client-y inner window x in pixels
window-group manages groups of windows
window-icon icon associated to window
window-window window associated to icon
window-icon-name name of the icon
window-icon-pixmap pixmap to be used in an icon
window-icon-window window to be used as icon
window-is-mapped tells if window is visible
window-is-shaped tells if window has non-rectangular shape
window-is-transient-for tells if window is transient
window-machine-name name of host on which the client is running
window-name name of the window
window-size client window size specified in resize increments
window-starts-iconic state in which window must first appear
window-status state of the window
window-user-set-position tells if user explicitly specifed the position
window-user-set-size tells if user explicitly specifed the size
window-program-set-position tells if program explicitly specifed the position
window-program-set-size tells if program explicitly specifed the size
window-was-on-screen tells if window was already on screen
window-width window width in pixels
window-height window height in pixels
window-x x position of upper-left corner of window in root
window-y y position of upper-left corner of window in root
grabs events grabbed on the whole window

Screen

Object Description

screen current screen
describe-screen user function called to describe a screen
root-window the root window
screen-depth screen depth
screen-height screen height
screen-width screen width
list-of-screens list of managed screens
screen-count number of screens attached to the display
tile background pixmap
wob-background (solid) background color of wob

Context

Object Description

context-save context management
context-restore context management
with local variable declarations
with-eval local variable declarations

Cursors

Object Description

cursor shape of the cursor in a wob
cursor-make makes a cursor with a bitmap and a mask
invert-cursors inverts the bitmaps used for making a cursor

Communication with other X11 clients

Object Description

GWM_EXECUTE Sending commands to GWM
cut-buffer contents of cut buffer 0
rotate-cut-buffers rotate server cut buffers
get-x-property gets an X property on the client
set-x-property sets an X property on a client window
delete-read-properties flags to delete X properties after reading them
resource-get searches GWM database for a resource
resource-put puts a resource in GWM database
get-x-default gets a server default
get-wm-command gets the WM_COMMAND property
send-key-to-window sends key event to a client
send-keycode-to-window sends key event to a client
send-current-event re-sends X event to the client of a window
window-wm-state gets the WM_STATE property of a window
window-wm-state-icon declares user icon for WM_STATE
window-wm-state-update updates WM_STATE property for windows with user icon
set-icon-sizes sets desired icon sizes
delete-window asks client to delete one of its windows
window-to-client client window Xid to Gwm wob conversions
client-to-window client window Xid to Gwm wob conversions

Session manager functions

Object Description

save-yourself asks client to update its WM_COMMAND property

Fonts

Object Description

font default font
font-make loads a font

Fsms

Object Description

fsm Finite State Machine of the wob
fsm-make compiles an automaton
on triggers a transition on an event in a state of a fsm
on-eval triggers a transition on an event in a state of a fsm
state-make makes a state of a fsm
wob-fsm gets or sets the fsm associated with current wob

Meter

Object Description

meter-close unmaps the meter
meter-open displays the meter
meter-update writes a string in the meter
meter sets meter attributes
move-meter shows meter during moves
resize-meter shows meter during resizes

Hooks

Object Description

opening WOOL expression evaluated at the creation of a window or icon
closing WOOL expression evaluated at the destruction of a window or icon

Debugging tools

Object Description

trace traces WOOL function calls
trace-level traces WOOL function calls
stack-print-level number of stack frames printed on error
hashinfo statistics on atom storage
meminfo prints memory used
oblist prints all defined objects
window-is-valid tests if window is still valid
wob-is-valid tests if wob is still valid

Christophe Tronche, ch@tronche.com