Home | Trees | Indices | Help |
|
---|
|
object --+ | XmlComponent --+ | DIV --+ | BEAUTIFY
Turns any list, dictionary, etc into decent looking html. Two special attributes are - sorted: a function that takes the dict and returned sorted keys - keyfilter: a function that takes a key and returns its representation or None if the key is to be skipped. By default key[:1]=='_' is skipped. Examples: >>> BEAUTIFY(['a', 'b', {'hello': 'world'}]).xml() '<div><table><tr><td><div>a</div></td></tr><tr><td><div>b</div></td></tr><tr><td><div><table><tr><td style="font-weight:bold;vertical-align:top;">hello</td><td style="vertical-align:top;">:</td><td><div>world</div></td></tr></table></div></td></tr></table></div>'
|
|||
|
|||
Inherited from Inherited from Inherited from Inherited from |
|
|||
|
|
|||
tag = 'div'
|
|||
Inherited from |
|
|||
Inherited from |
|
Args: components: any components that should be nested in this element attributes: any attributes you want to give to this element Raises: SyntaxError: when a stand alone tag receives components
|
Home | Trees | Indices | Help |
|
---|
Generated by Epydoc 3.0.1 on Sun Mar 16 02:36:14 2014 | http://epydoc.sourceforge.net |