summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorKonstantin Ritt <ritt.ks@gmail.com>2012-04-11 11:42:31 +0300
committerQt by Nokia <qt-info@nokia.com>2012-04-13 08:34:00 +0200
commit89e5740a9567f592bedf73b25971d935a85da858 (patch)
treeb881bbdfead06e39bd95ab2d6c88fea7763ab232 /src
parent810fdd65e6c609999060df32f86afcaaae74f300 (diff)
QChar: documentation fixes
Change-Id: Ic4b58ab811e53cf175ebaf0a67c40c56678f0f35 Reviewed-by: Lars Knoll <lars.knoll@nokia.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Diffstat (limited to 'src')
-rw-r--r--src/corelib/tools/qchar.cpp19
1 files changed, 18 insertions, 1 deletions
diff --git a/src/corelib/tools/qchar.cpp b/src/corelib/tools/qchar.cpp
index 165bda7b05..ef229fc0fc 100644
--- a/src/corelib/tools/qchar.cpp
+++ b/src/corelib/tools/qchar.cpp
@@ -1238,10 +1238,24 @@ ushort QChar::toCaseFolded(ushort ucs2)
Returns the Latin-1 character equivalent to the QChar, or 0. This
is mainly useful for non-internationalized software.
+ \note It is not possible to distinguish a non-Latin-1 character from a Latin-1 0
+ (NUL) character. Prefer to use unicode(), which does not have this ambiguity.
+
\sa toAscii(), unicode()
*/
/*!
+ \fn QChar QChar::fromLatin1(char)
+
+ Converts the Latin-1 character \a c to its equivalent QChar. This
+ is mainly useful for non-internationalized software.
+
+ An alternative is to use QLatin1Char.
+
+ \sa fromAscii(), unicode()
+*/
+
+/*!
\fn char QChar::toAscii() const
Returns the Latin-1 character value of the QChar, or 0 if the character is not
@@ -1254,6 +1268,9 @@ ushort QChar::toCaseFolded(ushort ucs2)
\note It is not possible to distinguish a non-Latin 1 character from an ASCII 0
(NUL) character. Prefer to use unicode(), which does not have this ambiguity.
+ \note This function does not check whether the character value is inside
+ the valid range of US-ASCII.
+
\sa toLatin1(), unicode()
*/
@@ -1307,7 +1324,7 @@ QDataStream &operator>>(QDataStream &in, QChar &chr)
/*!
\fn ushort QChar::unicode() const
- \overload
+ Returns the numeric Unicode value of the QChar.
*/
/*****************************************************************************