-
Notifications
You must be signed in to change notification settings - Fork 55
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Space between item listing/tables #228
Comments
As I check the code I see that this was deliberately done, via: def export_paragraph(self, paragraph):
results = super(PyDocXHTMLExporter, self).export_paragraph(paragraph)
results = is_not_empty_and_not_only_whitespace(results)
if results is None:
return Any reason why we do that? Basically I think that we need to detect empty paragraph and convert them into |
If I recall correctly, it's because word documents can have these blank p's, but don't actually render to anything in a document. Empty p's in OOXML do not necessarily translate to a line break in HTML. If in doubt, 1) check the spec: how does it say empty p's should be handled? 2) construct a word document with some empty p's. Open the document in Word. What happens? |
Yes, I did some tests and basically if we add an empty I did some work related to this here: botzill@34ee045. To properly allow This way we don't actually need this method : Line 255 in 9cd76ee
But not sure yet if this will cover all the cases. From tests I did seems be fine so far. |
The info I found about
Also here: https://msdn.microsoft.com/en-us/library/documentformat.openxml.wordprocessing.paragraph.aspx. But no info related to empty paragraphs. |
Currently if we have a list like:
is exported as:
So, there is no space between items.
This is applied to tables as well:
input:
output:
The text was updated successfully, but these errors were encountered: