| Home | Trees | Index | Help |
|
|---|
| Module wmii :: Class WMII |
|
object--+ |WMIIBase--+ | WMII
Python interface to WMII
The following 'magic attributes' are available, marked (r) for read-only, (w) for write-only and (rw) for read/write:| Method Summary | |
|---|---|
Creates WMII interface | |
If a ctl attribute, get it from /ctl, otherwise defer to base method | |
If the attribute is one of the /ctl attributes, write it to wmii, otherwise use the parent method | |
pops up the action menu | |
Schedules an action to occur after a given delay. | |
binds a key to an action | |
sets column mode to one of 'default', 'stack', 'max' | |
changes to default column view mode | |
changes to max column view mode | |
changes to stack column view mode | |
Runs the main event loop of this interface | |
If no argument given, toggles between framed and float focus | |
Changes focus in the given direction, 'up', 'down', 'left', 'right' | |
change focus to window below | |
change focus to column to the left | |
transfers focus to the next window in the current view | |
change focus to column to the right | |
change focus to window above | |
retrieves a key from shared data area | |
returns the full pathname of an action name, or None if no valid action exists by that name | |
returns a list of action names | |
returns a WMIIClient object for a given window id | |
switch to the next tag | |
switch to the previous tag | |
switch to viewing the tag 'tagid' | |
Sets up the tags bar | |
Kills the client with the given window id, or the current window if no id given | |
Reloads the key bindings from a file | |
default handler for tag create events | |
default handler for tag destroy events | |
default handler for tag focus events | |
handles a keystroke | |
picks up when user clicks on a tag label | |
display a message on status bar | |
default handler for tag unfocus events | |
handle an event, dispatching to on_EVENTNAME if the handler exists, or onUnknownEvent if it doesn't | |
default handler for unhandled events | |
this gets executed when an unknown key event happens | |
Displays a popup menu offering a set of choices, and returns the result or None if no choice was made | |
display program menu, execute program | |
Saves a value to shared data area | |
Default method for running pywmii. | |
Executes an 'action' script (any executable file in one of the WMII_CONFPATH directories, whigh a purely alphanumeric name | |
Searches for client window(s) matching a given set of parameters, including: | |
Resumes the periodical status bar update, with the existing feed | |
Starts the statusbar updater function | |
Stops the status bar updater | |
Returns the text to display on the status bar | |
Queues up a message to be displayed on the status bar next time it updates. | |
Break out of event loop, by writing a custom terminate event which tells the event loop to break. | |
Deletes a key binding | |
| Inherited from object | |
x.__delattr__('name') <==> del x.name | |
x.__getattribute__('name') <==> x.name | |
x.__hash__() <==> hash(x) | |
T.__new__(S, ...) -> a new object with type S, a subtype of T | |
helper for pickle | |
helper for pickle | |
x.__repr__() <==> repr(x) | |
x.__str__() <==> str(x) | |
| Property Summary | |
|---|---|
clientids: list of ids of current clients | |
clients: Dict of current clients - keys are clientid, values are WMIIClient
instances | |
colrules: list of (tag, percentages) tuples, controlling the sizing of columns
on a per-tag basis | |
keys: Currently grabbed keystrokes | |
nextTag: The 'next' tag (view) in chain | |
prevTag: The 'prev' tag (view) in chain | |
sel: Currently selected window | |
statusfunc: write-only - sets the function which will update the statusbar. | |
tag: Currently visible tag | |
tagrules: list of (regexp, tag) tuples, controlling the tagging of newly created
windows according to their titlebar text | |
tags: Current list of tags (views) | |
| Class Variable Summary | |
|---|---|
type |
clientClass = wmii.WMIIClient |
type |
columnClass = wmii.WMIIColumn |
tuple |
defaultFocusColors = ('#000000', '#ffcc00', '#000000')
|
tuple |
defaultNormColors = ('#ffee44', '#000000', '#000000')
|
type |
p9Class = wmii.P9_wmiir |
type |
viewClass = wmii.WMIIView |
| Method Details |
|---|
__init__(self,
**kw)
Creates WMII interface
|
__getattr__(self,
attr)
If a ctl attribute, get it from /ctl, otherwise defer to base
method
|
__setattr__(self, attr, val)If the attribute is one of the /ctl attributes, write it to wmii, otherwise use the parent method
|
actionmenu(self)pops up the action menu |
after(self, delay, action, *args)Schedules an action to occur after a given delay. Arguments:
|
bindkey(self, key, hdlr, *args)binds a key to an action Arguments:
|
colMode(self, mode)sets column mode to one of 'default', 'stack', 'max' |
colModeDefault(self)changes to default column view mode |
colModeMax(self)changes to max column view mode |
colModeStack(self)changes to stack column view mode |
eventLoop(self)Runs the main event loop of this interface |
float(self, winid=None)If no argument given, toggles between framed and float focus If a window id is given, then toggles that window to/from float mode |
focus(self, direction)Changes focus in the given direction, 'up', 'down', 'left', 'right' |
focusDown(self)change focus to window below |
focusLeft(self)change focus to column to the left |
focusNext(self)transfers focus to the next window in the current view |
focusRight(self)change focus to column to the right |
focusUp(self)change focus to window above |
get(self, key)retrieves a key from shared data area |
getActionPath(self, name)returns the full pathname of an action name, or None if no valid action exists by that name |
getActionsList(self)returns a list of action names |
getClient(self, winid)returns a WMIIClient object for a given window id |
gotoNextTag(self)switch to the next tag |
gotoPrevTag(self)switch to the previous tag |
gotoTag(self, tagid)switch to viewing the tag 'tagid' |
initTagsBar(self)Sets up the tags bar |
kill(self, winid='sel')Kills the client with the given window id, or the current window if no id given |
loadBindings(self, path=None)Reloads the key bindings from a file Arguments:
|
on_CreateTag(self, tag)default handler for tag create events |
on_DestroyTag(self, tag)default handler for tag destroy events |
on_FocusTag(self, tag)default handler for tag focus events |
on_Key(self, key)handles a keystroke |
on_LeftBarClick(self, button, tagid)picks up when user clicks on a tag label |
on_PyWmiiStatus(self, *args)display a message on status bar |
on_UnfocusTag(self, tag)default handler for tag unfocus events |
onEvent(self, name, *args)handle an event, dispatching to on_EVENTNAME if the handler exists, or onUnknownEvent if it doesn't |
onUnknownEvent(self, name, *args)default handler for unhandled events |
onUnknownKey(self, key)this gets executed when an unknown key event happens |
popupMenu(self, choices)Displays a popup menu offering a set of choices, and returns the result or None if no choice was made Arguments:
|
progmenu(self)display program menu, execute program |
put(self, key, value)Saves a value to shared data area |
run(self)Default method for running pywmii. Sets up the status bar, the tag labels, then enters the event loop |
runAction(self, name)Executes an 'action' script (any executable file in one of the WMII_CONFPATH directories, whigh a purely alphanumeric name |
search(self, **kw)Searches for client window(s) matching a given set of parameters, including:
|
statusResume(self, freq=None)Resumes the periodical status bar update, with the existing feed |
statusStart(self, freq=None, colors=None)Starts the statusbar updater function Arguments:
|
statusStop(self)Stops the status bar updater |
statusUpdate(self, wmii)Returns the text to display on the status bar Default method. You can customise this by either:
|
statusWrite(self, msg, delay=5, urgent=False)Queues up a message to be displayed on the status bar next time it updates. Arguments:
|
stop(self)Break out of event loop, by writing a custom terminate event which tells the event loop to break. |
unbindkey(self, key)Deletes a key binding |
| Property Details |
|---|
clientidslist of ids of current clients |
clientsDict of current clients - keys are clientid, values are WMIIClient instances |
colruleslist of (tag, percentages) tuples, controlling the sizing of columns on a per-tag basis |
keysCurrently grabbed keystrokes |
nextTagThe 'next' tag (view) in chain |
prevTagThe 'prev' tag (view) in chain |
selCurrently selected window |
tagCurrently visible tag |
tagruleslist of (regexp, tag) tuples, controlling the tagging of newly created windows according to their titlebar text |
tagsCurrent list of tags (views) |
| Class Variable Details |
|---|
defaultFocusColors
|
defaultNormColors
|
| Home | Trees | Index | Help |
|
|---|
| Generated by Epydoc 2.1 on Tue Jun 12 22:49:30 2007 | http://epydoc.sf.net |