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
David Binger
2003-11-25
> Need to think about it more, I guess.
>

Agreed.  The set of xhtml attributes isn't huge, but there are some
opportunities
for confusion there: 'title' and 'id' come to mind, and what about
'xml:lang'?
Maybe the attributes should always be passed in a dictionary, and some
other
sugar-wrapper can be used to make it convenient to make an attributes
dictionary
to pass.


   def __init__(self, name, value=None, attributes=None)
         ...
         self.attributes = attributes or {}


Thing('age', value=3, attributes=sugar(title='ok'))


reply