aboutsummaryrefslogtreecommitdiffstats
path: root/library/cpp/langs/scripts.h
blob: 4c47a33d2cb31307328101e75216c27c0ca59901 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
#pragma once

#include <util/generic/strbuf.h>

// Writing systems, a.k.a. scripts
//
enum EScript {
    SCRIPT_UNKNOWN = 0,
    SCRIPT_LATIN,
    SCRIPT_CYRILLIC,

    SCRIPT_GREEK,
    SCRIPT_ARABIC,
    SCRIPT_HEBREW,
    SCRIPT_ARMENIAN,
    SCRIPT_GEORGIAN,

    SCRIPT_HAN,
    SCRIPT_KATAKANA,
    SCRIPT_HIRAGANA,
    SCRIPT_HANGUL,

    SCRIPT_DEVANAGARI,
    SCRIPT_BENGALI,
    SCRIPT_GUJARATI,
    SCRIPT_GURMUKHI,
    SCRIPT_KANNADA,
    SCRIPT_MALAYALAM,
    SCRIPT_ORIYA,
    SCRIPT_TAMIL,
    SCRIPT_TELUGU,
    SCRIPT_THAANA,
    SCRIPT_SINHALA,

    SCRIPT_MYANMAR,
    SCRIPT_THAI,
    SCRIPT_LAO,
    SCRIPT_KHMER,
    SCRIPT_TIBETAN,
    SCRIPT_MONGOLIAN,

    SCRIPT_ETHIOPIC,
    SCRIPT_RUNIC,
    SCRIPT_COPTIC,
    SCRIPT_SYRIAC,

    SCRIPT_OTHER,
    SCRIPT_MAX
};

// According to ISO 15924 codes. See https://en.wikipedia.org/wiki/ISO_15924
//
EScript ScriptByName(const TStringBuf& name);
EScript ScriptByNameOrDie(const TStringBuf& name);
const char* IsoNameByScript(EScript script);
const char* FullNameByScript(EScript script);