summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLiang Qi <liang.qi@qt.io>2017-01-31 08:49:01 +0100
committerLiang Qi <liang.qi@qt.io>2017-02-01 08:35:42 +0000
commit3cd1c3cb70dd57df939ad067f5668e8304d32237 (patch)
tree759f9c14dc4fbfb50bd84a8d8e6815e274e0ed87
parent681c15891e723925a876f5d3e8d711b503384285 (diff)
Fix libs build with msvc on Chinese locale on Windows
Chinese locale means Code Page 936 here. It's also related with removing C4819 warnings. And it's also following Conventions in Qt source code: All code is ascii only (7-bit characters only, run man ascii if unsure) See also http://wiki.qt.io/Coding_Conventions Task-number: QTBUG-56155 Task-number: QTBUG-58161 Change-Id: I37fa7a0e6a82a16eaf80e1cc99be801099ab87de Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: jian liang <jianliang79@gmail.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
-rw-r--r--src/3rdparty/harfbuzz/src/harfbuzz-thai.c2
-rw-r--r--src/corelib/tools/qstring.cpp8
-rw-r--r--src/corelib/tools/qunicodetools.cpp2
-rw-r--r--src/plugins/generic/tuiotouch/qtuiohandler.cpp2
4 files changed, 7 insertions, 7 deletions
diff --git a/src/3rdparty/harfbuzz/src/harfbuzz-thai.c b/src/3rdparty/harfbuzz/src/harfbuzz-thai.c
index 2d4627e4f7..fe3296e887 100644
--- a/src/3rdparty/harfbuzz/src/harfbuzz-thai.c
+++ b/src/3rdparty/harfbuzz/src/harfbuzz-thai.c
@@ -277,7 +277,7 @@ static HB_Bool HB_ThaiConvertStringToGlyphIndices (HB_ShaperItem *item)
}
}
- /* Special case to handle U+0E33 (SARA AM, ำ): SARA AM is normally written at the end of a
+ /* Special case to handle U+0E33 (SARA AM): SARA AM is normally written at the end of a
* word with a base character and an optional top character before it. For example, U+0E0B
* (base), U+0E49 (top), U+0E33 (SARA AM). The sequence should be converted to 4 glyphs:
* base, hilo (the little circle in the top left part of SARA AM, NIKHAHIT), top, then the
diff --git a/src/corelib/tools/qstring.cpp b/src/corelib/tools/qstring.cpp
index aae4aab4c9..247119d178 100644
--- a/src/corelib/tools/qstring.cpp
+++ b/src/corelib/tools/qstring.cpp
@@ -1840,7 +1840,7 @@ QString &QString::operator=(const QString &other) Q_DECL_NOTHROW
*/
QString &QString::operator=(QLatin1String other)
{
- if (isDetached() && other.size() <= capacity()) { // assumes d->alloc == 0 → !isDetached() (sharedNull)
+ if (isDetached() && other.size() <= capacity()) { // assumes d->alloc == 0 -> !isDetached() (sharedNull)
d->size = other.size();
d->data()[other.size()] = 0;
qt_from_latin1(d->data(), other.latin1(), other.size());
@@ -1899,7 +1899,7 @@ QString &QString::operator=(QLatin1String other)
*/
QString &QString::operator=(QChar ch)
{
- if (isDetached() && capacity() >= 1) { // assumes d->alloc == 0 → !isDetached() (sharedNull)
+ if (isDetached() && capacity() >= 1) { // assumes d->alloc == 0 -> !isDetached() (sharedNull)
// re-use existing capacity:
ushort *dat = d->data();
dat[0] = ch.unicode();
@@ -8357,7 +8357,7 @@ QString &QString::setRawData(const QChar *unicode, int size)
Returns the character at position \a pos in this object.
\note This function performs no error checking.
- The behavior is undefined when \a pos < 0 or \a pos ≥ size().
+ The behavior is undefined when \a pos < 0 or \a pos >= size().
\sa operator[]()
*/
@@ -8368,7 +8368,7 @@ QString &QString::setRawData(const QChar *unicode, int size)
Returns the character at position \a pos in this object.
\note This function performs no error checking.
- The behavior is undefined when \a pos < 0 or \a pos ≥ size().
+ The behavior is undefined when \a pos < 0 or \a pos >= size().
\sa at()
*/
diff --git a/src/corelib/tools/qunicodetools.cpp b/src/corelib/tools/qunicodetools.cpp
index be1d88e260..ac19d6b6d1 100644
--- a/src/corelib/tools/qunicodetools.cpp
+++ b/src/corelib/tools/qunicodetools.cpp
@@ -714,7 +714,7 @@ Q_CORE_EXPORT void initScripts(const ushort *string, int length, uchar *scripts)
}
// Never break between a combining mark (gc= Mc, Mn or Me) and its base character.
- // Thus, a combining mark — whatever its script property value is — should inherit
+ // Thus, a combining mark - whatever its script property value is - should inherit
// the script property value of its base character.
static const int test = (FLAG(QChar::Mark_NonSpacing) | FLAG(QChar::Mark_SpacingCombining) | FLAG(QChar::Mark_Enclosing));
if (Q_UNLIKELY(FLAG(prop->category) & test))
diff --git a/src/plugins/generic/tuiotouch/qtuiohandler.cpp b/src/plugins/generic/tuiotouch/qtuiohandler.cpp
index 26b88d6d78..eb646644ec 100644
--- a/src/plugins/generic/tuiotouch/qtuiohandler.cpp
+++ b/src/plugins/generic/tuiotouch/qtuiohandler.cpp
@@ -488,7 +488,7 @@ void QTuioHandler::process2DObjSet(const QOscMessage &message)
return;
}
- qCDebug(lcTuioSet) << "Processing SET for token " << classId << id << " @ " << x << y << "∡" << angle <<
+ qCDebug(lcTuioSet) << "Processing SET for token " << classId << id << " @ " << x << y << " angle: " << angle <<
"vel" << vx << vy << angularVelocity << "acc" << acceleration << angularAcceleration;
QTuioToken &tok = *it;
tok.setClassId(classId);