class colored_td(html.td): style = html.Style(color='#005E8C', padding='5px', border='2px solid #005E8C', text_align='left', white_space='pre-wrap', font_size='14px')
class th(html.th): style = html.Style(color='#0094ce', padding='5px', border='2px solid #005E8C', text_align='left', font_weight='bold', font_size='15px')
def test_alternating_style(): alternating = ( html.Style(background="white"), html.Style(background="grey"), ) class my(html): class li(html.li): def style(self): i = self.parent.index(self) return alternating[i % 2] style = property(style) x = my.ul(my.li("hello"), my.li("world"), my.li("42")) u = unicode(x) assert u == ('<ul><li style="background: white">hello</li>' '<li style="background: grey">world</li>' '<li style="background: white">42</li>' '</ul>')
class h3(html.h3): style = html.Style(color='#0094ce')
class h2(html.h2): style = html.Style(color='#0094ce')
class h1(html.h1): style = html.Style(color='#0094ce')
class table(html.table): style = html.Style(border='2px solid #005E8C', margin='16px 0px', color='#005E8C', font_size='15px')
class body(html.body): style = html.Style(background_color='#F0F0EE')
class th(html.th): style = html.Style(padding='5px', border='1px solid #E6E6E6', text_align='left', font_weight='bold')
class td(html.td): style = html.Style(padding='5px', border='1px solid #E6E6E6', text_align='left')
class table(html.table): style = html.Style(border='1px solid #e6e6e6', margin='16px 0px', color='#999', font_size='12px')
class body(html.body): style = html.Style(font_size="12pt")