LibreOffice plugin to pipe whole Writer documents through Google Translate, that ought to keep most of the page formatting.

⌈⌋ branch:  PageTranslate


Artifact [41c489ea55]

Artifact 41c489ea55301436dc9d4842c3e8862619a41252:

Wiki page [options] by mario 2020-06-07 13:37:28.
D 2020-06-07T13:37:28.275
L options
N text/x-markdown
P d6ba9b3453f7ff71e4c48b33b343d0d00afd9f87
U mario
W 1740
The settings page allows to define a few operation parameters.

### Primarily which service to use:

❎ **Google Translate** is the default

❏ **DeepL web** interface (kinda works, but only allows a few short paragraphs to be translated / then blocks further requests / "http error 429")

❏ **DeepL per API** (as of yet untested)

<div style="padding-left: 20pt">
 <b>API key</b> (also for Microsoft Translator)<br>
 <input type=text size=20>
</div>

❏ **Microsoft Translator** (requires an authorization key, and a `pip install translate` system package)

❏ **MyMemory** (should have an email address in the "API key" field, also requires `pip install translate`)

<div style="padding-left: 20pt">
 <b>Email</b> (optional, but recommended)<br>
 <input type=text size=20 value=you@example.com>
</div>

❏ **Command line tool** allows to send each text paragraph to a local application. To use it, set the command in the "API key" field again. For example:

<div style="padding-left: 20pt">
 <b>Command</b><br>
 <input type=text size=20 value="translate-cli -o -t {lang} [text}">
</div>

   Where `{text}` is a placeholder for the current text section. (Automatically escaped.)

### Additional options:

❏ **quick linebreak handling** might speed up table processing with Google Translate, as it avoids sending each newline-split sentence separately.

❏ **super slsow mode** iterates over paragraph segments, to keep more inline formatting - but seriously harms mid-sentence translations. Not very useful in practice.

❏ **also iterate over TextFrames** handles floating textframes / subdocuments.

❎ **debug mode** will fill up the /tmp/pagetranslate-libreoffice.txt file quicker

Z 84836310f00121901989e8281f78c299