1 | /**************************************************************************** |
2 | * Copyright (c) 1998-2013,2017 Free Software Foundation, Inc. * |
3 | * * |
4 | * Permission is hereby granted, free of charge, to any person obtaining a * |
5 | * copy of this software and associated documentation files (the * |
6 | * "Software"), to deal in the Software without restriction, including * |
7 | * without limitation the rights to use, copy, modify, merge, publish, * |
8 | * distribute, distribute with modifications, sublicense, and/or sell * |
9 | * copies of the Software, and to permit persons to whom the Software is * |
10 | * furnished to do so, subject to the following conditions: * |
11 | * * |
12 | * The above copyright notice and this permission notice shall be included * |
13 | * in all copies or substantial portions of the Software. * |
14 | * * |
15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS * |
16 | * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF * |
17 | * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. * |
18 | * IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, * |
19 | * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR * |
20 | * OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR * |
21 | * THE USE OR OTHER DEALINGS IN THE SOFTWARE. * |
22 | * * |
23 | * Except as contained in this notice, the name(s) of the above copyright * |
24 | * holders shall not be used in advertising or otherwise to promote the * |
25 | * sale, use or other dealings in this Software without prior written * |
26 | * authorization. * |
27 | ****************************************************************************/ |
28 | |
29 | /****************************************************************************/ |
30 | /* Author: Zeyd M. Ben-Halim <zmbenhal@netcom.com> 1992,1995 */ |
31 | /* and: Eric S. Raymond <esr@snark.thyrsus.com> */ |
32 | /* and: Thomas E. Dickey 1995-on */ |
33 | /****************************************************************************/ |
34 | |
35 | /* $Id: MKterm.h.awk.in,v 1.67 2017/04/06 00:19:26 tom Exp $ */ |
36 | |
37 | /* |
38 | ** term.h -- Definition of struct term |
39 | */ |
40 | |
41 | #ifndef NCURSES_TERM_H_incl |
42 | #define NCURSES_TERM_H_incl 1 |
43 | |
44 | #undef NCURSES_VERSION |
45 | #define NCURSES_VERSION "6.1" |
46 | |
47 | #include <ncurses_dll.h> |
48 | |
49 | #ifdef __cplusplus |
50 | extern "C" { |
51 | #endif |
52 | |
53 | /* Make this file self-contained by providing defaults for the HAVE_TERMIO[S]_H |
54 | * definition (based on the system for which this was configured). |
55 | */ |
56 | |
57 | #undef NCURSES_CONST |
58 | #define NCURSES_CONST const |
59 | |
60 | #undef NCURSES_SBOOL |
61 | #define NCURSES_SBOOL char |
62 | |
63 | #undef NCURSES_USE_DATABASE |
64 | #define NCURSES_USE_DATABASE 1 |
65 | |
66 | #undef NCURSES_USE_TERMCAP |
67 | #define NCURSES_USE_TERMCAP 0 |
68 | |
69 | #undef NCURSES_XNAMES |
70 | #define NCURSES_XNAMES 1 |
71 | |
72 | /* We will use these symbols to hide differences between |
73 | * termios/termio/sgttyb interfaces. |
74 | */ |
75 | #undef TTY |
76 | #undef SET_TTY |
77 | #undef GET_TTY |
78 | |
79 | /* Assume POSIX termio if we have the header and function */ |
80 | /* #if HAVE_TERMIOS_H && HAVE_TCGETATTR */ |
81 | #if 1 && 1 |
82 | |
83 | #undef TERMIOS |
84 | #define TERMIOS 1 |
85 | |
86 | #include <termios.h> |
87 | #define TTY struct termios |
88 | |
89 | #else /* !HAVE_TERMIOS_H */ |
90 | |
91 | /* #if HAVE_TERMIO_H */ |
92 | #if 1 |
93 | |
94 | #undef TERMIOS |
95 | #define TERMIOS 1 |
96 | |
97 | #include <termio.h> |
98 | #define TTY struct termio |
99 | |
100 | #else /* !HAVE_TERMIO_H */ |
101 | |
102 | #if __MINGW32__ |
103 | # include <ncurses_mingw.h> |
104 | # define TTY struct termios |
105 | #else |
106 | #undef TERMIOS |
107 | #include <sgtty.h> |
108 | #include <sys/ioctl.h> |
109 | #define TTY struct sgttyb |
110 | #endif /* MINGW32 */ |
111 | #endif /* HAVE_TERMIO_H */ |
112 | |
113 | #endif /* HAVE_TERMIOS_H */ |
114 | |
115 | #ifdef TERMIOS |
116 | #define GET_TTY(fd, buf) tcgetattr(fd, buf) |
117 | #define SET_TTY(fd, buf) tcsetattr(fd, TCSADRAIN, buf) |
118 | #else |
119 | #define GET_TTY(fd, buf) gtty(fd, buf) |
120 | #define SET_TTY(fd, buf) stty(fd, buf) |
121 | #endif |
122 | |
123 | #define NAMESIZE 256 |
124 | |
125 | /* The cast works because TERMTYPE is the first data in TERMINAL */ |
126 | #define CUR ((TERMTYPE *)(cur_term))-> |
127 | |
128 | #define auto_left_margin CUR Booleans[0] |
129 | #define auto_right_margin CUR Booleans[1] |
130 | #define no_esc_ctlc CUR Booleans[2] |
131 | #define ceol_standout_glitch CUR Booleans[3] |
132 | #define eat_newline_glitch CUR Booleans[4] |
133 | #define erase_overstrike CUR Booleans[5] |
134 | #define generic_type CUR Booleans[6] |
135 | #define hard_copy CUR Booleans[7] |
136 | #define has_meta_key CUR Booleans[8] |
137 | #define has_status_line CUR Booleans[9] |
138 | #define insert_null_glitch CUR Booleans[10] |
139 | #define memory_above CUR Booleans[11] |
140 | #define memory_below CUR Booleans[12] |
141 | #define move_insert_mode CUR Booleans[13] |
142 | #define move_standout_mode CUR Booleans[14] |
143 | #define over_strike CUR Booleans[15] |
144 | #define status_line_esc_ok CUR Booleans[16] |
145 | #define dest_tabs_magic_smso CUR Booleans[17] |
146 | #define tilde_glitch CUR Booleans[18] |
147 | #define transparent_underline CUR Booleans[19] |
148 | #define xon_xoff CUR Booleans[20] |
149 | #define needs_xon_xoff CUR Booleans[21] |
150 | #define prtr_silent CUR Booleans[22] |
151 | #define hard_cursor CUR Booleans[23] |
152 | #define non_rev_rmcup CUR Booleans[24] |
153 | #define no_pad_char CUR Booleans[25] |
154 | #define non_dest_scroll_region CUR Booleans[26] |
155 | #define can_change CUR Booleans[27] |
156 | #define back_color_erase CUR Booleans[28] |
157 | #define hue_lightness_saturation CUR Booleans[29] |
158 | #define col_addr_glitch CUR Booleans[30] |
159 | #define cr_cancels_micro_mode CUR Booleans[31] |
160 | #define has_print_wheel CUR Booleans[32] |
161 | #define row_addr_glitch CUR Booleans[33] |
162 | #define semi_auto_right_margin CUR Booleans[34] |
163 | #define cpi_changes_res CUR Booleans[35] |
164 | #define lpi_changes_res CUR Booleans[36] |
165 | #define columns CUR Numbers[0] |
166 | #define init_tabs CUR Numbers[1] |
167 | #define lines CUR Numbers[2] |
168 | #define lines_of_memory CUR Numbers[3] |
169 | #define magic_cookie_glitch CUR Numbers[4] |
170 | #define padding_baud_rate CUR Numbers[5] |
171 | #define virtual_terminal CUR Numbers[6] |
172 | #define width_status_line CUR Numbers[7] |
173 | #define num_labels CUR Numbers[8] |
174 | #define label_height CUR Numbers[9] |
175 | #define label_width CUR Numbers[10] |
176 | #define max_attributes CUR Numbers[11] |
177 | #define maximum_windows CUR Numbers[12] |
178 | #define max_colors CUR Numbers[13] |
179 | #define max_pairs CUR Numbers[14] |
180 | #define no_color_video CUR Numbers[15] |
181 | #define buffer_capacity CUR Numbers[16] |
182 | #define dot_vert_spacing CUR Numbers[17] |
183 | #define dot_horz_spacing CUR Numbers[18] |
184 | #define max_micro_address CUR Numbers[19] |
185 | #define max_micro_jump CUR Numbers[20] |
186 | #define micro_col_size CUR Numbers[21] |
187 | #define micro_line_size CUR Numbers[22] |
188 | #define number_of_pins CUR Numbers[23] |
189 | #define output_res_char CUR Numbers[24] |
190 | #define output_res_line CUR Numbers[25] |
191 | #define output_res_horz_inch CUR Numbers[26] |
192 | #define output_res_vert_inch CUR Numbers[27] |
193 | #define print_rate CUR Numbers[28] |
194 | #define wide_char_size CUR Numbers[29] |
195 | #define buttons CUR Numbers[30] |
196 | #define bit_image_entwining CUR Numbers[31] |
197 | #define bit_image_type CUR Numbers[32] |
198 | #define back_tab CUR Strings[0] |
199 | #define bell CUR Strings[1] |
200 | #define carriage_return CUR Strings[2] |
201 | #define change_scroll_region CUR Strings[3] |
202 | #define clear_all_tabs CUR Strings[4] |
203 | #define clear_screen CUR Strings[5] |
204 | #define clr_eol CUR Strings[6] |
205 | #define clr_eos CUR Strings[7] |
206 | #define column_address CUR Strings[8] |
207 | #define command_character CUR Strings[9] |
208 | #define cursor_address CUR Strings[10] |
209 | #define cursor_down CUR Strings[11] |
210 | #define cursor_home CUR Strings[12] |
211 | #define cursor_invisible CUR Strings[13] |
212 | #define cursor_left CUR Strings[14] |
213 | #define cursor_mem_address CUR Strings[15] |
214 | #define cursor_normal CUR Strings[16] |
215 | #define cursor_right CUR Strings[17] |
216 | #define cursor_to_ll CUR Strings[18] |
217 | #define cursor_up CUR Strings[19] |
218 | #define cursor_visible CUR Strings[20] |
219 | #define delete_character CUR Strings[21] |
220 | #define delete_line CUR Strings[22] |
221 | #define dis_status_line CUR Strings[23] |
222 | #define down_half_line CUR Strings[24] |
223 | #define enter_alt_charset_mode CUR Strings[25] |
224 | #define enter_blink_mode CUR Strings[26] |
225 | #define enter_bold_mode CUR Strings[27] |
226 | #define enter_ca_mode CUR Strings[28] |
227 | #define enter_delete_mode CUR Strings[29] |
228 | #define enter_dim_mode CUR Strings[30] |
229 | #define enter_insert_mode CUR Strings[31] |
230 | #define enter_secure_mode CUR Strings[32] |
231 | #define enter_protected_mode CUR Strings[33] |
232 | #define enter_reverse_mode CUR Strings[34] |
233 | #define enter_standout_mode CUR Strings[35] |
234 | #define enter_underline_mode CUR Strings[36] |
235 | #define erase_chars CUR Strings[37] |
236 | #define exit_alt_charset_mode CUR Strings[38] |
237 | #define exit_attribute_mode CUR Strings[39] |
238 | #define exit_ca_mode CUR Strings[40] |
239 | #define exit_delete_mode CUR Strings[41] |
240 | #define exit_insert_mode CUR Strings[42] |
241 | #define exit_standout_mode CUR Strings[43] |
242 | #define exit_underline_mode CUR Strings[44] |
243 | #define flash_screen CUR Strings[45] |
244 | #define form_feed CUR Strings[46] |
245 | #define from_status_line CUR Strings[47] |
246 | #define init_1string CUR Strings[48] |
247 | #define init_2string CUR Strings[49] |
248 | #define init_3string CUR Strings[50] |
249 | #define init_file CUR Strings[51] |
250 | #define insert_character CUR Strings[52] |
251 | #define insert_line CUR Strings[53] |
252 | #define insert_padding CUR Strings[54] |
253 | #define key_backspace CUR Strings[55] |
254 | #define key_catab CUR Strings[56] |
255 | #define key_clear CUR Strings[57] |
256 | #define key_ctab CUR Strings[58] |
257 | #define key_dc CUR Strings[59] |
258 | #define key_dl CUR Strings[60] |
259 | #define key_down CUR Strings[61] |
260 | #define key_eic CUR Strings[62] |
261 | #define key_eol CUR Strings[63] |
262 | #define key_eos CUR Strings[64] |
263 | #define key_f0 CUR Strings[65] |
264 | #define key_f1 CUR Strings[66] |
265 | #define key_f10 CUR Strings[67] |
266 | #define key_f2 CUR Strings[68] |
267 | #define key_f3 CUR Strings[69] |
268 | #define key_f4 CUR Strings[70] |
269 | #define key_f5 CUR Strings[71] |
270 | #define key_f6 CUR Strings[72] |
271 | #define key_f7 CUR Strings[73] |
272 | #define key_f8 CUR Strings[74] |
273 | #define key_f9 CUR Strings[75] |
274 | #define key_home CUR Strings[76] |
275 | #define key_ic CUR Strings[77] |
276 | #define key_il CUR Strings[78] |
277 | #define key_left CUR Strings[79] |
278 | #define key_ll CUR Strings[80] |
279 | #define key_npage CUR Strings[81] |
280 | #define key_ppage CUR Strings[82] |
281 | #define key_right CUR Strings[83] |
282 | #define key_sf CUR Strings[84] |
283 | #define key_sr CUR Strings[85] |
284 | #define key_stab CUR Strings[86] |
285 | #define key_up CUR Strings[87] |
286 | #define keypad_local CUR Strings[88] |
287 | #define keypad_xmit CUR Strings[89] |
288 | #define lab_f0 CUR Strings[90] |
289 | #define lab_f1 CUR Strings[91] |
290 | #define lab_f10 CUR Strings[92] |
291 | #define lab_f2 CUR Strings[93] |
292 | #define lab_f3 CUR Strings[94] |
293 | #define lab_f4 CUR Strings[95] |
294 | #define lab_f5 CUR Strings[96] |
295 | #define lab_f6 CUR Strings[97] |
296 | #define lab_f7 CUR Strings[98] |
297 | #define lab_f8 CUR Strings[99] |
298 | #define lab_f9 CUR Strings[100] |
299 | #define meta_off CUR Strings[101] |
300 | #define meta_on CUR Strings[102] |
301 | #define newline CUR Strings[103] |
302 | #define pad_char CUR Strings[104] |
303 | #define parm_dch CUR Strings[105] |
304 | #define parm_delete_line CUR Strings[106] |
305 | #define parm_down_cursor CUR Strings[107] |
306 | #define parm_ich CUR Strings[108] |
307 | #define parm_index CUR Strings[109] |
308 | #define parm_insert_line CUR Strings[110] |
309 | #define parm_left_cursor CUR Strings[111] |
310 | #define parm_right_cursor CUR Strings[112] |
311 | #define parm_rindex CUR Strings[113] |
312 | #define parm_up_cursor CUR Strings[114] |
313 | #define pkey_key CUR Strings[115] |
314 | #define pkey_local CUR Strings[116] |
315 | #define pkey_xmit CUR Strings[117] |
316 | #define print_screen CUR Strings[118] |
317 | #define prtr_off CUR Strings[119] |
318 | #define prtr_on CUR Strings[120] |
319 | #define repeat_char CUR Strings[121] |
320 | #define reset_1string CUR Strings[122] |
321 | #define reset_2string CUR Strings[123] |
322 | #define reset_3string CUR Strings[124] |
323 | #define reset_file CUR Strings[125] |
324 | #define restore_cursor CUR Strings[126] |
325 | #define row_address CUR Strings[127] |
326 | #define save_cursor CUR Strings[128] |
327 | #define scroll_forward CUR Strings[129] |
328 | #define scroll_reverse CUR Strings[130] |
329 | #define set_attributes CUR Strings[131] |
330 | #define set_tab CUR Strings[132] |
331 | #define set_window CUR Strings[133] |
332 | #define tab CUR Strings[134] |
333 | #define to_status_line CUR Strings[135] |
334 | #define underline_char CUR Strings[136] |
335 | #define up_half_line CUR Strings[137] |
336 | #define init_prog CUR Strings[138] |
337 | #define key_a1 CUR Strings[139] |
338 | #define key_a3 CUR Strings[140] |
339 | #define key_b2 CUR Strings[141] |
340 | #define key_c1 CUR Strings[142] |
341 | #define key_c3 CUR Strings[143] |
342 | #define prtr_non CUR Strings[144] |
343 | #define char_padding CUR Strings[145] |
344 | #define acs_chars CUR Strings[146] |
345 | #define plab_norm CUR Strings[147] |
346 | #define key_btab CUR Strings[148] |
347 | #define enter_xon_mode CUR Strings[149] |
348 | #define exit_xon_mode CUR Strings[150] |
349 | #define enter_am_mode CUR Strings[151] |
350 | #define exit_am_mode CUR Strings[152] |
351 | #define xon_character CUR Strings[153] |
352 | #define xoff_character CUR Strings[154] |
353 | #define ena_acs CUR Strings[155] |
354 | #define label_on CUR Strings[156] |
355 | #define label_off CUR Strings[157] |
356 | #define key_beg CUR Strings[158] |
357 | #define key_cancel CUR Strings[159] |
358 | #define key_close CUR Strings[160] |
359 | #define key_command CUR Strings[161] |
360 | #define key_copy CUR Strings[162] |
361 | #define key_create CUR Strings[163] |
362 | #define key_end CUR Strings[164] |
363 | #define key_enter CUR Strings[165] |
364 | #define key_exit CUR Strings[166] |
365 | #define key_find CUR Strings[167] |
366 | #define key_help CUR Strings[168] |
367 | #define key_mark CUR Strings[169] |
368 | #define key_message CUR Strings[170] |
369 | #define key_move CUR Strings[171] |
370 | #define key_next CUR Strings[172] |
371 | #define key_open CUR Strings[173] |
372 | #define key_options CUR Strings[174] |
373 | #define key_previous CUR Strings[175] |
374 | #define key_print CUR Strings[176] |
375 | #define key_redo CUR Strings[177] |
376 | #define key_reference CUR Strings[178] |
377 | #define key_refresh CUR Strings[179] |
378 | #define key_replace CUR Strings[180] |
379 | #define key_restart CUR Strings[181] |
380 | #define key_resume CUR Strings[182] |
381 | #define key_save CUR Strings[183] |
382 | #define key_suspend CUR Strings[184] |
383 | #define key_undo CUR Strings[185] |
384 | #define key_sbeg CUR Strings[186] |
385 | #define key_scancel CUR Strings[187] |
386 | #define key_scommand CUR Strings[188] |
387 | #define key_scopy CUR Strings[189] |
388 | #define key_screate CUR Strings[190] |
389 | #define key_sdc CUR Strings[191] |
390 | #define key_sdl CUR Strings[192] |
391 | #define key_select CUR Strings[193] |
392 | #define key_send CUR Strings[194] |
393 | #define key_seol CUR Strings[195] |
394 | #define key_sexit CUR Strings[196] |
395 | #define key_sfind CUR Strings[197] |
396 | #define key_shelp CUR Strings[198] |
397 | #define key_shome CUR Strings[199] |
398 | #define key_sic CUR Strings[200] |
399 | #define key_sleft CUR Strings[201] |
400 | #define key_smessage CUR Strings[202] |
401 | #define key_smove CUR Strings[203] |
402 | #define key_snext CUR Strings[204] |
403 | #define key_soptions CUR Strings[205] |
404 | #define key_sprevious CUR Strings[206] |
405 | #define key_sprint CUR Strings[207] |
406 | #define key_sredo CUR Strings[208] |
407 | #define key_sreplace CUR Strings[209] |
408 | #define key_sright CUR Strings[210] |
409 | #define key_srsume CUR Strings[211] |
410 | #define key_ssave CUR Strings[212] |
411 | #define key_ssuspend CUR Strings[213] |
412 | #define key_sundo CUR Strings[214] |
413 | #define req_for_input CUR Strings[215] |
414 | #define key_f11 CUR Strings[216] |
415 | #define key_f12 CUR Strings[217] |
416 | #define key_f13 CUR Strings[218] |
417 | #define key_f14 CUR Strings[219] |
418 | #define key_f15 CUR Strings[220] |
419 | #define key_f16 CUR Strings[221] |
420 | #define key_f17 CUR Strings[222] |
421 | #define key_f18 CUR Strings[223] |
422 | #define key_f19 CUR Strings[224] |
423 | #define key_f20 CUR Strings[225] |
424 | #define key_f21 CUR Strings[226] |
425 | #define key_f22 CUR Strings[227] |
426 | #define key_f23 CUR Strings[228] |
427 | #define key_f24 CUR Strings[229] |
428 | #define key_f25 CUR Strings[230] |
429 | #define key_f26 CUR Strings[231] |
430 | #define key_f27 CUR Strings[232] |
431 | #define key_f28 CUR Strings[233] |
432 | #define key_f29 CUR Strings[234] |
433 | #define key_f30 CUR Strings[235] |
434 | #define key_f31 CUR Strings[236] |
435 | #define key_f32 CUR Strings[237] |
436 | #define key_f33 CUR Strings[238] |
437 | #define key_f34 CUR Strings[239] |
438 | #define key_f35 CUR Strings[240] |
439 | #define key_f36 CUR Strings[241] |
440 | #define key_f37 CUR Strings[242] |
441 | #define key_f38 CUR Strings[243] |
442 | #define key_f39 CUR Strings[244] |
443 | #define key_f40 CUR Strings[245] |
444 | #define key_f41 CUR Strings[246] |
445 | #define key_f42 CUR Strings[247] |
446 | #define key_f43 CUR Strings[248] |
447 | #define key_f44 CUR Strings[249] |
448 | #define key_f45 CUR Strings[250] |
449 | #define key_f46 CUR Strings[251] |
450 | #define key_f47 CUR Strings[252] |
451 | #define key_f48 CUR Strings[253] |
452 | #define key_f49 CUR Strings[254] |
453 | #define key_f50 CUR Strings[255] |
454 | #define key_f51 CUR Strings[256] |
455 | #define key_f52 CUR Strings[257] |
456 | #define key_f53 CUR Strings[258] |
457 | #define key_f54 CUR Strings[259] |
458 | #define key_f55 CUR Strings[260] |
459 | #define key_f56 CUR Strings[261] |
460 | #define key_f57 CUR Strings[262] |
461 | #define key_f58 CUR Strings[263] |
462 | #define key_f59 CUR Strings[264] |
463 | #define key_f60 CUR Strings[265] |
464 | #define key_f61 CUR Strings[266] |
465 | #define key_f62 CUR Strings[267] |
466 | #define key_f63 CUR Strings[268] |
467 | #define clr_bol CUR Strings[269] |
468 | #define clear_margins CUR Strings[270] |
469 | #define set_left_margin CUR Strings[271] |
470 | #define set_right_margin CUR Strings[272] |
471 | #define label_format CUR Strings[273] |
472 | #define set_clock CUR Strings[274] |
473 | #define display_clock CUR Strings[275] |
474 | #define remove_clock CUR Strings[276] |
475 | #define create_window CUR Strings[277] |
476 | #define goto_window CUR Strings[278] |
477 | #define hangup CUR Strings[279] |
478 | #define dial_phone CUR Strings[280] |
479 | #define quick_dial CUR Strings[281] |
480 | #define tone CUR Strings[282] |
481 | #define pulse CUR Strings[283] |
482 | #define flash_hook CUR Strings[284] |
483 | #define fixed_pause CUR Strings[285] |
484 | #define wait_tone CUR Strings[286] |
485 | #define user0 CUR Strings[287] |
486 | #define user1 CUR Strings[288] |
487 | #define user2 CUR Strings[289] |
488 | #define user3 CUR Strings[290] |
489 | #define user4 CUR Strings[291] |
490 | #define user5 CUR Strings[292] |
491 | #define user6 CUR Strings[293] |
492 | #define user7 CUR Strings[294] |
493 | #define user8 CUR Strings[295] |
494 | #define user9 CUR Strings[296] |
495 | #define orig_pair CUR Strings[297] |
496 | #define orig_colors CUR Strings[298] |
497 | #define initialize_color CUR Strings[299] |
498 | #define initialize_pair CUR Strings[300] |
499 | #define set_color_pair CUR Strings[301] |
500 | #define set_foreground CUR Strings[302] |
501 | #define set_background CUR Strings[303] |
502 | #define change_char_pitch CUR Strings[304] |
503 | #define change_line_pitch CUR Strings[305] |
504 | #define change_res_horz CUR Strings[306] |
505 | #define change_res_vert CUR Strings[307] |
506 | #define define_char CUR Strings[308] |
507 | #define enter_doublewide_mode CUR Strings[309] |
508 | #define enter_draft_quality CUR Strings[310] |
509 | #define enter_italics_mode CUR Strings[311] |
510 | #define enter_leftward_mode CUR Strings[312] |
511 | #define enter_micro_mode CUR Strings[313] |
512 | #define enter_near_letter_quality CUR Strings[314] |
513 | #define enter_normal_quality CUR Strings[315] |
514 | #define enter_shadow_mode CUR Strings[316] |
515 | #define enter_subscript_mode CUR Strings[317] |
516 | #define enter_superscript_mode CUR Strings[318] |
517 | #define enter_upward_mode CUR Strings[319] |
518 | #define exit_doublewide_mode CUR Strings[320] |
519 | #define exit_italics_mode CUR Strings[321] |
520 | #define exit_leftward_mode CUR Strings[322] |
521 | #define exit_micro_mode CUR Strings[323] |
522 | #define exit_shadow_mode CUR Strings[324] |
523 | #define exit_subscript_mode CUR Strings[325] |
524 | #define exit_superscript_mode CUR Strings[326] |
525 | #define exit_upward_mode CUR Strings[327] |
526 | #define micro_column_address CUR Strings[328] |
527 | #define micro_down CUR Strings[329] |
528 | #define micro_left CUR Strings[330] |
529 | #define micro_right CUR Strings[331] |
530 | #define micro_row_address CUR Strings[332] |
531 | #define micro_up CUR Strings[333] |
532 | #define order_of_pins CUR Strings[334] |
533 | #define parm_down_micro CUR Strings[335] |
534 | #define parm_left_micro CUR Strings[336] |
535 | #define parm_right_micro CUR Strings[337] |
536 | #define parm_up_micro CUR Strings[338] |
537 | #define select_char_set CUR Strings[339] |
538 | #define set_bottom_margin CUR Strings[340] |
539 | #define set_bottom_margin_parm CUR Strings[341] |
540 | #define set_left_margin_parm CUR Strings[342] |
541 | #define set_right_margin_parm CUR Strings[343] |
542 | #define set_top_margin CUR Strings[344] |
543 | #define set_top_margin_parm CUR Strings[345] |
544 | #define start_bit_image CUR Strings[346] |
545 | #define start_char_set_def CUR Strings[347] |
546 | #define stop_bit_image CUR Strings[348] |
547 | #define stop_char_set_def CUR Strings[349] |
548 | #define subscript_characters CUR Strings[350] |
549 | #define superscript_characters CUR Strings[351] |
550 | #define these_cause_cr CUR Strings[352] |
551 | #define zero_motion CUR Strings[353] |
552 | #define char_set_names CUR Strings[354] |
553 | #define key_mouse CUR Strings[355] |
554 | #define mouse_info CUR Strings[356] |
555 | #define req_mouse_pos CUR Strings[357] |
556 | #define get_mouse CUR Strings[358] |
557 | #define set_a_foreground CUR Strings[359] |
558 | #define set_a_background CUR Strings[360] |
559 | #define pkey_plab CUR Strings[361] |
560 | #define device_type CUR Strings[362] |
561 | #define code_set_init CUR Strings[363] |
562 | #define set0_des_seq CUR Strings[364] |
563 | #define set1_des_seq CUR Strings[365] |
564 | #define set2_des_seq CUR Strings[366] |
565 | #define set3_des_seq CUR Strings[367] |
566 | #define set_lr_margin CUR Strings[368] |
567 | #define set_tb_margin CUR Strings[369] |
568 | #define bit_image_repeat CUR Strings[370] |
569 | #define bit_image_newline CUR Strings[371] |
570 | #define bit_image_carriage_return CUR Strings[372] |
571 | #define color_names CUR Strings[373] |
572 | #define define_bit_image_region CUR Strings[374] |
573 | #define end_bit_image_region CUR Strings[375] |
574 | #define set_color_band CUR Strings[376] |
575 | #define set_page_length CUR Strings[377] |
576 | #define display_pc_char CUR Strings[378] |
577 | #define enter_pc_charset_mode CUR Strings[379] |
578 | #define exit_pc_charset_mode CUR Strings[380] |
579 | #define enter_scancode_mode CUR Strings[381] |
580 | #define exit_scancode_mode CUR Strings[382] |
581 | #define pc_term_options CUR Strings[383] |
582 | #define scancode_escape CUR Strings[384] |
583 | #define alt_scancode_esc CUR Strings[385] |
584 | #define enter_horizontal_hl_mode CUR Strings[386] |
585 | #define enter_left_hl_mode CUR Strings[387] |
586 | #define enter_low_hl_mode CUR Strings[388] |
587 | #define enter_right_hl_mode CUR Strings[389] |
588 | #define enter_top_hl_mode CUR Strings[390] |
589 | #define enter_vertical_hl_mode CUR Strings[391] |
590 | #define set_a_attributes CUR Strings[392] |
591 | #define set_pglen_inch CUR Strings[393] |
592 | |
593 | #define BOOLWRITE 37 |
594 | #define NUMWRITE 33 |
595 | #define STRWRITE 394 |
596 | |
597 | /* older synonyms for some capabilities */ |
598 | #define beehive_glitch no_esc_ctlc |
599 | #define teleray_glitch dest_tabs_magic_smso |
600 | #define micro_char_size micro_col_size |
601 | |
602 | #ifdef __INTERNAL_CAPS_VISIBLE |
603 | #define termcap_init2 CUR Strings[394] |
604 | #define termcap_reset CUR Strings[395] |
605 | #define magic_cookie_glitch_ul CUR Numbers[33] |
606 | #define backspaces_with_bs CUR Booleans[37] |
607 | #define crt_no_scrolling CUR Booleans[38] |
608 | #define no_correctly_working_cr CUR Booleans[39] |
609 | #define carriage_return_delay CUR Numbers[34] |
610 | #define new_line_delay CUR Numbers[35] |
611 | #define linefeed_if_not_lf CUR Strings[396] |
612 | #define backspace_if_not_bs CUR Strings[397] |
613 | #define gnu_has_meta_key CUR Booleans[40] |
614 | #define linefeed_is_newline CUR Booleans[41] |
615 | #define backspace_delay CUR Numbers[36] |
616 | #define horizontal_tab_delay CUR Numbers[37] |
617 | #define number_of_function_keys CUR Numbers[38] |
618 | #define other_non_function_keys CUR Strings[398] |
619 | #define arrow_key_map CUR Strings[399] |
620 | #define has_hardware_tabs CUR Booleans[42] |
621 | #define return_does_clr_eol CUR Booleans[43] |
622 | #define acs_ulcorner CUR Strings[400] |
623 | #define acs_llcorner CUR Strings[401] |
624 | #define acs_urcorner CUR Strings[402] |
625 | #define acs_lrcorner CUR Strings[403] |
626 | #define acs_ltee CUR Strings[404] |
627 | #define acs_rtee CUR Strings[405] |
628 | #define acs_btee CUR Strings[406] |
629 | #define acs_ttee CUR Strings[407] |
630 | #define acs_hline CUR Strings[408] |
631 | #define acs_vline CUR Strings[409] |
632 | #define acs_plus CUR Strings[410] |
633 | #define memory_lock CUR Strings[411] |
634 | #define memory_unlock CUR Strings[412] |
635 | #define box_chars_1 CUR Strings[413] |
636 | #endif /* __INTERNAL_CAPS_VISIBLE */ |
637 | |
638 | |
639 | /* |
640 | * Predefined terminfo array sizes |
641 | */ |
642 | #define BOOLCOUNT 44 |
643 | #define NUMCOUNT 39 |
644 | #define STRCOUNT 414 |
645 | |
646 | /* used by code for comparing entries */ |
647 | #define acs_chars_index 146 |
648 | |
649 | typedef struct termtype { /* in-core form of terminfo data */ |
650 | char *term_names; /* str_table offset of term names */ |
651 | char *str_table; /* pointer to string table */ |
652 | NCURSES_SBOOL *Booleans; /* array of boolean values */ |
653 | short *Numbers; /* array of integer values */ |
654 | char **Strings; /* array of string offsets */ |
655 | |
656 | #if NCURSES_XNAMES |
657 | char *ext_str_table; /* pointer to extended string table */ |
658 | char **ext_Names; /* corresponding names */ |
659 | |
660 | unsigned short num_Booleans;/* count total Booleans */ |
661 | unsigned short num_Numbers; /* count total Numbers */ |
662 | unsigned short num_Strings; /* count total Strings */ |
663 | |
664 | unsigned short ext_Booleans;/* count extensions to Booleans */ |
665 | unsigned short ext_Numbers; /* count extensions to Numbers */ |
666 | unsigned short ext_Strings; /* count extensions to Strings */ |
667 | #endif /* NCURSES_XNAMES */ |
668 | |
669 | } TERMTYPE; |
670 | |
671 | /* |
672 | * The only reason these structures are visible is for read-only use. |
673 | * Programs which modify the data are not, never were, portable across |
674 | * curses implementations. |
675 | */ |
676 | #ifdef NCURSES_INTERNALS |
677 | |
678 | typedef TERMTYPE TERMTYPE2; |
679 | |
680 | typedef struct term { /* describe an actual terminal */ |
681 | TERMTYPE type; /* terminal type description */ |
682 | short Filedes; /* file description being written to */ |
683 | TTY Ottyb; /* original state of the terminal */ |
684 | TTY Nttyb; /* current state of the terminal */ |
685 | int _baudrate; /* used to compute padding */ |
686 | char * _termname; /* used for termname() */ |
687 | } TERMINAL; |
688 | #else |
689 | typedef struct term TERMINAL; |
690 | #endif /* NCURSES_INTERNALS */ |
691 | |
692 | |
693 | #if 0 && !0 |
694 | extern NCURSES_EXPORT_VAR(TERMINAL *) cur_term; |
695 | #elif 0 |
696 | NCURSES_WRAPPED_VAR(TERMINAL *, cur_term); |
697 | #define cur_term NCURSES_PUBLIC_VAR(cur_term()) |
698 | #else |
699 | extern NCURSES_EXPORT_VAR(TERMINAL *) cur_term; |
700 | #endif |
701 | |
702 | #if 0 || 0 |
703 | NCURSES_WRAPPED_VAR(NCURSES_CONST char * const *, boolnames); |
704 | NCURSES_WRAPPED_VAR(NCURSES_CONST char * const *, boolcodes); |
705 | NCURSES_WRAPPED_VAR(NCURSES_CONST char * const *, boolfnames); |
706 | NCURSES_WRAPPED_VAR(NCURSES_CONST char * const *, numnames); |
707 | NCURSES_WRAPPED_VAR(NCURSES_CONST char * const *, numcodes); |
708 | NCURSES_WRAPPED_VAR(NCURSES_CONST char * const *, numfnames); |
709 | NCURSES_WRAPPED_VAR(NCURSES_CONST char * const *, strnames); |
710 | NCURSES_WRAPPED_VAR(NCURSES_CONST char * const *, strcodes); |
711 | NCURSES_WRAPPED_VAR(NCURSES_CONST char * const *, strfnames); |
712 | |
713 | #define boolnames NCURSES_PUBLIC_VAR(boolnames()) |
714 | #define boolcodes NCURSES_PUBLIC_VAR(boolcodes()) |
715 | #define boolfnames NCURSES_PUBLIC_VAR(boolfnames()) |
716 | #define numnames NCURSES_PUBLIC_VAR(numnames()) |
717 | #define numcodes NCURSES_PUBLIC_VAR(numcodes()) |
718 | #define numfnames NCURSES_PUBLIC_VAR(numfnames()) |
719 | #define strnames NCURSES_PUBLIC_VAR(strnames()) |
720 | #define strcodes NCURSES_PUBLIC_VAR(strcodes()) |
721 | #define strfnames NCURSES_PUBLIC_VAR(strfnames()) |
722 | |
723 | #else |
724 | |
725 | extern NCURSES_EXPORT_VAR(NCURSES_CONST char * const ) boolnames[]; |
726 | extern NCURSES_EXPORT_VAR(NCURSES_CONST char * const ) boolcodes[]; |
727 | extern NCURSES_EXPORT_VAR(NCURSES_CONST char * const ) boolfnames[]; |
728 | extern NCURSES_EXPORT_VAR(NCURSES_CONST char * const ) numnames[]; |
729 | extern NCURSES_EXPORT_VAR(NCURSES_CONST char * const ) numcodes[]; |
730 | extern NCURSES_EXPORT_VAR(NCURSES_CONST char * const ) numfnames[]; |
731 | extern NCURSES_EXPORT_VAR(NCURSES_CONST char * const ) strnames[]; |
732 | extern NCURSES_EXPORT_VAR(NCURSES_CONST char * const ) strcodes[]; |
733 | extern NCURSES_EXPORT_VAR(NCURSES_CONST char * const ) strfnames[]; |
734 | |
735 | #endif |
736 | |
737 | /* |
738 | * These entrypoints are used only by the ncurses utilities such as tic. |
739 | */ |
740 | #ifdef NCURSES_INTERNALS |
741 | |
742 | extern NCURSES_EXPORT(int) _nc_set_tty_mode (TTY *buf); |
743 | extern NCURSES_EXPORT(int) _nc_read_entry2 (const char * const, char * const, TERMTYPE2 *const); |
744 | extern NCURSES_EXPORT(int) _nc_read_file_entry (const char *const, TERMTYPE2 *); |
745 | extern NCURSES_EXPORT(int) _nc_read_termtype (TERMTYPE2 *, char *, int); |
746 | extern NCURSES_EXPORT(char *) _nc_first_name (const char *const); |
747 | extern NCURSES_EXPORT(int) _nc_name_match (const char *const, const char *const, const char *const); |
748 | |
749 | #endif /* NCURSES_INTERNALS */ |
750 | |
751 | |
752 | /* |
753 | * These entrypoints are used by tack. |
754 | */ |
755 | extern NCURSES_EXPORT(const TERMTYPE *) _nc_fallback (const char *); |
756 | extern NCURSES_EXPORT(int) _nc_read_entry (const char * const, char * const, TERMTYPE *const); |
757 | |
758 | /* Normal entry points */ |
759 | extern NCURSES_EXPORT(TERMINAL *) set_curterm (TERMINAL *); |
760 | extern NCURSES_EXPORT(int) del_curterm (TERMINAL *); |
761 | |
762 | /* miscellaneous entry points */ |
763 | extern NCURSES_EXPORT(int) restartterm (NCURSES_CONST char *, int, int *); |
764 | extern NCURSES_EXPORT(int) setupterm (NCURSES_CONST char *,int,int *); |
765 | |
766 | /* terminfo entry points, also declared in curses.h */ |
767 | #if !defined(__NCURSES_H) |
768 | extern NCURSES_EXPORT(char *) tigetstr (NCURSES_CONST char *); |
769 | extern NCURSES_EXPORT_VAR(char) ttytype[]; |
770 | extern NCURSES_EXPORT(int) putp (const char *); |
771 | extern NCURSES_EXPORT(int) tigetflag (NCURSES_CONST char *); |
772 | extern NCURSES_EXPORT(int) tigetnum (NCURSES_CONST char *); |
773 | |
774 | #if 1 /* NCURSES_TPARM_VARARGS */ |
775 | extern NCURSES_EXPORT(char *) tparm (NCURSES_CONST char *, ...); /* special */ |
776 | #else |
777 | extern NCURSES_EXPORT(char *) tparm (NCURSES_CONST char *, long,long,long,long,long,long,long,long,long); /* special */ |
778 | extern NCURSES_EXPORT(char *) tparm_varargs (NCURSES_CONST char *, ...); /* special */ |
779 | #endif |
780 | |
781 | extern NCURSES_EXPORT(char *) tiparm (const char *, ...); /* special */ |
782 | |
783 | #endif /* __NCURSES_H */ |
784 | |
785 | /* termcap database emulation (XPG4 uses const only for 2nd param of tgetent) */ |
786 | #if !defined(NCURSES_TERMCAP_H_incl) |
787 | extern NCURSES_EXPORT(char *) tgetstr (NCURSES_CONST char *, char **); |
788 | extern NCURSES_EXPORT(char *) tgoto (const char *, int, int); |
789 | extern NCURSES_EXPORT(int) tgetent (char *, const char *); |
790 | extern NCURSES_EXPORT(int) tgetflag (NCURSES_CONST char *); |
791 | extern NCURSES_EXPORT(int) tgetnum (NCURSES_CONST char *); |
792 | extern NCURSES_EXPORT(int) tputs (const char *, int, int (*)(int)); |
793 | #endif /* NCURSES_TERMCAP_H_incl */ |
794 | |
795 | /* |
796 | * Include curses.h before term.h to enable these extensions. |
797 | */ |
798 | #if defined(NCURSES_SP_FUNCS) && (NCURSES_SP_FUNCS != 0) |
799 | |
800 | extern NCURSES_EXPORT(char *) NCURSES_SP_NAME(tigetstr) (SCREEN*, NCURSES_CONST char *); |
801 | extern NCURSES_EXPORT(int) NCURSES_SP_NAME(putp) (SCREEN*, const char *); |
802 | extern NCURSES_EXPORT(int) NCURSES_SP_NAME(tigetflag) (SCREEN*, NCURSES_CONST char *); |
803 | extern NCURSES_EXPORT(int) NCURSES_SP_NAME(tigetnum) (SCREEN*, NCURSES_CONST char *); |
804 | |
805 | #if 1 /* NCURSES_TPARM_VARARGS */ |
806 | extern NCURSES_EXPORT(char *) NCURSES_SP_NAME(tparm) (SCREEN*, NCURSES_CONST char *, ...); /* special */ |
807 | #else |
808 | extern NCURSES_EXPORT(char *) NCURSES_SP_NAME(tparm) (SCREEN*, NCURSES_CONST char *, long,long,long,long,long,long,long,long,long); /* special */ |
809 | extern NCURSES_EXPORT(char *) NCURSES_SP_NAME(tparm_varargs) (SCREEN*, NCURSES_CONST char *, ...); /* special */ |
810 | #endif |
811 | |
812 | /* termcap database emulation (XPG4 uses const only for 2nd param of tgetent) */ |
813 | extern NCURSES_EXPORT(char *) NCURSES_SP_NAME(tgetstr) (SCREEN*, NCURSES_CONST char *, char **); |
814 | extern NCURSES_EXPORT(char *) NCURSES_SP_NAME(tgoto) (SCREEN*, const char *, int, int); |
815 | extern NCURSES_EXPORT(int) NCURSES_SP_NAME(tgetent) (SCREEN*, char *, const char *); |
816 | extern NCURSES_EXPORT(int) NCURSES_SP_NAME(tgetflag) (SCREEN*, NCURSES_CONST char *); |
817 | extern NCURSES_EXPORT(int) NCURSES_SP_NAME(tgetnum) (SCREEN*, NCURSES_CONST char *); |
818 | extern NCURSES_EXPORT(int) NCURSES_SP_NAME(tputs) (SCREEN*, const char *, int, NCURSES_SP_OUTC); |
819 | |
820 | extern NCURSES_EXPORT(TERMINAL *) NCURSES_SP_NAME(set_curterm) (SCREEN*, TERMINAL *); |
821 | extern NCURSES_EXPORT(int) NCURSES_SP_NAME(del_curterm) (SCREEN*, TERMINAL *); |
822 | |
823 | extern NCURSES_EXPORT(int) NCURSES_SP_NAME(restartterm) (SCREEN*, NCURSES_CONST char *, int, int *); |
824 | #endif /* NCURSES_SP_FUNCS */ |
825 | |
826 | #ifdef __cplusplus |
827 | } |
828 | #endif |
829 | |
830 | #endif /* NCURSES_TERM_H_incl */ |
831 | |