ReactOS  0.4.14-dev-384-g5b37caa
getline.h
Go to the documentation of this file.
1 #ifndef GETLINE_H
2 #define GETLINE_H
3 
4 /* unix systems can #define POSIX to use termios, otherwise
5  * the bsd or sysv interface will be used
6  */
7 
8 #define GL_BUF_SIZE 1024
9 
10 /* Result codes available for gl_get_result() */
11 #define GL_OK 0 /* Valid line of input entered */
12 #define GL_EOF (-1) /* End of input */
13 #define GL_INTERRUPT (-2) /* User hit Ctrl+C */
14 
15 typedef size_t (*gl_strwidth_proc)(char *);
16 typedef int (*gl_in_hook_proc)(char *);
17 typedef int (*gl_out_hook_proc)(char *);
18 typedef int (*gl_tab_hook_proc)(char *, int, int *, size_t);
19 typedef size_t (*gl_strlen_proc)(const char *);
20 typedef char * (*gl_tab_completion_proc)(const char *, int);
21 
22 char *getline(char *); /* read a line of input */
23 void gl_setwidth(int); /* specify width of screen */
24 void gl_setheight(int); /* specify height of screen */
25 void gl_histadd(char *); /* adds entries to hist */
26 void gl_strwidth(gl_strwidth_proc); /* to bind gl_strlen */
28 char *gl_local_filename_completion_proc(const char *, int);
29 void gl_set_home_dir(const char *homedir);
30 void gl_histsavefile(const char *const path);
31 void gl_histloadfile(const char *const path);
32 char *gl_getpass(const char *const prompt, char *const pass, int dsize);
33 int gl_get_result(void);
34 
35 #ifndef _getline_c_
36 
43 extern const char *gl_filename_quote_characters;
46 extern char gl_buf[GL_BUF_SIZE];
47 
48 #endif /* ! _getline_c_ */
49 
50 #endif /* GETLINE_H */
void gl_setheight(int)
Definition: getline.c:547
#define GL_BUF_SIZE
Definition: getline.h:8
gl_strlen_proc gl_strlen
size_t(* gl_strwidth_proc)(char *)
Definition: getline.h:15
int gl_filename_quoting_desired
Definition: getline.c:85
void gl_histloadfile(const char *const path)
Definition: getline.c:1437
char *(* gl_tab_completion_proc)(const char *, int)
Definition: getline.h:20
pass
Definition: typegen.h:24
const char * gl_filename_quote_characters
Definition: getline.c:86
char * gl_local_filename_completion_proc(const char *, int)
Definition: getline.c:2258
gl_in_hook_proc gl_in_hook
Definition: getline.c:80
int gl_ellipses_during_completion
Definition: getline.c:87
int(* gl_tab_hook_proc)(char *, int, int *, size_t)
Definition: getline.h:18
__kernel_size_t size_t
Definition: linux.h:237
gl_tab_completion_proc gl_completion_proc
Definition: getline.c:84
void gl_set_home_dir(const char *homedir)
Definition: getline.c:1985
int(* gl_out_hook_proc)(char *)
Definition: getline.h:17
void gl_tab_completion(gl_tab_completion_proc)
Definition: getline.c:1951
char * getline(char *)
Definition: getline.c:560
gl_out_hook_proc gl_out_hook
Definition: getline.c:81
void gl_histadd(char *)
Definition: getline.c:1314
gl_tab_hook_proc gl_tab_hook
Definition: getline.c:82
void gl_histsavefile(const char *const path)
Definition: getline.c:1408
Definition: services.c:325
void gl_strwidth(gl_strwidth_proc)
int gl_completion_exact_match_extra_char
Definition: getline.c:88
char gl_buf[GL_BUF_SIZE]
Definition: getline.c:89
int gl_get_result(void)
Definition: getline.c:224
void gl_setwidth(int)
Definition: getline.c:532
size_t(* gl_strlen_proc)(const char *)
Definition: getline.h:19
char * gl_getpass(const char *const prompt, char *const pass, int dsize)
Definition: getline.c:2051
int(* gl_in_hook_proc)(char *)
Definition: getline.h:16
unsigned int(__cdecl typeof(jpeg_read_scanlines))(struct jpeg_decompress_struct *
Definition: typeof.h:31