durusmail: quixote-users: Generalizing form/widget API a bit
Generalizing form/widget API a bit
2003-11-25
2003-11-25
2003-11-25
2003-11-25
2003-11-25
2003-11-26
2003-11-26
2003-11-26
2003-11-26
2003-11-26
2003-11-26
2003-11-26
2003-11-26
2003-11-26
2003-11-26
2003-11-26
2003-11-29
2003-11-30
2003-11-26
2003-11-26
2003-11-26
Patch: add html_attrs keyword arg to widget classes
2003-11-30
Patch: add html_attrs keyword arg to widget classes
2003-12-01
Patch: add html_attrs keyword arg to widget classes
2003-12-01
Patch: add html_attrs keyword arg to widget classes
2003-12-01
2003-12-02
2003-12-03
2003-12-02
Patch: add html_attrs keyword arg to widget classes
2003-12-01
Patch: add html_attrs keyword arg to widget classes
2003-12-01
Generalizing form/widget API a bit
Jim Dukarm
2003-11-26
---------- Martin Maney: --------------
> It's a nasty, inconsistent gimmick, IMO.  Or does it allow for
> consistent use of the trailing underscore even with non-keywords?

I wonder whether it is even necessary to avoid the word "class" in
this context, since it is just being used as a dict key and eventually
gets included in a stream of text.

> Lovely idea, but it seems to require more than just 2.2:

You have a point there.

Greg's 'attrs' could be a function that would overcome this problem,
along the lines of a 'cookbook' trick, which I think should work in
Python 2.2:

def attrs(**kwargs):
    return kwargs

Jim Dukarm
DELTA-X RESEARCH
Victoria BC Canada


reply