# This table contains braille codes and rules for Bengali  script.
#
# Copyright (C) 2014 National Institute for Visually Handicapped, 116, Rajpur Road, Dehradun, Uttrakhand, India
#
# This file is part of liblouis.
#
# liblouis is free software: you can redistribute it and/or modify it
# under the terms of the GNU Lesser General Public License as
# published by the Free Software Foundation, either version 2.1 of the
# License, or (at your option) any later version.
#
# liblouis is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
# Lesser General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public
# License along with liblouis. If not, see
# <http://www.gnu.org/licenses/>.

# This table is built and maintained under an activity of Braille Council of India
# Contributors: Dipendra Manocha, Sreeja, Dinesh Kaushal, Mesar Hameed
# Last updated on May 5, 2014
# To report any bugs or any suggestion, please write to d@saksham.org and sreeja.param@gmail.com

include braille-patterns.cti

letter   \x0981	3	# Bengali Sign Candrabindu
letter   \x0982	56	# Bengali Sign Anusvara
letter   \x0983	6	# Bengali Sign Visarga
letter   \x0985	1	# Bengali Letter A
letter   \x0986	345	# Bengali Letter AA
letter   \x0987	24	# Bengali Letter I
letter   \x0988	35	# Bengali Letter II
letter   \x0989	136	# Bengali Letter U
letter   \x098A	1256	# Bengali Letter UU
letter   \x098B	5-1235	# Bengali Letter Vocalic R
letter   \x098C	5-123	# Bengali Letter Vocalic L
letter   \x098F	15	# Bengali Letter E
letter   \x0990	34	# Bengali Letter AI
letter   \x0993	135	# Bengali Letter O
letter   \x0994	246	# Bengali Letter AU

# Consonents

letter   \x0995	13	# Bengali Letter KA
letter   \x0996	46	# Bengali Letter KHA
letter   \x0997	1245	# Bengali Letter GA
letter   \x0998	126	# Bengali Letter GHA
letter   \x0999	346	# Bengali Letter NGA

letter   \x099A	14	# Bengali Letter CA
letter   \x099B	16	# Bengali Letter CHA
letter   \x099C	245	# Bengali Letter JA
letter   \x099D	356	# Bengali Letter JHA
letter   \x099E	25	# Bengali Letter NYA

letter   \x099F	23456	# Bengali Letter TTA
letter   \x09A0	2456	# Bengali Letter TTHA
letter   \x09A1	1246	# Bengali Letter DDA
letter   \x09A2	123456	# Bengali Letter DDHA
letter   \x09A3	3456	# Bengali Letter NNA

letter   \x09A4	2345	# Bengali Letter TA
letter   \x09A5	1456	# Bengali Letter THA
letter   \x09A6	145	# Bengali Letter DA
letter   \x09A7	2346	# Bengali Letter DHA
letter   \x09A8	1345	# Bengali Letter NA

letter   \x09AA	1234	# Bengali Letter PA
letter   \x09AB	235	# Bengali Letter PHA
letter   \x09AC	12	# Bengali Letter BA = Bengali va, wa
letter   \x09AD	45	# Bengali Letter BHA
letter   \x09AE	134	# Bengali Letter MA
letter   \x09AF	13456	# Bengali Letter YA
letter   \x09B0	1235	# Bengali Letter RA
letter   \x09B2	123	# Bengali Letter LA
letter   \x09B6	146	# Bengali Letter SHA
letter   \x09B7	12346	# Bengali Letter SSA
letter   \x09B8	234	# Bengali Letter SA
letter   \x09B9	125	# Bengali Letter HA

letter   \x09BD	2	# Bengali Sign Avagraha

# vowel sign

letter   \x09BE	345	# Bengali vowel sign AA
letter   \x09BF	24	# Bengali vowel sign I (Stands To The Left Of The Consonant)
letter   \x09C0	35	# Bengali vowel sign II
letter   \x09C1	136	# Bengali vowel sign U
letter   \x09C2	1256	# Bengali vowel sign UU                                                
letter   \x09C3	5-1235	# Bengali vowel sign VOCALIC R
letter   \x09C4	6-1235	# Bengali vowel sign VOCALIC RR
letter   \x09C7	15	# Bengali vowel sign E (stands to the left of the consonant)
letter   \x09C8	34	# Bengali vowel sign AI (stands to the left of the consonant)
letter   \x09CB	135	# Bengali vowel sign O = 09C7 and 09BE
letter   \x09CC	246	# Bengali vowel sign AU = 09C7 and 09D7

letter   \x09CD	  4	# Bengali sign VIRAMA

