Add more translations

This commit is contained in:
Veronica K. B. Olsen
2021-02-17 19:10:50 +01:00
parent 5a685474ff
commit be8f98f6c7
4 changed files with 51 additions and 19 deletions
+1 -2
View File
@@ -828,8 +828,7 @@ class GuiPreferencesEditor(QWidget):
for spTag, spProv in theDict.listDictionaries():
qLocal = QLocale(spTag)
spLang = qLocal.nativeLanguageName().title()
spName = qLocal.bcp47Name()
self.spellLangList.addItem("%s (%s) [%s]" % (spLang, spName, spProv), spTag)
self.spellLangList.addItem("%s [%s]" % (spLang, spProv), spTag)
spellIdx = self.spellLangList.findData(self.mainConf.spellLanguage)
if spellIdx != -1:
+6 -3
View File
@@ -27,7 +27,7 @@ along with this program. If not, see <https://www.gnu.org/licenses/>.
import nw
import logging
from PyQt5.QtCore import Qt
from PyQt5.QtCore import Qt, QLocale
from PyQt5.QtGui import QIcon, QPixmap, QColor, QBrush
from PyQt5.QtWidgets import (
QHBoxLayout, QVBoxLayout, QLineEdit, QPlainTextEdit, QLabel, QWidget,
@@ -207,11 +207,14 @@ class GuiProjectEditMain(QWidget):
)
self.spellLang = QComboBox(self)
self.spellLang.setFixedWidth(xW)
theDict = self.theParent.docEditor.theDict
self.spellLang.addItem(self.tr("Default"), "None")
if theDict is not None:
for spTag, spName in theDict.listDictionaries():
self.spellLang.addItem(spName, spTag)
for spTag, spProv in theDict.listDictionaries():
qLocal = QLocale(spTag)
spLang = qLocal.nativeLanguageName().title()
self.spellLang.addItem("%s [%s]" % (spLang, spProv), spTag)
self.mainForm.addRow(
self.tr("Spell check language"),