The `h1_` to `h6_` tags define headers, combining the opening and closing tag where the s attribute is the block content. >>> b = HtmlBuilder() >>> b.compact = True >>> b.h1_('Hello world') >>> b.getHtml() ' Hello world '
(self, s, **args)
| 781 | self.newLine() # Optional newline is self.compact is False. |
| 782 | |
| 783 | def h1_(self, s, **args): |
| 784 | """The `h1_` to `h6_` tags define headers, combining the opening and |
| 785 | closing tag where the s attribute is the block content. |
| 786 | |
| 787 | >>> b = HtmlBuilder() |
| 788 | >>> b.compact = True |
| 789 | >>> b.h1_('Hello world') |
| 790 | >>> b.getHtml() |
| 791 | '<h1>Hello world</h1>' |
| 792 | """ |
| 793 | self.h1(**args) |
| 794 | self.addHtml(s) |
| 795 | self._h1() |
| 796 | |
| 797 | def h2(self, **args): |
| 798 | """The `h1` to `h6` tags define headers. h1 defines the largest header. h6 |