letter   \x09CE   4-2345    # Bengali letter Khanda TA (a dead consonant form of ta, without implicit vowel, used in some     sequences)
letter   \x09DC	12456	# Bengali letter RRA =   09A1 and 09BC
letter   \x09DD	5-12456	# BENGALI LETTER RHA =  09A2 AND  09BC
letter   \x09DF	26	# BENGALI LETTER YYA =  09AF AND   09BC

letter   \x09E0	6-1235	# BENGALI LETTER VOCALIC RR
letter   \x09E1	6-123	# BENGALI LETTER VOCALIC LL
letter   \x09E2	5-123	# BENGALI LETTER VOCALIC L
letter   \x09E3	6-123	# BENGALIC LETTER VOCALIC LL

# Digits

litdigit   \x09E6	245	# BENGALI DIGIT ZERO
litdigit   \x09E7	1	# BENGALI DIGIT ONE
litdigit   \x09E8	12	# BENGALI DIGIT TWO
litdigit   \x09E9	14	# BENGALI DIGIT THREE
litdigit   \x09EA	145	# BENGALI DIGIT FOUR
litdigit   \x09EB	15	# BENGALI DIGIT FIVE
litdigit   \x09EC	124	# BENGALI DIGIT SIX
litdigit  \x09ED	1245	# BENGALI DIGIT SEVEN
litdigit   \x09EE	125	# BENGALI DIGIT EIGHT
litdigit  \x09EF	24	# BENGALI DIGIT NINE

letter     \x09F0	1235	# BENGALI LETTER RA WITH MIDDLE DIAGONAL (ASSAMESE)
letter    \x09F1    1236	# BENGALI LETTER RA WITH LOWER DIAGONAL =  BENGALI LETTER VA WITH LOWER DIAGONAL (1.0) ASSAMESE

replace \X200D

# Half characters 
always	\x0995\x09cD   	4-13	# Bengali Letter KA
always	\x0996\x09cD   	4-46	# Bengali Letter KHA
always	\x0997\x09cD   	4-1245	# Bengali Letter GA
always	\x0998\x09cD   	4-126	# Bengali Letter GHA
always	\x0999\x09cD   	4-346	# Bengali Letter NGA

always	\x099A\x09cD   	4-14	# Bengali Letter CA
always	\x099B\x09cD   	4-16	# Bengali Letter CHA
always	\x099C\x09cD   	4-245	# Bengali Letter JA
always	\x099D\x09cD   	4-356	# Bengali Letter JHA
always	\x099E\x09cD   	4-25	# Bengali Letter NYA

always	\x099F\x09cD   	4-23456	# Bengali Letter TTA
always	\x09A0\x09cD   	4-2456	# Bengali Letter TTHA
always	\x09A1\x09cD   	4-1246	# Bengali Letter DDA
always	\x09A2\x09cD   	4-123456	# Bengali Letter DDHA
always	\x09A3\x09cD   	4-3456	# Bengali Letter NNA

always	\x09A4\x09cD   	4-2345	# Bengali Letter TA
always	\x09A5\x09cD   	4-1456	# Bengali Letter THA
always	\x09A6\x09cD   	4-145	# Bengali Letter DA
always	\x09A7\x09cD   	4-2346	# Bengali Letter DHA
always	\x09A8\x09cD   	4-1345	# Bengali Letter NA

always	\x09AA\x09cD   	4-1234	# Bengali Letter PA
always	\x09AB\x09cD   	4-235	# Bengali Letter PHA
always	\x09AC\x09cD   	4-12	# Bengali Letter BA =  Bengali va, wa
always	\x09AD\x09cD   	4-45	# Bengali Letter BHA
always	\x09AE\x09cD   	4-134	# Bengali Letter MA

always	\x09AF\x09cD   	4-13456	# Bengali Letter YA
always	\x09B0\x09cD   	4-1235	# Bengali Letter RA
always	\x09B2\x09cD   	4-123	# Bengali Letter LA
always	\x09B6\x09cD   	4-146	# Bengali Letter SHA
always	\x09B7\x09cD   	4-12346	# Bengali Letter SSA
always	\x09B8\x09cD   	4-234	# Bengali Letter SA
always	\x09B9\x09cD   	4-125	# Bengali Letter HA


