When I save an odt document with footnotes as Text (.txt), footnotes are removed but corresponding numbers in text are preserved.
So this is half way through, either delete footnotes completely or leave them. Is it normal or a bug?
I want to have a text without footnotes to be able to process it with a text-to-speech convertor.
I also didn’t find out how to remove all footnotes from an odt document at one go.
A plain text file (.txt) is just a sequence of characters without structure nor formatting. In particular, there is no notion of pages, hence no top or bottom of pages. Consequently there is no logical location to put notes there. Notes are skipped (whether footnotes or endnotes for a similar argument).
You might question why the note anchor is left. The anchor is part of the main text flow as a real character (with formatting information added “off-band”). The note text itself is insert as meta-information which needs to be specifically collected to be laid out. It is not part of the main text flow.
When exporting to plain text, Writer only scans the main text flow, skipping any formatting and meta information. IMHO (I’m no developer), eliminating the anchor would require a huge parsing job, correlating the anchor sequence with subsequent meta information (because what looks like an anchor may also be a voluntary text entry by user). I don’t think the performance impact is worth it.
If you have a reasonable number of notes, you can eliminate them manually quite easily. Recent versions of Writer (read: 7.x releases) have a Footnotes & Endnotes in the Navigator (F5 if not already visible).
- expand the Footnotes & Endnotes to display all notes
- double-click on a note (the cursor will be sent to the start of the note anchor)
- press Del (this will delete the anchor and note text)
- repeat
Note also that [:control:]
regex would find these - among with other special entities, like fields. So using Find and Replace, and replacing manually (checking each occurrence) with nothing, could also be used.