mirror of
https://github.com/koreader/koreader.git
synced 2025-08-10 00:52:38 +00:00
Translator: add "Translate from book language" option (#8094)
When enabled, if the book has some supported language tag in its metadata, use it as the source language. Otherwise, fallback to the current settings (auto-detect or selected source language).
This commit is contained in:
@@ -113,6 +113,8 @@ for __, v in ipairs(LANGUAGES) do
|
||||
ReaderTypography.HYPH_DICT_NAME_TO_LANG_NAME_TAG[hyph_filename] = { lang_name, lang_tag }
|
||||
end
|
||||
end
|
||||
-- Make lang aliases available to other modules (can be used by Translator)
|
||||
ReaderTypography.LANG_ALIAS_TO_LANG_TAG = LANG_ALIAS_TO_LANG_TAG
|
||||
|
||||
function ReaderTypography:init()
|
||||
self.menu_table = {}
|
||||
|
||||
Reference in New Issue
Block a user