melder_enums.h 6.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123
  1. /* melder_enums.h
  2. *
  3. * Copyright (C) 2007,2013,2015,2016,2018 Paul Boersma
  4. *
  5. * This code is free software; you can redistribute it and/or modify
  6. * it under the terms of the GNU General Public License as published by
  7. * the Free Software Foundation; either version 2 of the License, or (at
  8. * your option) any later version.
  9. *
  10. * This code is distributed in the hope that it will be useful, but
  11. * WITHOUT ANY WARRANTY; without even the implied warranty of
  12. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  13. * See the GNU General Public License for more details.
  14. *
  15. * You should have received a copy of the GNU General Public License
  16. * along with this work. If not, see <http://www.gnu.org/licenses/>.
  17. */
  18. enums_begin (kMelder_number, 1)
  19. enums_add (kMelder_number, 1, EQUAL_TO, U"equal to")
  20. enums_add (kMelder_number, 2, NOT_EQUAL_TO, U"not equal to")
  21. enums_add (kMelder_number, 3, LESS_THAN, U"less than")
  22. enums_add (kMelder_number, 4, LESS_THAN_OR_EQUAL_TO, U"less than or equal to")
  23. enums_add (kMelder_number, 5, GREATER_THAN, U"greater than")
  24. enums_add (kMelder_number, 6, GREATER_THAN_OR_EQUAL_TO, U"greater than or equal to")
  25. enums_end (kMelder_number, 6, EQUAL_TO)
  26. enums_begin (kMelder_string, 1)
  27. enums_add (kMelder_string, 1, EQUAL_TO, U"is equal to")
  28. enums_add (kMelder_string, 2, NOT_EQUAL_TO, U"is not equal to")
  29. enums_add (kMelder_string, 3, CONTAINS, U"contains")
  30. enums_add (kMelder_string, 4, DOES_NOT_CONTAIN, U"does not contain")
  31. enums_add (kMelder_string, 5, STARTS_WITH, U"starts with")
  32. enums_add (kMelder_string, 6, DOES_NOT_START_WITH, U"does not start with")
  33. enums_add (kMelder_string, 7, ENDS_WITH, U"ends with")
  34. enums_add (kMelder_string, 8, DOES_NOT_END_WITH, U"does not end with")
  35. enums_add (kMelder_string, 9, CONTAINS_WORD, U"contains a word equal to")
  36. enums_add (kMelder_string, 10, DOES_NOT_CONTAIN_WORD, U"does not contain a word equal to")
  37. enums_add (kMelder_string, 11, CONTAINS_WORD_STARTING_WITH, U"contains a word starting with")
  38. enums_add (kMelder_string, 12, DOES_NOT_CONTAIN_WORD_STARTING_WITH, U"does not contain a word starting with")
  39. enums_add (kMelder_string, 13, CONTAINS_WORD_ENDING_WITH, U"contains a word ending with")
  40. enums_add (kMelder_string, 14, DOES_NOT_CONTAIN_WORD_ENDING_WITH, U"does not contain a word ending with")
  41. enums_add (kMelder_string, 15, CONTAINS_INK, U"contains ink equal to")
  42. enums_add (kMelder_string, 16, DOES_NOT_CONTAIN_INK, U"does not contain ink equal to")
  43. enums_add (kMelder_string, 17, CONTAINS_INK_STARTING_WITH, U"contains ink starting with")
  44. enums_add (kMelder_string, 18, DOES_NOT_CONTAIN_INK_STARTING_WITH, U"does not contain ink starting with")
  45. enums_add (kMelder_string, 19, CONTAINS_INK_ENDING_WITH, U"contains ink ending with")
  46. enums_add (kMelder_string, 20, DOES_NOT_CONTAIN_INK_ENDING_WITH, U"does not contain ink ending with")
  47. enums_add (kMelder_string, 21, MATCH_REGEXP, U"matches (regex)")
  48. enums_end (kMelder_string, 21, EQUAL_TO)
  49. enums_begin (kMelder_textInputEncoding, 1)
  50. enums_add (kMelder_textInputEncoding, 1, UTF8, U"UTF-8")
  51. enums_add (kMelder_textInputEncoding, 2, UTF8_THEN_ISO_LATIN1, U"try UTF-8, then ISO Latin-1")
  52. enums_add (kMelder_textInputEncoding, 3, ISO_LATIN1, U"ISO Latin-1")
  53. enums_add (kMelder_textInputEncoding, 4, UTF8_THEN_WINDOWS_LATIN1, U"try UTF-8, then Windows Latin-1")
  54. enums_add (kMelder_textInputEncoding, 5, WINDOWS_LATIN1, U"Windows Latin-1")
  55. enums_add (kMelder_textInputEncoding, 6, UTF8_THEN_MACROMAN, U"try UTF-8, then MacRoman")
  56. enums_add (kMelder_textInputEncoding, 7, MACROMAN, U"MacRoman")
  57. #if defined (_WIN32)
  58. enums_end (kMelder_textInputEncoding, 7, UTF8_THEN_WINDOWS_LATIN1)
  59. #elif defined (macintosh)
  60. enums_end (kMelder_textInputEncoding, 7, UTF8_THEN_MACROMAN)
  61. #else
  62. enums_end (kMelder_textInputEncoding, 7, UTF8_THEN_ISO_LATIN1)
  63. #endif
  64. enums_begin (kMelder_textOutputEncoding, 1)
  65. enums_add (kMelder_textOutputEncoding, 1, UTF8, U"UTF-8")
  66. enums_add (kMelder_textOutputEncoding, 2, UTF16, U"UTF-16")
  67. enums_add (kMelder_textOutputEncoding, 3, ASCII_THEN_UTF16, U"try ASCII, then UTF-16")
  68. enums_add (kMelder_textOutputEncoding, 4, ISO_LATIN1_THEN_UTF16, U"try ISO Latin-1, then UTF-16")
  69. enums_end (kMelder_textOutputEncoding, 4, ASCII_THEN_UTF16)
  70. enums_begin (kMelder_asynchronicityLevel, 0)
  71. enums_add (kMelder_asynchronicityLevel, 0, SYNCHRONOUS, U"synchronous (nothing)")
  72. enums_add (kMelder_asynchronicityLevel, 1, CALLING_BACK, U"calling back (view running cursor)")
  73. enums_add (kMelder_asynchronicityLevel, 2, INTERRUPTABLE, U"interruptable (Escape key stops playing)")
  74. enums_add (kMelder_asynchronicityLevel, 3, ASYNCHRONOUS, U"asynchronous (anything)")
  75. enums_end (kMelder_asynchronicityLevel, 3, ASYNCHRONOUS)
  76. #if defined (_WIN32)
  77. enums_begin (kMelder_inputSoundSystem, 1)
  78. enums_add (kMelder_inputSoundSystem, 1, MME_VIA_PORTAUDIO, U"MME via PortAudio")
  79. enums_end (kMelder_inputSoundSystem, 1, MME_VIA_PORTAUDIO)
  80. // in order to allow recording for over 64 megabytes (paMME)
  81. enums_begin (kMelder_outputSoundSystem, 1)
  82. enums_add (kMelder_outputSoundSystem, 1, MME, U"MME")
  83. enums_add (kMelder_outputSoundSystem, 2, MME_VIA_PORTAUDIO, U"MME via PortAudio")
  84. enums_end (kMelder_outputSoundSystem, 2, MME)
  85. // in order to reduce the long latencies of paMME and to avoid the incomplete implementation of paDirectSound
  86. #elif defined (macintosh)
  87. enums_begin (kMelder_inputSoundSystem, 1)
  88. enums_add (kMelder_inputSoundSystem, 1, COREAUDIO_VIA_PORTAUDIO, U"CoreAudio via PortAudio")
  89. enums_end (kMelder_inputSoundSystem, 1, COREAUDIO_VIA_PORTAUDIO)
  90. // in order to have CoreAudio
  91. enums_begin (kMelder_outputSoundSystem, 1)
  92. enums_add (kMelder_outputSoundSystem, 1, COREAUDIO_VIA_PORTAUDIO, U"CoreAudio via PortAudio")
  93. enums_end (kMelder_outputSoundSystem, 1, COREAUDIO_VIA_PORTAUDIO)
  94. // in order to have CoreAudio
  95. #else
  96. enums_begin (kMelder_inputSoundSystem, 1)
  97. enums_add (kMelder_inputSoundSystem, 1, ALSA_VIA_PORTAUDIO, U"ALSA via PortAudio")
  98. enums_end (kMelder_inputSoundSystem, 1, ALSA_VIA_PORTAUDIO)
  99. // in order to use ALSA and therefore be compatible with Ubuntu 10.10 and later
  100. enums_begin (kMelder_outputSoundSystem, 1)
  101. enums_add (kMelder_outputSoundSystem, 1, PULSEAUDIO, U"PulseAudio")
  102. enums_add (kMelder_outputSoundSystem, 2, ALSA_VIA_PORTAUDIO, U"ALSA via PortAudio")
  103. enums_end (kMelder_outputSoundSystem, 2, PULSEAUDIO)
  104. // because we prefer to try PulseAudio directly
  105. #endif
  106. /* End of file melder_enums.h */