diff options
Diffstat (limited to 'scripts/kconfig/libcurses/curspriv.h')
-rw-r--r-- | scripts/kconfig/libcurses/curspriv.h | 119 |
1 files changed, 119 insertions, 0 deletions
diff --git a/scripts/kconfig/libcurses/curspriv.h b/scripts/kconfig/libcurses/curspriv.h new file mode 100644 index 000000000..8bb712a8e --- /dev/null +++ b/scripts/kconfig/libcurses/curspriv.h | |||
@@ -0,0 +1,119 @@ | |||
1 | /* Private definitions and declarations for use within PDCurses. | ||
2 | These should generally not be referenced by applications. */ | ||
3 | |||
4 | #ifndef __CURSES_INTERNALS__ | ||
5 | #define __CURSES_INTERNALS__ 1 | ||
6 | |||
7 | #define CURSES_LIBRARY | ||
8 | #include "curses.h" | ||
9 | |||
10 | #if defined(__TURBOC__) || defined(__EMX__) || defined(__DJGPP__) || \ | ||
11 | defined(PDC_99) || defined(__WATCOMC__) | ||
12 | # ifndef HAVE_VSSCANF | ||
13 | # define HAVE_VSSCANF /* have vsscanf() */ | ||
14 | # endif | ||
15 | #endif | ||
16 | |||
17 | #if defined(PDC_99) || defined(__WATCOMC__) | ||
18 | # ifndef HAVE_VSNPRINTF | ||
19 | # define HAVE_VSNPRINTF /* have vsnprintf() */ | ||
20 | # endif | ||
21 | #endif | ||
22 | |||
23 | /*----------------------------------------------------------------------*/ | ||
24 | |||
25 | typedef struct /* structure for ripped off lines */ | ||
26 | { | ||
27 | int line; | ||
28 | int (*init)(WINDOW *, int); | ||
29 | } RIPPEDOFFLINE; | ||
30 | |||
31 | /* Window properties */ | ||
32 | |||
33 | #define _SUBWIN 0x01 /* window is a subwindow */ | ||
34 | #define _PAD 0x10 /* X/Open Pad. */ | ||
35 | #define _SUBPAD 0x20 /* X/Open subpad. */ | ||
36 | |||
37 | /* Miscellaneous */ | ||
38 | |||
39 | #define _NO_CHANGE -1 /* flags line edge unchanged */ | ||
40 | |||
41 | #define _ECHAR 0x08 /* Erase char (^H) */ | ||
42 | #define _DWCHAR 0x17 /* Delete Word char (^W) */ | ||
43 | #define _DLCHAR 0x15 /* Delete Line char (^U) */ | ||
44 | |||
45 | /*----------------------------------------------------------------------*/ | ||
46 | |||
47 | /* Platform implementation functions */ | ||
48 | |||
49 | void PDC_beep(void); | ||
50 | bool PDC_can_change_color(void); | ||
51 | int PDC_color_content(short, short *, short *, short *); | ||
52 | bool PDC_check_key(void); | ||
53 | int PDC_curs_set(int); | ||
54 | void PDC_flushinp(void); | ||
55 | int PDC_get_columns(void); | ||
56 | int PDC_get_cursor_mode(void); | ||
57 | int PDC_get_key(void); | ||
58 | int PDC_get_rows(void); | ||
59 | void PDC_gotoyx(int, int); | ||
60 | bool PDC_has_mouse(void); | ||
61 | int PDC_init_color(short, short, short, short); | ||
62 | void PDC_init_pair(short, short, short); | ||
63 | int PDC_modifiers_set(void); | ||
64 | int PDC_mouse_set(void); | ||
65 | void PDC_napms(int); | ||
66 | int PDC_pair_content(short, short *, short *); | ||
67 | void PDC_reset_prog_mode(void); | ||
68 | void PDC_reset_shell_mode(void); | ||
69 | int PDC_resize_screen(int, int); | ||
70 | void PDC_restore_screen_mode(int); | ||
71 | void PDC_save_screen_mode(int); | ||
72 | void PDC_scr_close(void); | ||
73 | void PDC_scr_free(void); | ||
74 | int PDC_scr_open(int, char **); | ||
75 | void PDC_set_keyboard_binary(bool); | ||
76 | void PDC_transform_line(int, int, int, const chtype *); | ||
77 | const char *PDC_sysname(void); | ||
78 | |||
79 | /* Internal cross-module functions */ | ||
80 | |||
81 | void PDC_init_atrtab(void); | ||
82 | WINDOW *PDC_makelines(WINDOW *); | ||
83 | WINDOW *PDC_makenew(int, int, int, int); | ||
84 | int PDC_mouse_in_slk(int, int); | ||
85 | void PDC_slk_free(void); | ||
86 | void PDC_slk_initialize(void); | ||
87 | void PDC_sync(WINDOW *); | ||
88 | |||
89 | #ifdef PDC_WIDE | ||
90 | int PDC_mbtowc(wchar_t *, const char *, size_t); | ||
91 | size_t PDC_mbstowcs(wchar_t *, const char *, size_t); | ||
92 | size_t PDC_wcstombs(char *, const wchar_t *, size_t); | ||
93 | #endif | ||
94 | |||
95 | #ifdef PDCDEBUG | ||
96 | # define PDC_LOG(x) if (SP && SP->dbfp) PDC_debug x | ||
97 | #else | ||
98 | # define PDC_LOG(x) | ||
99 | #endif | ||
100 | |||
101 | /* Internal macros for attributes */ | ||
102 | |||
103 | #define PDC_COLOR_PAIRS 256 | ||
104 | |||
105 | #ifndef max | ||
106 | # define max(a,b) (((a) > (b)) ? (a) : (b)) | ||
107 | #endif | ||
108 | #ifndef min | ||
109 | # define min(a,b) (((a) < (b)) ? (a) : (b)) | ||
110 | #endif | ||
111 | |||
112 | #define DIVROUND(num, divisor) ((num) + ((divisor) >> 1)) / (divisor) | ||
113 | |||
114 | #define PDC_CLICK_PERIOD 150 /* time to wait for a click, if | ||
115 | not set by mouseinterval() */ | ||
116 | |||
117 | #define PDC_MAXCOL 768 /* maximum possible COLORS; may be less */ | ||
118 | |||
119 | #endif /* __CURSES_INTERNALS__ */ | ||