[Urwid] GLib MainLoop and some quirks

Andrew Psaltis ampsaltis at gmail.com
Sun May 17 17:41:11 EDT 2009


Ian,

Attached is a diff for main_loop.py that adds a GLibMainLoop class (taken
with hg diff).  I know that it accomplishes simple functionality, but more
complex things (like timeouts) have not been tested yet.  They should work,
though.

Also, I noticed some quirks:

When I attempt to subclass RadioButton, apparently, only the "RadioButton"
part of the class gets stored in the "group" list.  Attempting to use the
RadioButton functionality with the subclass itself in the group list works
fine.  I'm not sure if my subclass should redefine the constructor to
compensate for this, but what I have does work.  I noticed this with
0.9.8.4, but I have not tried otherwise with the trunk of the development
repository.

Also, on the Linux terminal, at least with wicd-curses (which does indeed
have quirks of its own), the prompt does not always end up in the correct
position.  If I move and quit immediately, the prompt likes to place itself
somewhere along the middle of the screen.  Most other times, it does display
the prompt properly at the bottom of the screen as expected.  If it makes a
difference, it uses an integrated version of the attached GLibMainLoop.

~Andrew
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.excess.org/pipermail/urwid/attachments/20090517/b87f8456/attachment.htm 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: mainloop.diff
Type: application/octet-stream
Size: 8416 bytes
Desc: not available
Url : http://lists.excess.org/pipermail/urwid/attachments/20090517/b87f8456/attachment.obj 


More information about the Urwid mailing list