ANN: Urwid 0.9.8 - Console UI Library
ian at excess.org
Mon Mar 26 06:28:38 CEST 2007
Announcing Urwid 0.9.8
Urwid home page:
About this release:
This release improves Urwid's performance by 70% to 450% (reducing
running time by 41% to 82%) for some benchmarks. New base classes
have been introduced for widgets, canvases and list walkers. Some bugs
have been fixed. Python 2.2 or later is now required.
There were three major changes that contributed to the performance
improvement in this release. The Canvas class was rewritten so that
canvases can be combined more efficiently. Canvas objects are now
cached so that most unchanged widgets will not need to re-render
themselves. There is a new C module for some of the heavily used
low-level string functions contributed by Rebecca Breu.
Urwid's raw_display module may now be used with libraries like Twisted
that have their own event loops. Use the new get_input_descriptors()
and get_input_nonblocking() methods instead of get_input() when using an
external event loop.
While I have tried to maintain compatibility with older versions of
Urwid, some of the changes in this release may affect existing code.
Please report any problems you have to the mailing list or the IRC channel.
New in this release:
* Rendering is now significantly faster.
* New Widget base class for all widgets. It includes automatic caching
of rows() and render() methods. It also adds a new __super attribute
for accessing methods in superclasses.
Widgets must now call self._invalidate() to notify the cache when
their content has changed.
To disable caching in a widget set the class variable no_cache to a
list that includes the string "render".
* Canvas classes have been reorganized: Canvas has been renamed to
TextCanvas and Canvas is now the base class for all canvases. New
canvas classes include BlankCanvas, SolidCanvas and CompositeCanvas.
* External event loops may now be used with the raw_display module. The
new methods get_input_descriptors() and get_input_nonblocking()
should be used instead of get_input() to allow input processing
* The Columns, Pile and ListBox widgets now choose their first
selectable child widget as the focus widget by defaut.
* New ListWalker base class for list walker classes.
* New Signals class that will be used to improve the existing event
callbacks. Currently it is used for ListWalker objects to notify
their ListBox when their content has changed.
* SimpleListWalker now behaves as a list and supports all list
operations. This class now detects when changes are made to the list
and notifies the ListBox object. New code should use this class to
wrap lists of widgets before passing them to the ListBox
* New PollingListWalker class is now the default list walker that is
used when passing a simple list to the ListBox constructor. This
class is intended for backwards compatibility only. When this class
is used the ListBox object is unable to cache its render() method.
* The curses_display module can now draw in the lower-right corner of
* All display modules now have start() and stop() methods that may be
used instead of calling run_wrapper().
* The raw_display module now uses an alternate buffer so that the
original screen can be restored on exit. The old behaviour is
available by seting the alternate_buffer parameter of start() or
run_wrapper() to False.
* Many internal string processing functions have been rewritten in C to
improve their performance.
* Compatible with Python >= 2.2. Python 2.1 is no longer supported.
Urwid is a console UI library for Python. It features fluid interface
resizing, UTF-8 support, multiple text layouts, simple attribute markup,
powerful scrolling list boxes and flexible interface design.
Urwid is released under the GNU LGPL.
More information about the Python-announce-list