badly formed open document format file

I wonder if anyone on the list can provide any clues as to why a file is
badly formed ?

The file concerned is an export from another application (Scrivener)
which provides the option to export as an open document odt. The test
file comprises 2 paragraphs of text followed by a third paragraph
incorporating a bullet list and completed by a fourth text paragraph.

When this file, testexport.odt, is opened in LibreOffice Writer, the
bullets and their associated text items are completely missing. Other
text paragraphs are good.

Exports in other formats (.doc, .pdf, .rtf) are correct and can be read
by LO or Okular (pdf).

I am hoping someone more clued up than me can 'analyse' the test files
and provide a clue as to where the odt file is badly made.

The testexport.odt file is at at this link :

https://www.dropbox.com/s/buw0iy5i5xytcwe/testexport.odt?dl=0

It should look like this file :

https://www.dropbox.com/s/3hc2r74vx2j67qj/testexport.doc?dl=0

Thankyou,
Philip

Philip Jackson wrote:

> I wonder if anyone on the list can provide any clues as to why a file is
> badly formed ?
>
> The file concerned is an export from another application (Scrivener)
> which provides the option to export as an open document odt. The test
> file comprises 2 paragraphs of text followed by a third paragraph
> incorporating a bullet list and completed by a fourth text paragraph.
>
> When this file, testexport.odt, is opened in LibreOffice Writer, the
> bullets and their associated text items are completely missing. Other
> text paragraphs are good.
>
> Exports in other formats (.doc, .pdf, .rtf) are correct and can be read
> by LO or Okular (pdf).
>
> I am hoping someone more clued up than me can 'analyse' the test files
> and provide a clue as to where the odt file is badly made.

The bulleted paragraphs are in the file as a <text:list-item>, but they are not inside a <text:list> element as required.

My Scrivener (2.7 on Mac OS X) does export the <text:list> with <text:list-item>s inside it, but it also puts its own bullet before each paragraph so that they now have 2 bullets each in the ODT file!

Thanks for the clue, Piet. I have been able to make the correction that
you suggested directly in the content.xml file and it works fine.

Not much use for serious work though.

Philip

Piet van Oostrum wrote:

> My Scrivener (2.7 on Mac OS X) does export the <text:list> with
> <text:list-item>s inside it, but it also puts its own bullet before
> each paragraph so that they now have 2 bullets each in the ODT
> file!

It appears that the Scrivener 2.7 situation is different than I thought. I tested it on a Scrivener doc with the test page imported from the .doc file (and also by copy/pasting that text). It appears that Scrivener imports the list in a strange way: it makes a list with no bullets as a list attribute, but with the bullets prepended to each list element. So when exporting it to ODT, the list elements get two bullets: one from being a list element, the other in the text. By correcting the list after importing it will be exported correctly. So the problem is on the import side, not the export side.