1 | |
2 | /* |
3 | * speechd_types.h - types for Speech Dispatcher |
4 | * |
5 | * Copyright (C) 2001, 2002, 2003 Brailcom, o.p.s. |
6 | * |
7 | * This is free software; you can redistribute it and/or modify it |
8 | * under the terms of the GNU Lesser General Public License as published by |
9 | * the Free Software Foundation; either version 2.1, or (at your option) |
10 | * any later version. |
11 | * |
12 | * This software 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 GNU |
15 | * Lesser General Public License for more details. |
16 | * |
17 | * You should have received a copy of the GNU Lesser General Public License |
18 | * along with this program. If not, see <https://www.gnu.org/licenses/>. |
19 | */ |
20 | |
21 | #ifndef SPEECHD_TYPES_H |
22 | #define SPEECHD_TYPES_H |
23 | |
24 | typedef enum { |
25 | SPD_PUNCT_ALL = 0, |
26 | SPD_PUNCT_NONE = 1, |
27 | SPD_PUNCT_SOME = 2, |
28 | SPD_PUNCT_MOST = 3 |
29 | } SPDPunctuation; |
30 | |
31 | typedef enum { |
32 | SPD_CAP_NONE = 0, |
33 | SPD_CAP_SPELL = 1, |
34 | SPD_CAP_ICON = 2 |
35 | } SPDCapitalLetters; |
36 | |
37 | typedef enum { |
38 | SPD_SPELL_OFF = 0, |
39 | SPD_SPELL_ON = 1 |
40 | } SPDSpelling; |
41 | |
42 | typedef enum { |
43 | SPD_MALE1 = 1, |
44 | SPD_MALE2 = 2, |
45 | SPD_MALE3 = 3, |
46 | SPD_FEMALE1 = 4, |
47 | SPD_FEMALE2 = 5, |
48 | SPD_FEMALE3 = 6, |
49 | SPD_CHILD_MALE = 7, |
50 | SPD_CHILD_FEMALE = 8, |
51 | SPD_UNSPECIFIED = -1 |
52 | } SPDVoiceType; |
53 | |
54 | typedef struct { |
55 | char *name; /* Name of the voice (id) */ |
56 | char *language; /* 2/3-letter ISO language code, |
57 | * possibly followed by 2/3-letter ISO region code, |
58 | * e.g. en-US */ |
59 | char *variant; /* a not-well defined string describing dialect etc. */ |
60 | } SPDVoice; |
61 | |
62 | typedef enum { |
63 | SPD_DATA_TEXT = 0, |
64 | SPD_DATA_SSML = 1 |
65 | } SPDDataMode; |
66 | |
67 | typedef enum { |
68 | SPD_IMPORTANT = 1, |
69 | SPD_MESSAGE = 2, |
70 | SPD_TEXT = 3, |
71 | SPD_NOTIFICATION = 4, |
72 | SPD_PROGRESS = 5 |
73 | } SPDPriority; |
74 | |
75 | typedef enum { |
76 | SPD_BEGIN = 1, |
77 | SPD_END = 2, |
78 | SPD_INDEX_MARKS = 4, |
79 | SPD_CANCEL = 8, |
80 | SPD_PAUSE = 16, |
81 | SPD_RESUME = 32, |
82 | |
83 | SPD_ALL = 0x3f |
84 | } SPDNotification; |
85 | |
86 | typedef enum { |
87 | SPD_EVENT_BEGIN, |
88 | SPD_EVENT_END, |
89 | SPD_EVENT_INDEX_MARK, |
90 | SPD_EVENT_CANCEL, |
91 | SPD_EVENT_PAUSE, |
92 | SPD_EVENT_RESUME |
93 | } SPDNotificationType; |
94 | |
95 | typedef enum { |
96 | SORT_BY_TIME = 0, |
97 | SORT_BY_ALPHABET = 1 |
98 | } ESort; |
99 | |
100 | typedef enum { |
101 | SPD_MSGTYPE_TEXT = 0, |
102 | SPD_MSGTYPE_SOUND_ICON = 1, |
103 | SPD_MSGTYPE_CHAR = 2, |
104 | SPD_MSGTYPE_KEY = 3, |
105 | SPD_MSGTYPE_SPELL = 99 |
106 | } SPDMessageType; |
107 | |
108 | typedef struct { |
109 | signed int rate; |
110 | signed int pitch; |
111 | signed int pitch_range; |
112 | signed int volume; |
113 | |
114 | SPDPunctuation punctuation_mode; |
115 | SPDSpelling spelling_mode; |
116 | SPDCapitalLetters cap_let_recogn; |
117 | |
118 | SPDVoiceType voice_type; |
119 | SPDVoice voice; |
120 | } SPDMsgSettings; |
121 | |
122 | #endif /* not ifndef SPEECHD_TYPES */ |
123 | |