eSpeak NG is an open source speech synthesizer that supports more than hundred languages and accents.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

tostring.cpp 4.6KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187
  1. /* Enumeration types to string.
  2. *
  3. * Copyright (C) 2012-2013 Reece H. Dunn
  4. *
  5. * This file is part of ucd-tools.
  6. *
  7. * ucd-tools is free software: you can redistribute it and/or modify
  8. * it under the terms of the GNU General Public License as published by
  9. * the Free Software Foundation, either version 3 of the License, or
  10. * (at your option) any later version.
  11. *
  12. * ucd-tools is distributed in the hope that it will be useful,
  13. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  14. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  15. * GNU General Public License for more details.
  16. *
  17. * You should have received a copy of the GNU General Public License
  18. * along with ucd-tools. If not, see <http://www.gnu.org/licenses/>.
  19. */
  20. #include "ucd/ucd.h"
  21. const char *ucd::get_category_group_string(category_group c)
  22. {
  23. switch (c)
  24. {
  25. case C: return "C";
  26. case I: return "I";
  27. case L: return "L";
  28. case M: return "M";
  29. case N: return "N";
  30. case P: return "P";
  31. case S: return "S";
  32. case Z: return "Z";
  33. default: return "-";
  34. }
  35. }
  36. const char *ucd::get_category_string(category c)
  37. {
  38. switch (c)
  39. {
  40. case Cc: return "Cc";
  41. case Cf: return "Cf";
  42. case Cn: return "Cn";
  43. case Co: return "Co";
  44. case Cs: return "Cs";
  45. case Ii: return "Ii";
  46. case Ll: return "Ll";
  47. case Lm: return "Lm";
  48. case Lo: return "Lo";
  49. case Lt: return "Lt";
  50. case Lu: return "Lu";
  51. case Mc: return "Mc";
  52. case Me: return "Me";
  53. case Mn: return "Mn";
  54. case Nd: return "Nd";
  55. case Nl: return "Nl";
  56. case No: return "No";
  57. case Pc: return "Pc";
  58. case Pd: return "Pd";
  59. case Pe: return "Pe";
  60. case Pf: return "Pf";
  61. case Pi: return "Pi";
  62. case Po: return "Po";
  63. case Ps: return "Ps";
  64. case Sc: return "Sc";
  65. case Sk: return "Sk";
  66. case Sm: return "Sm";
  67. case So: return "So";
  68. case Zl: return "Zl";
  69. case Zp: return "Zp";
  70. case Zs: return "Zs";
  71. default: return "--";
  72. }
  73. }
  74. const char *ucd::get_script_string(script s)
  75. {
  76. switch (s)
  77. {
  78. case Arab: return "Arab";
  79. case Armi: return "Armi";
  80. case Armn: return "Armn";
  81. case Avst: return "Avst";
  82. case Bali: return "Bali";
  83. case Bamu: return "Bamu";
  84. case Batk: return "Batk";
  85. case Beng: return "Beng";
  86. case Bopo: return "Bopo";
  87. case Brah: return "Brah";
  88. case Brai: return "Brai";
  89. case Bugi: return "Bugi";
  90. case Buhd: return "Buhd";
  91. case Cans: return "Cans";
  92. case Cari: return "Cari";
  93. case Cakm: return "Cakm";
  94. case Cham: return "Cham";
  95. case Cher: return "Cher";
  96. case Copt: return "Copt";
  97. case Cprt: return "Cprt";
  98. case Cyrl: return "Cyrl";
  99. case Deva: return "Deva";
  100. case Dsrt: return "Dsrt";
  101. case Egyp: return "Egyp";
  102. case Ethi: return "Ethi";
  103. case Geor: return "Geor";
  104. case Glag: return "Glag";
  105. case Goth: return "Goth";
  106. case Grek: return "Grek";
  107. case Gujr: return "Gujr";
  108. case Guru: return "Guru";
  109. case Hang: return "Hang";
  110. case Hano: return "Hano";
  111. case Hant: return "Hant";
  112. case Hebr: return "Hebr";
  113. case Hira: return "Hira";
  114. case Ital: return "Ital";
  115. case Java: return "Java";
  116. case Kali: return "Kali";
  117. case Kana: return "Kana";
  118. case Khar: return "Khar";
  119. case Khmr: return "Khmr";
  120. case Knda: return "Knda";
  121. case Kthi: return "Kthi";
  122. case Lana: return "Lana";
  123. case Laoo: return "Laoo";
  124. case Latn: return "Latn";
  125. case Lepc: return "Lepc";
  126. case Limb: return "Limb";
  127. case Linb: return "Linb";
  128. case Lisu: return "Lisu";
  129. case Lyci: return "Lyci";
  130. case Lydi: return "Lydi";
  131. case Mand: return "Mand";
  132. case Merc: return "Merc";
  133. case Mero: return "Mero";
  134. case Mlym: return "Mlym";
  135. case Mong: return "Mong";
  136. case Mtei: return "Mtei";
  137. case Mymr: return "Mymr";
  138. case Nkoo: return "Nkoo";
  139. case Ogam: return "Ogam";
  140. case Olck: return "Olck";
  141. case Orkh: return "Orkh";
  142. case Orya: return "Orya";
  143. case Osma: return "Osma";
  144. case Phag: return "Phag";
  145. case Phli: return "Phli";
  146. case Phnx: return "Phnx";
  147. case Plrd: return "Plrd";
  148. case Prti: return "Prti";
  149. case Qaak: return "Qaak";
  150. case Rjng: return "Rjng";
  151. case Runr: return "Runr";
  152. case Samr: return "Samr";
  153. case Sarb: return "Sarb";
  154. case Saur: return "Saur";
  155. case Shaw: return "Shaw";
  156. case Shrd: return "Shrd";
  157. case Sinh: return "Sinh";
  158. case Sora: return "Sora";
  159. case Sund: return "Sund";
  160. case Sylo: return "Sylo";
  161. case Syrn: return "Syrn";
  162. case Tagb: return "Tagb";
  163. case Takr: return "Takr";
  164. case Tale: return "Tale";
  165. case Talu: return "Talu";
  166. case Taml: return "Taml";
  167. case Tavt: return "Tavt";
  168. case Telu: return "Telu";
  169. case Tfng: return "Tfng";
  170. case Tglg: return "Tglg";
  171. case Thaa: return "Thaa";
  172. case Thai: return "Thai";
  173. case Tibt: return "Tibt";
  174. case Ugar: return "Ugar";
  175. case Vaii: return "Vaii";
  176. case Xpeo: return "Xpeo";
  177. case Xsux: return "Xsux";
  178. case Yiii: return "Yiii";
  179. case Zyyy: return "Zyyy";
  180. case Zzzz: return "Zzzz";
  181. default: return "----";
  182. }
  183. }