Changeset 4537:e9861188889d in livinglogic.python.xist

Show
Ignore:
Timestamp:
08/10/11 16:52:58 (8 years ago)
Author:
Walter Doerwald <walter@…>
Branch:
default
Tags:
rel-3-24-1
Message:

Fixed publishing BoolAttrs? in AttrElement?.

Files:
5 modified

Legend:

Unmodified
Added
Removed
  • NEWS.rst

    r4535 r4537  
     1Changes in 3.24.1 (released 08/10/2011) 
     2--------------------------------------- 
     3 
     4*   Fixed a bug in the new :class:`ll.xist.xsc.AttrElement` class that surfaced 
     5    in the context of boolean attributes. 
     6 
     7 
    18Changes in 3.24 (released 08/09/2011) 
    29------------------------------------- 
  • setup.py

    r4533 r4537  
    228228args = dict( 
    229229    name="ll-xist", 
    230     version="3.24", 
     230    version="3.24.1", 
    231231    description="Extensible HTML/XML generator, cross-platform templating language, Oracle utilities and various other tools", 
    232232    long_description=description, 
  • src/ll/xist/ns/ul4.py

    r4533 r4537  
    8686    def publishboolattr(self, publisher, attr): 
    8787        name = attr._publishname(publisher) 
    88         yield publisher.encode(u'<?if {cond}?> {name}'.format(cond=unicode(self.attrs.cond), name=attr._publishname(publisher))) 
     88        yield publisher.encode(u'<?if {cond}?> {name}'.format(cond=unicode(self.attrs.cond), name=name)) 
    8989        if publisher.xhtml>0: 
    9090            yield publisher.encode(u'="{name}"'.format(name=name)) 
  • src/ll/xist/xsc.py

    r4536 r4537  
    23272327            self.checkvalid() 
    23282328        if len(self)==1 and isinstance(self[0], AttrElement): 
    2329             for part in self[0].publishboolattr(publisher): 
     2329            for part in self[0].publishboolattr(publisher, self): 
    23302330                yield part 
    23312331        else: 
  • test/test_ul4.py

    r4533 r4537  
    19481948        yield eq, u'', r(s, cond=False) 
    19491949        yield eq, u'''<a>gu'"rk</a>''', r(s, cond=True) 
     1950 
     1951    s = html.ul(compact=ul4.attr_if(True, cond="cond")).conv().string() 
     1952    for r in all_renderers: 
     1953        yield eq, u'<ul></ul>', r(s, cond=False) 
     1954        yield eq, u'''<ul compact="compact"></ul>''', r(s, cond=True)