summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorEdward Welbourne <edward.welbourne@qt.io>2020-07-16 17:21:41 +0200
committerEdward Welbourne <edward.welbourne@qt.io>2020-07-20 16:06:28 +0200
commit996a7fc6f154cc6cd81b9f2af0899e4a8acac812 (patch)
tree1f173b9c30b0bac003880defb2a2b9d665ed788e /src
parent21d9384800f8579f2f76cc1230c0bcd0e240e1c7 (diff)
QChar: purge deprecated API
Since 5.3 joining() and old Joining type Replaced by JoiningType joiningType() Change-Id: Iefee50aaf94cec6d67b5fc004b3e68357b2015c5 Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Diffstat (limited to 'src')
-rw-r--r--src/corelib/text/qchar.cpp52
-rw-r--r--src/corelib/text/qchar.h31
2 files changed, 1 insertions, 82 deletions
diff --git a/src/corelib/text/qchar.cpp b/src/corelib/text/qchar.cpp
index a816e01b68..df9ab17174 100644
--- a/src/corelib/text/qchar.cpp
+++ b/src/corelib/text/qchar.cpp
@@ -1,6 +1,6 @@
/****************************************************************************
**
-** Copyright (C) 2019 The Qt Company Ltd.
+** Copyright (C) 2020 The Qt Company Ltd.
** Contact: https://www.qt.io/licensing/
**
** This file is part of the QtCore module of the Qt Toolkit.
@@ -538,24 +538,6 @@ QT_BEGIN_NAMESPACE
\sa joiningType()
*/
-#if QT_DEPRECATED_SINCE(5, 3)
-/*!
- \enum QChar::Joining
- \deprecated in 5.3, use JoiningType instead.
-
- This enum type defines the Unicode joining attributes. See the
- \l{http://www.unicode.org/}{Unicode Standard} for a description
- of the values.
-
- \value Center
- \value Dual
- \value OtherJoining
- \value Right
-
- \sa joining()
-*/
-#endif
-
/*!
\enum QChar::CombiningClass
@@ -1270,38 +1252,6 @@ QChar::JoiningType QChar::joiningType(char32_t ucs4) noexcept
return QChar::JoiningType(qGetProp(ucs4)->joining);
}
-#if QT_DEPRECATED_SINCE(5, 3)
-/*!
- \fn QChar::Joining QChar::joining() const
- \deprecated in 5.3, use joiningType() instead.
-
- Returns information about the joining properties of the character
- (needed for certain languages such as Arabic).
-*/
-
-/*!
- \overload
- \deprecated in 5.3, use joiningType() instead.
-
- Returns information about the joining properties of the UCS-4-encoded
- character specified by \a ucs4 (needed for certain languages such as Arabic).
-
- \note Before Qt 6, this function took a \c uint argument.
-*/
-QChar::Joining QChar::joining(char32_t ucs4) noexcept
-{
- if (ucs4 > LastValidCodePoint)
- return QChar::OtherJoining;
- switch (qGetProp(ucs4)->joining) {
- case QChar::Joining_Causing: return QChar::Center;
- case QChar::Joining_Dual: return QChar::Dual;
- case QChar::Joining_Right: return QChar::Right;
- default: break;
- }
- return QChar::OtherJoining;
-}
-#endif
-
/*!
\fn bool QChar::hasMirrored() const
diff --git a/src/corelib/text/qchar.h b/src/corelib/text/qchar.h
index 056101325e..8c6b2685aa 100644
--- a/src/corelib/text/qchar.h
+++ b/src/corelib/text/qchar.h
@@ -394,13 +394,6 @@ public:
Joining_Transparent
};
-#if QT_DEPRECATED_SINCE(5, 3)
- enum Joining
- {
- OtherJoining, Dual, Right, Center
- };
-#endif
-
enum CombiningClass
{
Combining_BelowLeftAttached = 200,
@@ -456,20 +449,6 @@ public:
inline Category category() const noexcept { return QChar::category(ucs); }
inline Direction direction() const noexcept { return QChar::direction(ucs); }
inline JoiningType joiningType() const noexcept { return QChar::joiningType(ucs); }
-#if QT_DEPRECATED_SINCE(5, 3)
- QT_DEPRECATED inline Joining joining() const noexcept
- {
- switch (QChar::joiningType(ucs)) {
- case QChar::Joining_Causing: return QChar::Center;
- case QChar::Joining_Dual: return QChar::Dual;
- case QChar::Joining_Right: return QChar::Right;
- case QChar::Joining_None:
- case QChar::Joining_Left:
- case QChar::Joining_Transparent:
- default: return QChar::OtherJoining;
- }
- }
-#endif
inline unsigned char combiningClass() const noexcept { return QChar::combiningClass(ucs); }
inline QChar mirroredChar() const noexcept { return QChar(QChar::mirroredChar(ucs)); }
@@ -488,17 +467,10 @@ public:
inline UnicodeVersion unicodeVersion() const noexcept { return QChar::unicodeVersion(ucs); }
-#if QT_DEPRECATED_SINCE(5, 0)
- QT_DEPRECATED Q_DECL_CONSTEXPR inline char toAscii() const noexcept { return toLatin1(); }
-#endif
Q_DECL_CONSTEXPR inline char toLatin1() const noexcept { return ucs > 0xff ? '\0' : char(ucs); }
Q_DECL_CONSTEXPR inline char16_t unicode() const noexcept { return ucs; }
Q_DECL_RELAXED_CONSTEXPR inline char16_t &unicode() noexcept { return ucs; }
-#if QT_DEPRECATED_SINCE(5, 0)
- QT_DEPRECATED static Q_DECL_CONSTEXPR inline QChar fromAscii(char c) noexcept
- { return fromLatin1(c); }
-#endif
static Q_DECL_CONSTEXPR QChar fromLatin1(char c) noexcept { return QLatin1Char(c); }
Q_DECL_CONSTEXPR inline bool isNull() const noexcept { return ucs == 0; }
@@ -566,9 +538,6 @@ public:
static Category QT_FASTCALL category(char32_t ucs4) noexcept Q_DECL_CONST_FUNCTION;
static Direction QT_FASTCALL direction(char32_t ucs4) noexcept Q_DECL_CONST_FUNCTION;
static JoiningType QT_FASTCALL joiningType(char32_t ucs4) noexcept Q_DECL_CONST_FUNCTION;
-#if QT_DEPRECATED_SINCE(5, 3)
- QT_DEPRECATED static Joining QT_FASTCALL joining(char32_t ucs4) noexcept Q_DECL_CONST_FUNCTION;
-#endif
static unsigned char QT_FASTCALL combiningClass(char32_t ucs4) noexcept Q_DECL_CONST_FUNCTION;
static char32_t QT_FASTCALL mirroredChar(char32_t ucs4) noexcept Q_DECL_CONST_FUNCTION;