]> git.saurik.com Git - apple/icu.git/blob - icuSources/layout/ScriptAndLanguage.h
ICU-6.2.22.tar.gz
[apple/icu.git] / icuSources / layout / ScriptAndLanguage.h
1 /*
2 *
3 * (C) Copyright IBM Corp. 1998-2004 - All Rights Reserved
4 *
5 */
6
7 #ifndef __SCRIPTANDLANGUAGE_H
8 #define __SCRIPTANDLANGUAGE_H
9
10 /**
11 * \file
12 * \internal
13 */
14
15 #include "LETypes.h"
16 #include "OpenTypeTables.h"
17
18 U_NAMESPACE_BEGIN
19
20 typedef TagAndOffsetRecord LangSysRecord;
21
22 struct LangSysTable
23 {
24 Offset lookupOrderOffset;
25 le_uint16 reqFeatureIndex;
26 le_uint16 featureCount;
27 le_uint16 featureIndexArray[ANY_NUMBER];
28 };
29
30 struct ScriptTable
31 {
32 Offset defaultLangSysTableOffset;
33 le_uint16 langSysCount;
34 LangSysRecord langSysRecordArray[ANY_NUMBER];
35
36 const LangSysTable *findLanguage(LETag languageTag, le_bool exactMatch = FALSE) const;
37 };
38
39 typedef TagAndOffsetRecord ScriptRecord;
40
41 struct ScriptListTable
42 {
43 le_uint16 scriptCount;
44 ScriptRecord scriptRecordArray[ANY_NUMBER];
45
46 const ScriptTable *findScript(LETag scriptTag) const;
47 const LangSysTable *findLanguage(LETag scriptTag, LETag languageTag, le_bool exactMatch = FALSE) const;
48 };
49
50 U_NAMESPACE_END
51 #endif
52