diff options
author | Kai Koehne <kai.koehne@theqtcompany.com> | 2014-10-20 16:51:08 +0200 |
---|---|---|
committer | Kai Koehne <kai.koehne@theqtcompany.com> | 2014-10-23 17:12:54 +0200 |
commit | 15377a6927a2df1dcf5592eea411ac1f0dd24840 (patch) | |
tree | 2eb85000b5de613ae18a9d186a4da52cb7554497 /src/corelib | |
parent | a133cea211b77a98f0d35b0b3e3c214bac1dc6b8 (diff) |
Doc: Fix description of QTranslator::translate()
If the translations are incomplete it's actually not ensured that a
translation without disambiguation is used: lrelease will drop the
disambiguation from one of the identical messages if there is no message
which actually has no disambiguation ...
Task-number: QTBUG-30471
Change-Id: I1787f5c401a7afb964acbf8a8609ba328c8140a9
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Diffstat (limited to 'src/corelib')
-rw-r--r-- | src/corelib/kernel/qtranslator.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/corelib/kernel/qtranslator.cpp b/src/corelib/kernel/qtranslator.cpp index d0fa0613b3..33827926c6 100644 --- a/src/corelib/kernel/qtranslator.cpp +++ b/src/corelib/kernel/qtranslator.cpp @@ -1086,6 +1086,11 @@ void QTranslatorPrivate::clear() \a disambiguation). If none is found, also tries (\a context, \a sourceText, ""). If that still fails, returns a null string. + \note Incomplete translations may result in unexpected behavior: + If no translation for (\a context, \a sourceText, "") + is provided, the method might in this case actually return a + translation for a different \a disambiguation. + If \a n is not -1, it is used to choose an appropriate form for the translation (e.g. "%n file found" vs. "%n files found"). |