diff options
author | Mert Tumer <mert.tumer@collabora.com> | 2022-07-05 12:03:27 +0300 |
---|---|---|
committer | Mert Tumer <mert.tumer@collabora.com> | 2022-07-26 19:56:03 +0300 |
commit | 3597348af55ec3c066067a2376289fbde2f62a95 (patch) | |
tree | 399641a3be7d2cb62a79a451700be9a3b88e3b2b /cui/inc/treeopt.hrc | |
parent | Revert "avoid repeated writer layout calls with tiled rendering" (tdf#145396) (diff) | |
download | core-private/mert/wip_deepl.tar.gz core-private/mert/wip_deepl.zip |
new uno command uno:Translate with deepl api
private/mert/wip_deepl
New Uno command added for translation
right now it is only using deepl translation api
There's a section in the options > language settings
for setting up the api url and auth key
uno:Translate is a menu button under Format tab
which will bring up Language Selection dialog for translation.
DeepL can accept html as the input for translation, this new
feature leverages that by exporting paragraphs/selections to
html and paste them back without losing the formatting (in theory)
This works good in general but we may lose formatting in very complex
styled sentences.
Translation works in two ways;
1) Whole document
when there is no selection, it assumes that we want to translate whole
document. Each paragraphs is sent one by one so that the output timeout
can be minimum for each paragraph.
2) Selection
Signed-off-by: Mert Tumer <mert.tumer@collabora.com>
Change-Id: Ia2d3ab2f6757faf565b939e1d670a7dedac33390
Diffstat (limited to 'cui/inc/treeopt.hrc')
-rw-r--r-- | cui/inc/treeopt.hrc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/cui/inc/treeopt.hrc b/cui/inc/treeopt.hrc index 952b79ea92d4..6d5bc4004a53 100644 --- a/cui/inc/treeopt.hrc +++ b/cui/inc/treeopt.hrc @@ -55,7 +55,8 @@ const std::pair<TranslateId, sal_uInt16> SID_LANGUAGE_OPTIONS_RES[] = { NC_("SID_LANGUAGE_OPTIONS_RES", "Searching in Japanese"), RID_SVXPAGE_JSEARCH_OPTIONS }, { NC_("SID_LANGUAGE_OPTIONS_RES", "Asian Layout"), RID_SVXPAGE_ASIAN_LAYOUT }, { NC_("SID_LANGUAGE_OPTIONS_RES", "Complex Text Layout"), RID_SVXPAGE_OPTIONS_CTL }, - { NC_("SID_LANGUAGE_OPTIONS_RES", "LanguageTool Server Settings"), RID_SVXPAGE_LANGTOOL_OPTIONS } + { NC_("SID_LANGUAGE_OPTIONS_RES", "LanguageTool Server Settings"), RID_SVXPAGE_LANGTOOL_OPTIONS }, + { NC_("SID_LANGUAGE_OPTIONS_RES", "DeepL Server Settings"), RID_SVXPAGE_DEEPL_OPTIONS } }; const std::pair<TranslateId, sal_uInt16> SID_INET_DLG_RES[] = |