Closed iandol closed 10 years ago
I'm not sure why it puts this at the top instead of the bottom in the navigator. But in my tests, the document itself is correct.
As for customizing ODT, you have to do this inside the MMD source.
The rogue Bibliography is also present in your MMD user guide: http://fletcher.github.io/MultiMarkdown-4/MMD_Users_Guide.fodt
Your document has no "real" Bibliography section at all (neither does mine). Can you think of any problems if I just delete this master-styles section? Thanks for all your hard work on an excellent tool BTW!
@fletcher — the rogue header is still being added to all FODT output. The problem is there is a text:h element (line 255 of you doc fodt) that is being read. Here is you MMD documentation with the rogue heading:
Is this a bug with LibreOffice?
This seems to be a problem with OpenOffice/LibreOffice, but I haven't looked into it since my original response.
Here is the part of the MMD code where the header element is inserted into the styles section:
https://github.com/fletcher/MultiMarkdown-4/blob/master/odf.c#L1231
Note, I remove the <text:h text:outline-level="2">Bibliography</text:h>
manually from the FODT and this "fixes" the rogue header, but I don't understand what it is doing in styling XML in the first place. I'll post a bug on the LibreOffice bugzilla, perhaps they know why there is a text:h element in this styling code?
In a new FODT created by LibreOffice Writer, this is the master-styles section, it doesn't contain any text headers:
<office:master-styles>
<style:master-page style:name="Standard" style:page-layout-name="pm1"/>
</office:master-styles>
OK, so you're creating an endnote page style which has a "heading-2" in the page header with the text "Bibliography", I can recreate this denovo using V5.02 of LibreOffice, and the same thing happens in Navigator and PDF output, so I've created a LibreOffice bug for this behaviour: https://bugs.documentfoundation.org/show_bug.cgi?id=94345
The workaround is either to ignore it and all documents produced by MMD->ODT have this, or remove the header until this is fixed.
When I output (document written in Scrivener) to flat ODF, I notice in the Navigator there is a rogue bibliography section: I can't find any heading in the document that matches this rogue entry. I do see in the raw fodt file the following:
This is somehow leaking into the document structure, I don't understand odt format but I imagine this is a bug in Libreoffice. I don't understand what the master-style section does, but can I control removing it when MMD generates its output (simple deletion causes a loading error)? I have lots of other little things I'd like to change (which I currently do using regexes), and the MMD manual suggests I can customise ODT output but I don't know where to start.