20#include <QtCore/private/qglobal_p.h>
24#if QT_CONFIG(icu) || defined(Q_OS_ANDROID)
25#include <unicode/ucol.h>
26#elif defined(Q_OS_MACOS)
27#include <CoreServices/CoreServices.h>
28#elif defined(Q_OS_WIN)
29#include <qt_windows.h>
32#include "qjniobject.h"
38#if QT_CONFIG(icu) || defined(Q_OS_ANDROID)
39typedef UCollator *CollatorType;
40typedef QByteArray CollatorKeyType;
41const CollatorType NoCollator =
nullptr;
43#elif defined(Q_OS_MACOS)
44typedef CollatorRef CollatorType;
45typedef QList<UCCollationValue> CollatorKeyType;
46const CollatorType NoCollator = 0;
48#elif defined(Q_OS_WIN)
49typedef QByteArray CollatorKeyType;
50typedef int CollatorType;
51const CollatorType NoCollator = 0;
54typedef QList<
wchar_t> CollatorKeyType;
60Q_DECLARE_JNI_CLASS(QtCollator,
"org/qtproject/qt/android/QtCollator")
61Q_DECLARE_JNI_CLASS(Collator,
"android/icu/text/Collator")
82 bool isC()
const {
return locale.language() == QLocale::C; }
QCollatorPrivate(const QLocale &locale)
static QCollatorSortKey sortKeyFromData(CollatorKeyType &&data)
QCollatorSortKeyPrivate(CollatorKeyType &&list)
Combined button and popup list for selecting options.
const CollatorType NoCollator
GenerationalCollator(const QCollator ©)
GenerationalCollator()=default