always	\x09C4\x09cD   	4-6-1235	# Bengali vowel sign VOCALIC RR
always	\x09CE\x09cD   	4-4-2345	# Bengali letter Khanda TA (a dead consonant form of ta, without implicit vowel, used in some sequences)
always	\x09DC\x09cD   	4-12456	# Bengali letter RRA = 09A1 and 09BC
always	\x09DF\x09cD   	4-26	# BENGALI LETTER YYA = 09AF AND 09BC
always	\x09E0\x09cD   	4-6-1235	# BENGALI LETTER VOCALIC RR
always	\x09E1\x09cD   	4-6-123	# BENGALI LETTER VOCALIC LL
always	\x09E2\x09cD   	4-5-123	# BENGALI LETTER VOCALIC L
always	\x09E3\x09cD   	4-6-123	# BENGALIC LETTER VOCALIC LL
always	\x09F0\x09cD   	4-1235	# BENGALI LETTER RA WITH MIDDLE DIAGONAL (ASSAMESE)
always	\x09F1\x09cD   	4-1236	# BENGALI LETTER RA WITH LOWER DIAGONAL =  BENGALI LETTER VA WITH LOWER DIAGONAL (1.0) ASSAMESE

 # ksha and gya


 
 always \x0995\x09CD\x09B7\x09CD 4-12345 #"ksha"
 always \x099C\x09CD\x099E  156 #"gyan"
 always \x0995\x09CD\x09B7 12345 #"ksha"
 
   # consonent followed by vowel but not matra
   
   class BengaliVowel \x0985\x0986\x0987\x0988\x0989\x0985\x098A\x098B\x098C\x098F\x0990\x0993\x0994
   class HALANT \x09CD
   
   


before BengaliVowel always \x0995 13-1 # Bengali ka
before BengaliVowel always \x0996 46-1 # Bengali kha
before BengaliVowel always \x0997 1245-1 # Bengali ga
before BengaliVowel always \x0998 126-1 # Bengali gha

#before HALANT always \x0995  4-13 # Bengali ka

before BengaliVowel always \x099A 14-1 # Bengali ca
before BengaliVowel always \x099B 16-1 # Bengali cha
before BengaliVowel always \x099C 245-1 # Bengali ja
before BengaliVowel always \x099D 356-1 # Bengali jha

before BengaliVowel always \x099F 23456-1 # Bengali ta
before BengaliVowel always \x09A0 2456-1 # Bengali tha
before BengaliVowel always \x09A1 1246-1 # Bengali da
before BengaliVowel always \x09A2 123456-1 # Bengali dha
before BengaliVowel always \x09A3 3456-1 #Bengali nna

before BengaliVowel always \x09A4 2345-1 # Bengali ta
before BengaliVowel always \x09A5 1456-1 # Bengali tha
before BengaliVowel always \x09A6 145-1 # Bengali da
before BengaliVowel always \x09A7 2346-1 # Bengali dha
before BengaliVowel always \x09A8 1345-1 #Bengali na

before BengaliVowel always \x09AA 1234-1 # Bengali pa
before BengaliVowel always \x09AB 235-1 # Bengali pha
before BengaliVowel always \x09AC 12-1 # Bengali ba
before BengaliVowel always \x09AD 45-1 # Bengali bha
before BengaliVowel always \x09AE 134-1 #Bengali ma

before BengaliVowel always \x09AF 13456-1 # Bengali yaa
before BengaliVowel always \x09B0 1235-1 # Bengali ra
before BengaliVowel always \x09B2 123-1 # Bengali la
before BengaliVowel always \x09B6 146-1 #Bengali sha
before BengaliVowel always \x09B7 12346-1 #Bengali ssha
before BengaliVowel always \x09B8 234-1 #Bengali sa
before BengaliVowel always \x09B9 125-1 #Bengali ha

 before BengaliVowel always	\x09C4 	6-1235-1	# Bengali vowel sign VOCALIC RR
 before BengaliVowel always	\x09CE 	2345-1	# Bengali letter Khanda TA (a dead consonant form of ta, without implicit vowel, used in some sequences)
 before BengaliVowel always	\x09DC 	12456-1	# Bengali letter RRA = 09A1 and 09BC
 before BengaliVowel always	\x09DF 	26-1	# BENGALI LETTER YYA = 09AF AND 09BC
 before BengaliVowel always	\x09E0 	6-1235-1	# BENGALI LETTER VOCALIC RR
 before BengaliVowel always	\x09E1 	6-123-1	# BENGALI LETTER VOCALIC LL
 before BengaliVowel always	\x09E3 	6-123-1	# BENGALIC LETTER VOCALIC LL
 before BengaliVowel always	\x09F0 	1235-1	# BENGALI LETTER RA WITH MIDDLE DIAGONAL (ASSAMESE)
 before BengaliVowel always	\x09F1 	1236-1	# BENGALI LETTER RA WITH LOWER DIAGONAL =  BENGALI LETTER VA WITH LOWER DIAGONAL (1.0) ASSAMESE
