Description
Migrating from legacy binary document formats to ODF can be a pain if the True Type fonts used in these documents only support a non Unicode encoding (e.g. only ARMSCII-8 or VISCII). These documents are readable in e.g. Openoffice when the appropriate legacy fonts are installed but not editable since ODF uses UTF-8 for character encoding. So when inserting new characters they'll be picked from another font since they're not found in the character table of the legacy font.
Odfrecode allows to remap these 8 bit character sets to the appropriate Unicode codepoints (after they've been converted to ODF) and makes it therefore possible to get rid of the legacy fonts used in these documents.
There are currently two tools available:
- odfrecode is non interactive and can be used for batch conversion
- odfrecode-gtk shows a dialog after conversion which allows the user to direclty open the converted Document in OpenOffice (or another ODF capable application). This can e.g. be used in a Nautilus/Konqueror/Dolphin context menu.
There are currently recoders from Armenian (ARMSCII-8), Georgian, Cyrillic (Windows-1251) and Greek (Windows-1253) to Unicode. The Romanian recoder just cleans up the bug explained in #327501.
Note: I'm not a native speaker of any of these languages so please excuse (and report) any errors made.
Examples
The following example recodes foo.odt from armscii8 to unicode:
odfrecode-gtk --recoder=armscii8 foo.odt
New converters can easily be added. For a simple example have a look at odfrecode/recoders/romanian.py.
Source Code
The source code is available via:
git clone https://git.sigxcpu.org/cgit/odfrecode
and can be browsed here.
Installation
After cloning the repository as described above run change into the source code directory and run:
python setup.py
This will install the necessary files on your system. If you're looking for a Debian package have a look at the debian branch in the git repository.
TODO
recoders
- Add more recoders (viscii, ...)
odfrecode-gtk
- Add i18n
- Add interactive mode (file browser, etc.)
- Add service menus for konqueror/dolphin/nautilus
Authors
Odfrecode was written by Guido Günther <agx@sigxcpu.org>. Many recoders were contributed by Torsten Werner <twerner@debian.org>.
License
Odfrecode is free software and licensed under the GPLv2.