Upgrade Texinfo from 4.8 to 4.13 on the vendor branch
[dragonfly.git] / contrib / texinfo / info / echo-area.h
1 /* echo-area.h -- Functions used in reading information from the echo area.
2    $Id: echo-area.h,v 1.8 2008/02/26 16:51:05 karl Exp $
3
4    This file is part of GNU Info, a program for reading online documentation
5    stored in Info format.
6
7    Copyright (C) 1993, 1997, 2004, 2007 Free Software Foundation, Inc.
8
9    This program is free software: you can redistribute it and/or modify
10    it under the terms of the GNU General Public License as published by
11    the Free Software Foundation, either version 3 of the License, or
12    (at your option) any later version.
13
14    This program is distributed in the hope that it will be useful,
15    but WITHOUT ANY WARRANTY; without even the implied warranty of
16    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
17    GNU General Public License for more details.
18
19    You should have received a copy of the GNU General Public License
20    along with this program.  If not, see <http://www.gnu.org/licenses/>.
21
22    Written by Brian Fox (bfox@ai.mit.edu). */
23
24 #ifndef INFO_ECHO_AREA_H
25 #define INFO_ECHO_AREA_H
26
27 #define EA_MAX_INPUT 256
28
29 extern int echo_area_is_active, info_aborted_echo_area;
30
31 /* Non-zero means that the last command executed while reading input
32    killed some text. */
33 extern int echo_area_last_command_was_kill;
34
35 extern void inform_in_echo_area (const char *message);
36 extern void echo_area_inform_of_deleted_window (WINDOW *window);
37 extern void echo_area_prep_read (void);
38 extern VFunction *ea_last_executed_command;
39 extern char * info_read_completing_internal (WINDOW *window, const char *prompt,
40     REFERENCE **completions, int force);
41
42 /* Read a line of text in the echo area.  Return a malloc ()'ed string,
43    or NULL if the user aborted out of this read.  WINDOW is the currently
44    active window, so that we can restore it when we need to.  PROMPT, if
45    non-null, is a prompt to print before reading the line. */
46 extern char *info_read_in_echo_area (WINDOW *window, const char *prompt);
47
48 /* Read a line in the echo area with completion over COMPLETIONS.
49    Takes arguments of WINDOW, PROMPT, and COMPLETIONS, a REFERENCE **. */
50 char *info_read_completing_in_echo_area (WINDOW *window,
51     const char *prompt, REFERENCE **completions);
52
53 /* Read a line in the echo area allowing completion over COMPLETIONS, but
54    not requiring it.  Takes arguments of WINDOW, PROMPT, and COMPLETIONS,
55    a REFERENCE **. */
56 extern char *info_read_maybe_completing (WINDOW *window,
57     const char *prompt, REFERENCE **completions);
58
59 extern void ea_insert (WINDOW *window, int count, unsigned char key);
60 extern void ea_quoted_insert (WINDOW *window, int count, unsigned char key);
61 extern void ea_beg_of_line (WINDOW *window, int count, unsigned char key);
62 extern void ea_backward (WINDOW *window, int count, unsigned char key);
63 extern void ea_delete (WINDOW *window, int count, unsigned char key);
64 extern void ea_end_of_line (WINDOW *window, int count, unsigned char key);
65 extern void ea_forward (WINDOW *window, int count, unsigned char key);
66 extern void ea_abort (WINDOW *window, int count, unsigned char key);
67 extern void ea_rubout (WINDOW *window, int count, unsigned char key);
68 extern void ea_complete (WINDOW *window, int count, unsigned char key);
69 extern void ea_newline (WINDOW *window, int count, unsigned char key);
70 extern void ea_kill_line (WINDOW *window, int count, unsigned char key);
71 extern void ea_backward_kill_line (WINDOW *window, int count, unsigned char key);
72 extern void ea_transpose_chars (WINDOW *window, int count, unsigned char key);
73 extern void ea_yank (WINDOW *window, int count, unsigned char key);
74 extern void ea_tab_insert (WINDOW *window, int count, unsigned char key);
75 extern void ea_possible_completions (WINDOW *window, int count, unsigned char key);
76 extern void ea_backward_word (WINDOW *window, int count, unsigned char key);
77 extern void ea_kill_word (WINDOW *window, int count, unsigned char key);
78 extern void ea_forward_word (WINDOW *window, int count, unsigned char key);
79 extern void ea_yank_pop (WINDOW *window, int count, unsigned char key);
80 extern void ea_backward_kill_word (WINDOW *window, int count, unsigned char key);
81 extern void ea_scroll_completions_window (WINDOW *window, int count,
82     unsigned char key);
83
84 #endif /* not INFO_ECHO_AREA_H */