@roger64: Oh, sorry, it is my fault! I just misread writer2xhtml as writer2epub, since I've read about the latter one before and writer2xhtml didn't came to my mind as a separate tool because OpenOffice/LibreOffice has already a XHTML export integrated in the GUI. I looked a little bit into the description of those tools, and fortunately they're written in Java (portable, widely installed), LGPLed and usable as command line tools, so they would be automatable. Regarding your description of the features, those tools could be the missing link between LibreOffice as front end for semantic markup and an automated processing workflow as backend, with the opportunity of highly customizable intervention at each processing step.
As you might probably know, EPUB isn't much more than zipped XHTMLs, so by unzipping an EPUB, you could use the files directly for a xhtml2latex or xhtml2fo tool I'm going to develop in the future. Still, the XHTML in the EPUB needs to be semantic (where Sigil may come back into the picuture...).
@st_albert: Full automatization could only be achieved if LibreOffice would enforce semantic markup and prevent direct formatting (probably as a special mode). All you would have to do in such a case would be to match your house styles to the styles found in the ODT. If possible, you could export your house styles to the writer, he would import them, so there wouldn't even be a need to match styles - still, LibreOffice seems to be not capable of such template exporting/importing, and it would only work for authors or content providers who you can convince to use the templates in the first place with LibreOffice. If not, you or a formatter may use LibreOffice to apply your house styles to the text written in another writing tool, word processor or text editor.
Now I'll go and try the standalone tools for myself, so that they probably can be integrated into a fully automated processing workflow. Without question, such an implementation would need quite some time, but if it gets solved once (and over time, I'm confident it will), it can be used by everyone since it is free software, and also extended and improved for all kinds of special purposes and customizations.
|