Description
This relates to #7275 because I would like lists to match the native styles of Word and of HTML. I am opening as a separate issue because resolution could be different than #7275.
Suppose you have this Markdown unordered list:
* Is this indented?
* Proper vertical space here?
* How about here?
* Back to first level.
* Vertical spacing again. Issue?
* How does this look?
When pandoc converts to a Word document, I see these deviations from conventions of both Word and in HTML (as viewed in browsers):
- first-level bullets are not indented
- second-level bullets are dashes instead of open discs
- list items have additional vertical spacing
These are just the differences I see in what I have recently done. A more exhaustive review may find more deltas.
The additional vertical spacing corresponds to a configuration difference in a pandoc-generated Word doc vs. native Word list styling: When selecting a list item in its entirety in Word, then clicking on the arrow on the bottom right of the Paragraph section in the Home ribbon, I see that the Don't add space between paragraphs of the same style box is unchecked in the pandoc-generated document. If you opened a blank, new document in Word 365 and created an identical list by hand, that checkbox would be checked. Checking that box in the pandoc-generated document eliminates the undesired extra vertical spacing.
Some solutions (meant as ideas, not as an exhaustive list):
- Allow reference docs to provide list styles. That is not currently supported per https://pandoc.org/MANUAL.html#option--reference-doc. (This is relevant to Custom bullet symbols in reference docx are ignored #4321 and Support customisable indentation of nested lists in .docx output #6586.)
- Change pandoc to use conventional list styles for Word conversions: no extra vertical spacing, indent first level list, and use conventional bullet styles, as per unstyled/native Word documents or browser renderings of basic HTML lists.