diff options
author | rsiddharth <s@ricketyspace.net> | 2018-02-25 06:10:22 +0000 |
---|---|---|
committer | rsiddharth <s@ricketyspace.net> | 2018-02-25 06:10:22 +0000 |
commit | b6ae71a56c966c5236201ba50a52d768ee9fca73 (patch) | |
tree | 00cb99139cf58eede18e7103fb01c757bd0ae867 | |
parent | 87936b0d2113ac0dbba604d7ac1625399c0051d8 (diff) |
md_tw.py: Add TWRenderer.header.
* md_tw.py (TWRenderer)[header]: New method.
-rw-r--r-- | md_tw.py | 7 |
1 files changed, 7 insertions, 0 deletions
@@ -279,6 +279,13 @@ class TWRenderer(mistune.Renderer): lambda line: True) return out + + def header(self, text, level, raw=None): + out = '{}'.format(text) + + return out + + def paragraph(self, text): out = self.tw_fill(text) out = '{}\n{}\n'.format(out, self.tw_get('initial_indent').strip()) |