mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
TXT Output: Handle scene breaks defined by margin-top in the css of the OEB.
This commit is contained in:
parent
5aef8ab40a
commit
76837bbd7e
@ -222,6 +222,8 @@ class TXTMLizer(object):
|
|||||||
# Scene breaks.
|
# Scene breaks.
|
||||||
if tag == 'hr':
|
if tag == 'hr':
|
||||||
text.append('\n\n* * *\n\n')
|
text.append('\n\n* * *\n\n')
|
||||||
|
elif style['margin-top']:
|
||||||
|
text.append('\n\n' + '\n' * round(style['margin-top']))
|
||||||
|
|
||||||
# Process tags that contain text.
|
# Process tags that contain text.
|
||||||
if hasattr(elem, 'text') and elem.text:
|
if hasattr(elem, 'text') and elem.text:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user