aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoseph Wenninger <jowenn@kde.org>2014-01-22 12:10:56 (GMT)
committerJoseph Wenninger <jowenn@kde.org>2014-01-22 12:27:47 (GMT)
commit5aeb612f80dba8bf7b02c72238b5f7ba7dfc1d7c (patch)
tree7f2a04886ed46208d3039aee41aa051413e6d4b0
parent911abc30e3787a5332c6ede9f5aa6376631917a1 (diff)
Work around that QSpinbox suffix is not singular/pluralizable
-rw-r--r--src/dialogs/katedialogs.cpp10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/dialogs/katedialogs.cpp b/src/dialogs/katedialogs.cpp
index 82048e4..d91ab1b 100644
--- a/src/dialogs/katedialogs.cpp
+++ b/src/dialogs/katedialogs.cpp
@@ -222,9 +222,11 @@ void KateIndentConfigTab::apply()
void KateIndentConfigTab::reload()
{
- ui->sbTabWidth->setSuffix(ki18np(" character", " characters").toString());
+ ui->sbTabWidth->setSpecialValueText(ki18nc("spinbox special value for 1","1 character").toString());//(ki18np(" character", " characters").toString());
+ ui->sbTabWidth->setSuffix(ki18nc("suffix for spinbox >1", " characters").toString());
ui->sbTabWidth->setValue(KateDocumentConfig::global()->tabWidth());
- ui->sbIndentWidth->setSuffix(ki18np(" character", " characters").toString());
+ ui->sbIndentWidth->setSpecialValueText(ki18nc("spinbox special value for 1","1 character").toString());
+ ui->sbIndentWidth->setSuffix(ki18nc("suffix for spinbox >1", " characters").toString());
ui->sbIndentWidth->setValue(KateDocumentConfig::global()->indentationWidth());
ui->chkKeepExtraSpaces->setChecked(KateDocumentConfig::global()->keepExtraSpaces());
ui->chkIndentPaste->setChecked(KateDocumentConfig::global()->indentPastedText());
@@ -659,7 +661,9 @@ void KateEditGeneralConfigTab::reload()
{
ui->chkStaticWordWrap->setChecked(KateDocumentConfig::global()->wordWrap());
ui->chkShowStaticWordWrapMarker->setChecked(KateRendererConfig::global()->wordWrapMarker());
- ui->sbWordWrap->setSuffix(ki18ncp("Wrap words at", " character", " characters").toString());
+ //ui->sbWordWrap->setSuffix(ki18ncp("Wrap words at", " character", " characters").toString());
+ ui->sbWordWrap->setSpecialValueText(ki18nc("spinbox special value for 1 Wrap words at","1 character").toString());//(ki18np(" character", " characters").toString());
+ ui->sbWordWrap->setSuffix(ki18nc("suffix for spinbox >1 wrap words at", " characters").toString());
ui->sbWordWrap->setValue(KateDocumentConfig::global()->wordWrapAt());
ui->chkSmartCopyCut->setChecked(KateViewConfig::global()->smartCopyCut());
}