*** empty log message ***
[m17n/m17n-db.git] / THAI-NORASI.flt
1 ;; THAI-NORASI.flt -- Font Layout Table for Thai (Norasi font)
2 ;; Copyright (C) 2003, 2004
3 ;;   National Institute of Advanced Industrial Science and Technology (AIST)
4 ;;   Registration Number H15PRO112
5
6 ;; This file is part of the m17n database; a sub-part of the m17n
7 ;; library.
8
9 ;; The m17n library is free software; you can redistribute it and/or
10 ;; modify it under the terms of the GNU Lesser General Public License
11 ;; as published by the Free Software Foundation; either version 2.1 of
12 ;; the License, or (at your option) any later version.
13
14 ;; The m17n library is distributed in the hope that it will be useful,
15 ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
16 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
17 ;; Lesser General Public License for more details.
18
19 ;; You should have received a copy of the GNU Lesser General Public
20 ;; License along with the m17n library; if not, write to the Free
21 ;; Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
22 ;; Boston, MA 02110-1301, USA.
23
24 ;;; <li> THAI-NORASI.flt
25 ;;;
26 ;;; For the Thai Norasi family fonts to draw Thai script.  The fonts are
27 ;;; available at:
28 ;;; <ul>
29 ;;; <li> infopage: <http://packages.debian.org/stable/x11/xfonts-thai-ttf.html>
30 ;;; </ul>
31
32 ;; 1st stage: basic composition of CVT
33 (category
34  ;; C: CONSONANT
35  ;; V: VOWEL upper and lower
36  ;; A: SARA-AM
37  ;; T: TONE
38  ;; E: else
39  (0x0E00 0x0E5F ?E)
40  (0x0E01 0x0E2E ?C)
41  (0x0E31        ?V)
42  (0x0E33        ?A)
43  (0x0E34 0x0E3A ?V)
44  (0x0E47        ?V)
45  (0x0E48 0x0E4E ?T)
46  )
47
48 (generator
49  (0
50   (cond
51    ("(C)(T)?(A)"                        ; SARA-AM -> NIKHAHIT+SARA-AA
52     (1 = 0x0E4D) (2 =) (3 0x0E32))
53    ("(C)(T)(V)?"                        ; CTV -> CVT
54     (1 =) (3 =) (2 =))
55    ("(C)(V)?(T)?"
56     (1 =) (2 =) (3 =))
57    ("[^C]"
58     [ = ]))
59   *))
60
61 (category
62  ;; C: CONSONANT tall
63  ;; c: CONSONANT normal
64  ;; d: CONSONANT deep
65  ;; V: VOWEL upper, NIKHAHIT, and YAMAKKAN
66  ;; v: VOWEL lower
67  ;; T: TONE
68  ;; E: ELSE
69  (0x0E00 0x0E5F ?E)
70  (0x0E01 0x0E2E ?c)
71  (0x0E0D 0x0E10 ?d)
72  (0x0E1B        ?C)
73  (0x0E1D        ?C)
74  (0x0E1F        ?C)
75  (0x0E2C        ?C)
76  (0x0E31        ?V)
77  (0x0E34 0x0E37 ?V)
78  (0x0E38 0x0E3A ?v)
79  (0x0E47        ?V)
80  (0x0E48 0x0E4C ?T)
81  (0x0E4D 0x0E4E ?V))
82
83 (generator
84  (0
85   (cond 
86    ("(C)(V)(T)?"
87     < (1 =) (2 vowel-upper-left) (3 tone-high-left) >)
88    ("(C)(v)?(T)?"
89     < (1 =) (2 =) (3 tone-low-left) >)
90    ("([cd])(V)(T)?"
91     < (1 =) (2 =) (3 =) >)
92    ("(c)(v)?(T)?"
93     < (1 =) (2 =) (3 tone-low) >)
94    ("(d)(v)?(T)?"
95     < (1 =) (2 vowel-deep) (3 tone-low) >)
96    ("[VvT]"
97     [ = ])
98    ("."
99     =))
100   *)
101
102  (vowel-upper-left
103   (cond
104    ((0x0E31) =)
105    ((range 0x0E34 0x0E37) 0xF701)
106    ((0x0E47) =)
107    ((0x0E4D) 0xF711)
108    ((0x0E4E) =)))
109
110  (vowel-deep
111   ((range 0x0E38 0x0E3A) 0xF718))
112
113  (tone-high-left
114   ((range 0x0E48 0x0E4C) 0xF713))
115
116  (tone-low-left
117   ((range 0x0E48 0x0E4C) 0xF705))
118
119  (tone-low
120   ((range 0x0E48 0x0E4C) 0xF70A)))
121
122 ;; Local Variables:
123 ;; mode: lisp
124 ;; End: