]> ncurses.scripts.mit.edu Git - ncurses.git/blob - man/form.3x
ncurses 4.1
[ncurses.git] / man / form.3x
1 '\" t
2 .TH forms 3X ""
3 .SH NAME
4 \fBforms\fR - curses extension for programming forms
5 .SH SYNOPSIS
6 \fB#include <form.h>\fR
7 .br
8 .SH DESCRIPTION
9 The \fBforms\fR library provides terminal-independent facilities for composing
10 form screens on character-cell terminals.  The library includes: field
11 routines, which create and modify form fields; and form routines, which group
12 fields into forms, display forms on the screen, and handle interaction with the
13 user.
14
15 The \fBforms\fR library uses the \fBcurses\fR libraries, and a curses
16 initialization routine such as \fBinitscr\fR must be called before using any of
17 these functions.  To use the \fBforms\fR library, link with the options
18 \fB-lform -lcurses\fR.
19
20 .SS Current Default Values for Field Attributes
21
22 The \fBforms\fR library maintains a default value for field attributes.  You
23 can get or set this default by calling the appropriate \fBget_\fR or \fBset_\fR
24 routine with a \fBNULL\fR field pointer.  Changing this default with a
25 \fBset_\fR function affects future field creations, but does not change the
26 rendering of fields already created.
27
28 .SS Routine Name Index
29
30 The following table lists each \fBform\fR routine and the name of
31 the manual page on which it is described.
32
33 .TS 
34 l l
35 l l .
36 \fBcurses\fR Routine Name       Manual Page Name
37 =
38 \fBcurrent_field\fR     form_page(3X)
39 \fBdata_ahead\fR        form_data(3X)
40 \fBdata_behind\fR       form_data(3X)
41 \fBdup_field\fR form_field_new(3X)
42 \fBdynamic_fieldinfo\fR form_field_info(3X)
43 \fBfield_arg\fR form_field_validation(3X)
44 \fBfield_back\fR        form_field_attributes(3X)
45 \fBfield_buffer\fR      form_field_buffer(3X)
46 \fBfield_count\fR       form_field(3X)
47 \fBfield_fore\fR        form_field_attributes(3X)
48 \fBfield_index\fR       form_page(3X)
49 \fBfield_info\fR        form_field_info(3X)
50 \fBfield_init\fR        form_hook(3X)
51 \fBfield_just\fR        form_field_just(3X)
52 \fBfield_opts\fR        form_field_opts(3X)
53 \fBfield_opts_off\fR    form_field_opts(3X)
54 \fBfield_opts_on\fR     form_field_opts(3X)
55 \fBfield_pad\fR form_field_attributes(3X)
56 \fBfield_status\fR      form_field_buffer(3X)
57 \fBfield_term\fR        form_hook(3X)
58 \fBfield_type\fR        form_field_validation(3X)
59 \fBfield_userptr\fR     form_field_userptr(3X)
60 \fBform_driver\fR       form_driver(3X)
61 \fBform_fields\fR       form_field(3X)
62 \fBform_init\fR form_hook(3X)
63 \fBform_opts\fR form_opts(3X)
64 \fBform_opts_off\fR     form_opts(3X)
65 \fBform_opts_on\fR      form_opts(3X)
66 \fBform_page\fR form_page(3X)
67 \fBform_request_by_name\fR      form_requestname(3X)
68 \fBform_request_name\fR form_requestname(3X)
69 \fBform_sub\fR  form_win(3X)
70 \fBform_term\fR form_hook(3X)
71 \fBform_userptr\fR      form_userptr(3X)
72 \fBform_win\fR  form_win(3X)
73 \fBfree_field\fR        form_field_new(3X)
74 \fBfree_form\fR form_new(3X)
75 \fBlink_field\fR        form_field_new(3X)
76 \fBlink_fieldtype\fR    link_fieldtype(3X)
77 \fBmove_field\fR        form_field(3X)
78 \fBnew_field\fR form_field_new(3X)
79 \fBnew_form\fR  form_new(3X)
80 \fBnew_page\fR  form_new_page(3X)
81 \fBpos_form_cursor\fR   form_cursor(3X)
82 \fBpost_form\fR form_post(3X)
83 \fBscale_form\fR        form_win(3X)
84 \fBset_current_field\fR form_page(3X)
85 \fBset_field_back\fR    form_field_attributes(3X)
86 \fBset_field_buffer\fR  form_field_buffer(3X)
87 \fBset_field_fore\fR    form_field_attributes(3X)
88 \fBset_field_init\fR    form_hook(3X)
89 \fBset_field_just\fR    form_field_just(3X)
90 \fBset_field_opts\fR    form_field_opts(3X)
91 \fBset_field_pad\fR     form_field_attributes(3X)
92 \fBset_field_status\fR  form_field_buffer(3X)
93 \fBset_field_term\fR    form_hook(3X)
94 \fBset_field_type\fR    form_field_validation(3X)
95 \fBset_field_userptr\fR form_field_userptr(3X)
96 \fBset_fieldtype_arg\fR form_fieldtype(3X)
97 \fBset_fieldtype_choice\fR      form_fieldtype(3X)
98 \fBset_form_fields\fR   form_field(3X)
99 \fBset_form_init\fR     form_hook(3X)
100 \fBset_form_opts\fR     form_field_opts(3X)
101 \fBset_form_page\fR     form_page(3X)
102 \fBset_form_sub\fR      form_win(3X)
103 \fBset_form_term\fR     form_hook(3X)
104 \fBset_form_userptr\fR  form_userptr(3X)
105 \fBset_form_win\fR      form_win(3X)
106 \fBset_max_field\fR     form_field_buffer(3X)
107 \fBset_new_page\fR      form_new_page(3X)
108 \fBunpost_form\fR       form_post(3X)
109 .TE
110 .SH RETURN VALUE
111 Routines that return pointers return \fBNULL\fR on error.  Routines that return
112 an integer return one of the following error codes:
113 .TP 5
114 \fBE_OK\fR
115 The routine succeeded.
116 .TP 5
117 \fBE_CONNECTED\fR
118 The field is already connected to a form.
119 .TP 5
120 \fBE_SYSTEM_ERROR\fR
121 System error occurred (see \fBerrno\fR).
122 .TP 5
123 \fBE_BAD_ARGUMENT\fR
124 Routine detected an incorrect or out-of-range argument.
125 .TP 5
126 \fBE_POSTED\fR
127 The form is already posted.
128 .TP 5
129 \fBE_BAD_STATE\fR
130 Routine was called from an initialization or termination function.
131 .TP 5
132 \fBE_NO_ROOM\fR
133 Form is too large for its window.
134 .TP 5
135 \fBE_NOT_POSTED\fR
136 The form has not been posted.
137 .TP 5
138 \fBE_UNKNOWN_COMMAND\fR
139 The form driver code saw an unknown request code.
140 .TP 5
141 \fBE_INVALID_FIELD\fR
142 Contents of a field are not valid.
143 .TP 5
144 \fBE_NOT_CONNECTED\fR
145 No fields are connected to the form.
146 .TP 5
147 \fBE_REQUEST_DENIED\fR
148 The form driver could not process the request.
149 .SH SEE ALSO
150 \fBcurses\fR(3X) and 3X pages whose names begin "form_" for detailed
151 descriptions of the entry points.
152 .SH NOTES
153 The header file \fB<form.h>\fR automatically includes the header files
154 \fB<curses.h>\fR and \fB<eti.h>\fR.
155
156 In your library list, libform.a should be before libncurses.a; that is,
157 you want to say `-lform -lncurses', not the other way around (which would
158 give you a link error using GNU \fBld\fR(1) and many other linkers).
159 .SH PORTABILITY
160 These routines emulate the System V forms library.  They were not supported on
161 Version 7 or BSD versions.
162 .SH AUTHORS
163 Juergen Pfeifer.  Manual pages and adaptation for ncurses by Eric
164 S. Raymond.
165 .\"#
166 .\"# The following sets edit modes for GNU EMACS
167 .\"# Local Variables:
168 .\"# mode:nroff
169 .\"# fill-column:79
170 .\"# End: