]> ncurses.scripts.mit.edu Git - ncurses.git/blob - man/form.3x
c7c751cb7260dd6e4b6ad308e90f9104c751ac47
[ncurses.git] / man / form.3x
1 '\" t
2 .\" $Id: form.3x,v 0.8 1997/12/14 01:44:04 tom Exp $
3 .TH form 3X ""
4 .SH NAME
5 \fBform\fR - curses extension for programming forms
6 .SH SYNOPSIS
7 \fB#include <form.h>\fR
8 .br
9 .SH DESCRIPTION
10 The \fBform\fR library provides terminal-independent facilities for composing
11 form screens on character-cell terminals.  The library includes: field
12 routines, which create and modify form fields; and form routines, which group
13 fields into forms, display forms on the screen, and handle interaction with the
14 user.
15
16 The \fBform\fR library uses the \fBcurses\fR libraries, and a curses
17 initialization routine such as \fBinitscr\fR must be called before using any of
18 these functions.  To use the \fBform\fR library, link with the options
19 \fB-lform -lcurses\fR.
20
21 .SS Current Default Values for Field Attributes
22
23 The \fBform\fR library maintains a default value for field attributes.  You
24 can get or set this default by calling the appropriate \fBget_\fR or \fBset_\fR
25 routine with a \fBNULL\fR field pointer.  Changing this default with a
26 \fBset_\fR function affects future field creations, but does not change the
27 rendering of fields already created.
28
29 .SS Routine Name Index
30
31 The following table lists each \fBform\fR routine and the name of
32 the manual page on which it is described.
33
34 .TS 
35 l l
36 l l .
37 \fBcurses\fR Routine Name       Manual Page Name
38 =
39 current_field   \fBform_page\fR(3X)
40 data_ahead      \fBform_data\fR(3X)
41 data_behind     \fBform_data\fR(3X)
42 dup_field       \fBform_field_new\fR(3X)
43 dynamic_fieldinfo       \fBform_field_info\fR(3X)
44 field_arg       \fBform_field_validation\fR(3X)
45 field_back      \fBform_field_attributes\fR(3X)
46 field_buffer    \fBform_field_buffer\fR(3X)
47 field_count     \fBform_field\fR(3X)
48 field_fore      \fBform_field_attributes\fR(3X)
49 field_index     \fBform_page\fR(3X)
50 field_info      \fBform_field_info\fR(3X)
51 field_init      \fBform_hook\fR(3X)
52 field_just      \fBform_field_just\fR(3X)
53 field_opts      \fBform_field_opts\fR(3X)
54 field_opts_off  \fBform_field_opts\fR(3X)
55 field_opts_on   \fBform_field_opts\fR(3X)
56 field_pad       \fBform_field_attributes\fR(3X)
57 field_status    \fBform_field_buffer\fR(3X)
58 field_term      \fBform_hook\fR(3X)
59 field_type      \fBform_field_validation\fR(3X)
60 field_userptr   \fBform_field_userptr\fR(3X)
61 form_driver     \fBform_driver\fR(3X)
62 form_fields     \fBform_field\fR(3X)
63 form_init       \fBform_hook\fR(3X)
64 form_opts       \fBform_opts\fR(3X)
65 form_opts_off   \fBform_opts\fR(3X)
66 form_opts_on    \fBform_opts\fR(3X)
67 form_page       \fBform_page\fR(3X)
68 form_request_by_name    \fBform_requestname\fR(3X)
69 form_request_name       \fBform_requestname\fR(3X)
70 form_sub        \fBform_win\fR(3X)
71 form_term       \fBform_hook\fR(3X)
72 form_userptr    \fBform_userptr\fR(3X)
73 form_win        \fBform_win\fR(3X)
74 free_field      \fBform_field_new\fR(3X)
75 free_form       \fBform_new\fR(3X)
76 link_field      \fBform_field_new\fR(3X)
77 link_fieldtype  \fBform_fieldtype\fR(3X)
78 move_field      \fBform_field\fR(3X)
79 new_field       \fBform_field_new\fR(3X)
80 new_form        \fBform_new\fR(3X)
81 new_page        \fBform_new_page\fR(3X)
82 pos_form_cursor \fBform_cursor\fR(3X)
83 post_form       \fBform_post\fR(3X)
84 scale_form      \fBform_win\fR(3X)
85 set_current_field       \fBform_page\fR(3X)
86 set_field_back  \fBform_field_attributes\fR(3X)
87 set_field_buffer        \fBform_field_buffer\fR(3X)
88 set_field_fore  \fBform_field_attributes\fR(3X)
89 set_field_init  \fBform_hook\fR(3X)
90 set_field_just  \fBform_field_just\fR(3X)
91 set_field_opts  \fBform_field_opts\fR(3X)
92 set_field_pad   \fBform_field_attributes\fR(3X)
93 set_field_status        \fBform_field_buffer\fR(3X)
94 set_field_term  \fBform_hook\fR(3X)
95 set_field_type  \fBform_field_validation\fR(3X)
96 set_field_userptr       \fBform_field_userptr\fR(3X)
97 set_fieldtype_arg       \fBform_fieldtype\fR(3X)
98 set_fieldtype_choice    \fBform_fieldtype\fR(3X)
99 set_form_fields \fBform_field\fR(3X)
100 set_form_init   \fBform_hook\fR(3X)
101 set_form_opts   \fBform_field_opts\fR(3X)
102 set_form_page   \fBform_page\fR(3X)
103 set_form_sub    \fBform_win\fR(3X)
104 set_form_term   \fBform_hook\fR(3X)
105 set_form_userptr        \fBform_userptr\fR(3X)
106 set_form_win    \fBform_win\fR(3X)
107 set_max_field   \fBform_field_buffer\fR(3X)
108 set_new_page    \fBform_new_page\fR(3X)
109 unpost_form     \fBform_post\fR(3X)
110 .TE
111 .SH RETURN VALUE
112 Routines that return pointers return \fBNULL\fR on error.  Routines that return
113 an integer return one of the following error codes:
114 .TP 5
115 \fBE_OK\fR
116 The routine succeeded.
117 .TP 5
118 \fBE_CONNECTED\fR
119 The field is already connected to a form.
120 .TP 5
121 \fBE_SYSTEM_ERROR\fR
122 System error occurred (see \fBerrno\fR).
123 .TP 5
124 \fBE_BAD_ARGUMENT\fR
125 Routine detected an incorrect or out-of-range argument.
126 .TP 5
127 \fBE_POSTED\fR
128 The form is already posted.
129 .TP 5
130 \fBE_BAD_STATE\fR
131 Routine was called from an initialization or termination function.
132 .TP 5
133 \fBE_NO_ROOM\fR
134 Form is too large for its window.
135 .TP 5
136 \fBE_NOT_POSTED\fR
137 The form has not been posted.
138 .TP 5
139 \fBE_UNKNOWN_COMMAND\fR
140 The form driver code saw an unknown request code.
141 .TP 5
142 \fBE_INVALID_FIELD\fR
143 Contents of a field are not valid.
144 .TP 5
145 \fBE_NOT_CONNECTED\fR
146 No fields are connected to the form.
147 .TP 5
148 \fBE_REQUEST_DENIED\fR
149 The form driver could not process the request.
150 .SH SEE ALSO
151 \fBcurses\fR(3X) and 3X pages whose names begin "form_" for detailed
152 descriptions of the entry points.
153 .SH NOTES
154 The header file \fB<form.h>\fR automatically includes the header files
155 \fB<curses.h>\fR and \fB<eti.h>\fR.
156
157 In your library list, libform.a should be before libncurses.a; that is,
158 you want to say `-lform -lncurses', not the other way around (which would
159 give you a link error using GNU \fBld\fR(1) and many other linkers).
160 .SH PORTABILITY
161 These routines emulate the System V forms library.  They were not supported on
162 Version 7 or BSD versions.
163 .SH AUTHORS
164 Juergen Pfeifer.  Manual pages and adaptation for ncurses by Eric
165 S. Raymond.
166 .\"#
167 .\"# The following sets edit modes for GNU EMACS
168 .\"# Local Variables:
169 .\"# mode:nroff
170 .\"# fill-column:79
171 .\"# End: