Ask Your Question
0

LibreWriter: convert footnotes into endnotes or vice versa? Plus: macOS workflow to convert manually

asked 2016-10-14 13:57:45 +0200

JayBrown gravatar image

updated 2016-10-14 15:20:06 +0200

Is there a way to convert footnotes into endnotes or vice versa in LibreWriter?

You can change the settings to display footnotes at the end of the document, but there's no conversion.

In an old discussion I found a hint to edit an odt's content.xml, so I created a workflow for macOS that will do that, i.e. convert footnotes <> endnotes (odt & fodt): https://github.com/JayBrown/LOconv

But it would be better, if you could do it from within LibreWriter. Any chances of this being implemented in the future? It seems to be quite easy to do such a conversion. Or has it already been implemented, and I just didn't find it?

edit retag flag offensive close merge delete

Comments

See also tdf#89352.

Lupp gravatar imageLupp ( 2017-11-16 12:05:37 +0200 )edit

4 Answers

Sort by » oldest newest most voted
0

answered 2016-10-16 22:03:29 +0200

JayBrown gravatar image

So the answer is that there is no (official) solution (yet). There isn't a one-shot-convert function in Writer (yet), so I can only suggest that you use the nnConv script (renamed from "LOconv"), which will automate the xml hacks for you. It will work on odt and fodt.

https://github.com/JayBrown/nnConv

  • distro contains a workflow version and shell script with osascript prompts (both for macOS)
  • repo also contains a separate *nix shell script that should work for macOS/Linux/BSD etc. purely on on the command line (tested only on macOS)

It doesn't work on docx files, and probably never will, because that document format is just plain insane. The solution would be to write in odt or fodt format and just export/save as docx, if you need MS Office compatibility, or even as doc, if your work needs to be imported into e.g. InDesign.

edit flag offensive delete link more
0

answered 2016-10-14 19:53:58 +0200

ajlittoz gravatar image

From what I understand of LO (I'm neither a guru nor a developer), no conversion is at stake because there is basically no difference between footnotes and endnotes. The note paragraph is tagged with a style name which is defined by Tools->Footnotes/Endnotes... settings. There you have two tabs for customizing two behaviours. Whether they dictate the set notes at the bottom of the page or at end of a document is a matter of setting a flag (clicking on a radio button). Both settings may result in the same layout despite the names.

Of course, if you use Endnote style for a foot note results in user confusion.

In your case, either you misused the style or started your document with one layout and later changed your mind, it does not matter.

What you really ask for is the ability to change globally the name of a style to avoid to hunt all occurrences.

Have you tried Edit->Find & Replace..., More options, clicking Look for paragraph styles? You select the offending paragraph style from the Find drop-down menu and the replacement paragraph style in the Replace drop down menu.

If this answers your question, please tick the check mark and close the question for community benefit. If you find it valuable, be kind enough to upvote it if you have enough karma.

edit flag offensive delete link more

Comments

Thank you, but that's not what I'm looking for. I know how to change/find/replace styles. When you look at the xml of an OpenDocument file, you'll see that there is a distinct difference between footnotes and endnotes, independent of the style: the former have note-class="footnote", and the latter have note-class="endnote". So the feature request, if it hasn't been implemented yet, is a function to change the note class, not the note style.

JayBrown gravatar imageJayBrown ( 2016-10-14 21:21:42 +0200 )edit

You're right. I never noticed before how the two tabs were different and my trick does not work because of that.

ajlittoz gravatar imageajlittoz ( 2016-10-15 08:49:39 +0200 )edit
0

answered 2016-10-14 23:01:47 +0200

RGB-es gravatar image

Go to the first footnote/endnote anchor → Right click → Footnote/endnote. On the menu you get, you can switch between footnote and endnote just by changing the "type". There is no need to press OK because the change is immediate: just use the arrows to navigate to the next note.

edit flag offensive delete link more

Comments

Thank you… yes, I knew about that as well. For the occasional note it's probably fine, even though the right-click contextual menu isn't always accurate (often missing the footnote/endnote menu item… but it's not a good option for articles/chapters/books with hundreds of footnotes. In these case you'd want a single command to convert all footnotes to endnotes (and/or vice versa) in one shot.

JayBrown gravatar imageJayBrown ( 2016-10-14 23:29:18 +0200 )edit

AFAIK, there is no way to do this "on one shot", sorry: you need to "hack" the ODT file by editing content.xml with a text editor and changing by hand the "note-class" tag.

RGB-es gravatar imageRGB-es ( 2016-10-15 01:07:53 +0200 )edit

Ah, OK, that's what I feared. You can easily replace everything at once with the sed command, which is what I did in the workflow. So I'll send them an "enhancement" bug report.

JayBrown gravatar imageJayBrown ( 2016-10-15 19:57:13 +0200 )edit
0

answered 2017-11-16 01:44:50 +0200

Ricollect gravatar image

updated 2017-11-16 01:47:43 +0200

How about this?

Edit: For convenience and to avoid a possible problem if the link dies, here's the answer from the link:

Try going to Tools / Footnotes & Endnotes. Select the Footnotes tab. Change the selection from "end of page" to "end of document". It changed all of mine in the whole document, just like I was hoping for.

https://askubuntu.com/questions/48274...

edit flag offensive delete link more
Login/Signup to Answer

Question Tools

1 follower

Stats

Asked: 2016-10-14 13:57:45 +0200

Seen: 1,958 times

Last updated: Nov 16 '17