wip: in-dev for HTML tabulations from final result
This commit is contained in:
parent
c841c63218
commit
8664c8babc
|
@ -591,7 +591,6 @@ def tab_article(article):
|
|||
for line in article:
|
||||
if len(line) == 0: continue
|
||||
|
||||
print(line)
|
||||
if line.startswith('<h'):
|
||||
tn = line[2]
|
||||
tab = int(tn) * 3
|
||||
|
@ -599,12 +598,12 @@ def tab_article(article):
|
|||
tab = int(tab) + 3
|
||||
continue
|
||||
|
||||
if line.startswith('<div'):
|
||||
if line.startswith('<div') or line.startswith('<p'):
|
||||
wip_tmp = '%s\n%s%s'%(wip_tmp, int(tab)*' ', line)
|
||||
tab = int(tab) + 3
|
||||
continue
|
||||
|
||||
if line.startswith('</div'):
|
||||
if line.startswith('</div') or line.startswith('</p'):
|
||||
tab = int(tab) - 3
|
||||
wip_tmp = '%s\n%s%s'%(wip_tmp, int(tab)*' ', line)
|
||||
continue
|
||||
|
|
Loading…
Reference in New Issue