1 /****************************************************************************
3 ** Copyright (C) 2012 Nokia Corporation and/or its subsidiary(-ies).
4 ** Contact: http://www.qt-project.org/
6 ** This file is part of the QtCore module of the Qt Toolkit.
8 ** $QT_BEGIN_LICENSE:LGPL$
9 ** GNU Lesser General Public License Usage
10 ** This file may be used under the terms of the GNU Lesser General Public
11 ** License version 2.1 as published by the Free Software Foundation and
12 ** appearing in the file LICENSE.LGPL included in the packaging of this
13 ** file. Please review the following information to ensure the GNU Lesser
14 ** General Public License version 2.1 requirements will be met:
15 ** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
17 ** In addition, as a special exception, Nokia gives you certain additional
18 ** rights. These rights are described in the Nokia Qt LGPL Exception
19 ** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
21 ** GNU General Public License Usage
22 ** Alternatively, this file may be used under the terms of the GNU General
23 ** Public License version 3.0 as published by the Free Software Foundation
24 ** and appearing in the file LICENSE.GPL included in the packaging of this
25 ** file. Please review the following information to ensure the GNU General
26 ** Public License version 3.0 requirements will be met:
27 ** http://www.gnu.org/copyleft/gpl.html.
30 ** Alternatively, this file may be used in accordance with the terms and
31 ** conditions contained in a signed written agreement between you and Nokia.
40 ****************************************************************************/
42 /* This file is autogenerated from the Unicode 5.0 database. Do not edit */
48 // This file is not part of the Qt API. It exists for the convenience
49 // of internal files. This header file may change from version to version
50 // without notice, or even be removed.
55 #ifndef QUNICODETABLES_P_H
56 #define QUNICODETABLES_P_H
58 #include <QtCore/qchar.h>
62 #define UNICODE_DATA_VERSION QChar::Unicode_5_0
64 #define UNICODE_LAST_CODEPOINT 0x10ffff
66 namespace QUnicodeTables {
69 ushort category : 8; /* 5 needed */
70 ushort line_break_class : 8; /* 6 needed */
71 ushort direction : 8; /* 5 needed */
72 ushort combiningClass : 8;
74 signed short digitValue : 6; /* 5 needed */
75 ushort unicodeVersion : 4;
76 ushort lowerCaseSpecial : 1;
77 ushort upperCaseSpecial : 1;
78 ushort titleCaseSpecial : 1;
79 ushort caseFoldSpecial : 1; /* currently unused */
80 signed short mirrorDiff : 16;
81 signed short lowerCaseDiff : 16;
82 signed short upperCaseDiff : 16;
83 signed short titleCaseDiff : 16;
84 signed short caseFoldDiff : 16;
85 ushort graphemeBreak : 8; /* 4 needed */
86 ushort wordBreak : 8; /* 4 needed */
87 ushort sentenceBreak : 8; /* 4 needed */
89 Q_CORE_EXPORT const Properties * QT_FASTCALL properties(uint ucs4);
90 Q_CORE_EXPORT const Properties * QT_FASTCALL properties(ushort ucs2);
92 // See http://www.unicode.org/reports/tr24/tr24-5.html
123 ScriptCount = Inherited,
127 CanadianAboriginal = Common,
154 SylotiNagri = Common,
162 enum { ScriptSentinel = 32 };
169 GraphemeBreakControl,
187 WordBreakExtendNumLet
198 SentenceBreakOLetter,
199 SentenceBreakNumeric,
206 // see http://www.unicode.org/reports/tr14/tr14-19.html
207 // we don't use the XX, AI and CB properties and map them to AL instead.
208 // as we don't support any EBDIC based OS'es, NL is ignored and mapped to AL as well.
209 enum LineBreakClass {
210 LineBreak_OP, LineBreak_CL, LineBreak_QU, LineBreak_GL, LineBreak_NS,
211 LineBreak_EX, LineBreak_SY, LineBreak_IS, LineBreak_PR, LineBreak_PO,
212 LineBreak_NU, LineBreak_AL, LineBreak_ID, LineBreak_IN, LineBreak_HY,
213 LineBreak_BA, LineBreak_BB, LineBreak_B2, LineBreak_ZW, LineBreak_CM,
214 LineBreak_WJ, LineBreak_H2, LineBreak_H3, LineBreak_JL, LineBreak_JV,
215 LineBreak_JT, LineBreak_SA, LineBreak_SG,
216 LineBreak_SP, LineBreak_CR, LineBreak_LF, LineBreak_BK
220 Q_CORE_EXPORT QUnicodeTables::LineBreakClass QT_FASTCALL lineBreakClass(uint ucs4);
221 inline int lineBreakClass(QChar ch)
222 { return lineBreakClass(ch.unicode()); }
224 Q_CORE_EXPORT int QT_FASTCALL script(uint ucs4);
225 inline int script(QChar ch)
226 { return script(ch.unicode()); }
228 } // namespace QUnicodeTables
232 #endif // QUNICODETABLES_P_H