forked from GitHub/gf-core
Telugu transliteration
This commit is contained in:
@@ -450,6 +450,7 @@ allCommands enc pgf = Map.fromList [
|
|||||||
options = [
|
options = [
|
||||||
("arabic", "Arabic"),
|
("arabic", "Arabic"),
|
||||||
("devanagari","Devanagari"),
|
("devanagari","Devanagari"),
|
||||||
|
("telugu", "Telugu"),
|
||||||
("thai", "Thai")
|
("thai", "Thai")
|
||||||
]
|
]
|
||||||
}),
|
}),
|
||||||
@@ -594,6 +595,7 @@ stringOpOptions = [
|
|||||||
("from_cp1251","decode from cp1251 (Cyrillic used in Bulgarian resource)"),
|
("from_cp1251","decode from cp1251 (Cyrillic used in Bulgarian resource)"),
|
||||||
("from_arabic","from unicode to GF Arabic transliteration"),
|
("from_arabic","from unicode to GF Arabic transliteration"),
|
||||||
("from_devanagari","from unicode to GF Devanagari transliteration"),
|
("from_devanagari","from unicode to GF Devanagari transliteration"),
|
||||||
|
("from_thai","from unicode to GF Telugu transliteration"),
|
||||||
("from_thai","from unicode to GF Thai transliteration"),
|
("from_thai","from unicode to GF Thai transliteration"),
|
||||||
("from_utf8","decode from utf8"),
|
("from_utf8","decode from utf8"),
|
||||||
("lextext","text-like lexer"),
|
("lextext","text-like lexer"),
|
||||||
@@ -603,6 +605,7 @@ stringOpOptions = [
|
|||||||
("to_arabic","from GF Arabic transliteration to unicode"),
|
("to_arabic","from GF Arabic transliteration to unicode"),
|
||||||
("to_devanagari","from GF Devanagari transliteration to unicode"),
|
("to_devanagari","from GF Devanagari transliteration to unicode"),
|
||||||
("to_html","wrap in a html file with linebreaks"),
|
("to_html","wrap in a html file with linebreaks"),
|
||||||
|
("to_telugu","from GF Telugu transliteration to unicode"),
|
||||||
("to_thai","from GF Thai transliteration to unicode"),
|
("to_thai","from GF Thai transliteration to unicode"),
|
||||||
("to_utf8","encode to utf8"),
|
("to_utf8","encode to utf8"),
|
||||||
("unlextext","text-like unlexer"),
|
("unlextext","text-like unlexer"),
|
||||||
|
|||||||
@@ -27,6 +27,7 @@ transliteration :: String -> Maybe Transliteration
|
|||||||
transliteration s = case s of
|
transliteration s = case s of
|
||||||
"arabic" -> Just transArabic
|
"arabic" -> Just transArabic
|
||||||
"devanagari" -> Just transDevanagari
|
"devanagari" -> Just transDevanagari
|
||||||
|
"telugu" -> Just transTelugu
|
||||||
"thai" -> Just transThai
|
"thai" -> Just transThai
|
||||||
---- "urdu" -> Just transUrdu
|
---- "urdu" -> Just transUrdu
|
||||||
_ -> Nothing
|
_ -> Nothing
|
||||||
@@ -114,3 +115,15 @@ transArabic = mkTransliteration allTrans allCodes where
|
|||||||
allCodes = [0x0621..0x062f] ++ [0x0630..0x063a] ++
|
allCodes = [0x0621..0x062f] ++ [0x0630..0x063a] ++
|
||||||
[0x0641..0x064f] ++ [0x0650..0x0657]
|
[0x0641..0x064f] ++ [0x0650..0x0657]
|
||||||
|
|
||||||
|
transTelugu :: Transliteration
|
||||||
|
transTelugu = mkTransliteration allTrans allCodes where
|
||||||
|
allTrans = words $
|
||||||
|
"- c1 c2 c3 - A A: I I: U U: R_ L_ - E E: " ++
|
||||||
|
"A' - O O: A_ k k. g g. n. c c. j j. n' T " ++
|
||||||
|
"T. d d. N t t. d d. n - p p. b b. m y " ++
|
||||||
|
"r R l L - v s' S s h - - - c5 a: i " ++
|
||||||
|
"i: u u: r_ r. - e e: a' - o o: a_ c6 - - " ++
|
||||||
|
"- - - - - c7 c8 z Z - - - - - - - " ++
|
||||||
|
"R+ L+ l+ l* - - n0 n1 n2 n3 n4 n5 n6 n7 n8 n9 "
|
||||||
|
allCodes = [0x0c00 .. 0x0c7f]
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user