The form library uses the curses libraries. To use the form library, link with the options -lform -lcurses.
Your program should set up the locale, e.g.,
setlocale(LC_ALL, "");
so that input/output processing will work.
A curses initialization routine such as initscr must be called before using any of these functions.
curses Routine Name | Manual Page Name |
current_field | page(3FORM) |
data_ahead | data(3FORM) |
data_behind | data(3FORM) |
dup_field | field_new(3FORM) |
dynamic_field_info | field_info(3FORM) |
field_arg | field_validation(3FORM) |
field_back | field_attributes(3FORM) |
field_buffer | field_buffer(3FORM) |
field_count | field(3FORM) |
field_fore | field_attributes(3FORM) |
field_index | page(3FORM) |
field_info | field_info(3FORM) |
field_init | hook(3FORM) |
field_just | field_just(3FORM) |
field_opts | field_opts(3FORM) |
field_opts_off | field_opts(3FORM) |
field_opts_on | field_opts(3FORM) |
field_pad | field_attributes(3FORM) |
field_status | field_buffer(3FORM) |
field_term | hook(3FORM) |
field_type | field_validation(3FORM) |
field_userptr | field_userptr(3FORM) |
form_driver | driver(3FORM) |
form_driver_w | driver(3FORM)* |
form_fields | field(3FORM) |
form_init | hook(3FORM) |
form_opts | opts(3FORM) |
form_opts_off | opts(3FORM) |
form_opts_on | opts(3FORM) |
form_page | page(3FORM) |
form_request_by_name | requestname(3FORM)* |
form_request_name | requestname(3FORM)* |
form_sub | win(3FORM) |
form_term | hook(3FORM) |
form_userptr | userptr(3FORM) |
form_win | win(3FORM) |
free_field | field_new(3FORM) |
free_fieldtype | fieldtype(3FORM) |
free_form | new(3FORM) |
link_field | field_new(3FORM) |
link_fieldtype | fieldtype(3FORM) |
move_field | field(3FORM) |
new_field | field_new(3FORM) |
new_fieldtype | fieldtype(3FORM) |
new_form | new(3FORM) |
new_page | new_page(3FORM) |
pos_form_cursor | cursor(3FORM) |
post_form | post(3FORM) |
scale_form | win(3FORM) |
set_current_field | page(3FORM) |
set_field_back | field_attributes(3FORM) |
set_field_buffer | field_buffer(3FORM) |
set_field_fore | field_attributes(3FORM) |
set_field_init | hook(3FORM) |
set_field_just | field_just(3FORM) |
set_field_opts | field_opts(3FORM) |
set_field_pad | field_attributes(3FORM) |
set_field_status | field_buffer(3FORM) |
set_field_term | hook(3FORM) |
set_field_type | field_validation(3FORM) |
set_field_userptr | field_userptr(3FORM) |
set_fieldtype_arg | fieldtype(3FORM) |
set_fieldtype_choice | fieldtype(3FORM) |
set_form_fields | field(3FORM) |
set_form_init | hook(3FORM) |
set_form_opts | field_opts(3FORM) |
set_form_page | page(3FORM) |
set_form_sub | win(3FORM) |
set_form_term | hook(3FORM) |
set_form_userptr | userptr(3FORM) |
set_form_win | win(3FORM) |
set_max_field | field_buffer(3FORM) |
set_new_page | new_page(3FORM) |
unfocus_current_field | page(3FORM)* |
unpost_form | post(3FORM) |
In your library list, libform.a should be before libncurses.a; that is, you want to say ``-lform -lncurses'', not the other way around (which would give you a link error when using static libraries).
The menu facility was documented in SVr4.2 in Character User Interface Programming (UNIX SVR4.2).
It is not part of X/Open Curses.
Aside from ncurses, there are few implementations:
.IP • 4
systems based on SVr4 source code, e.g., Solaris.
.IP • 4
NetBSD curses.
A few functions in this implementation are extensions added for ncurses, but not provided by other implementations, e.g., form_driver_w, unfocus_current_field.
This describes ncurses version 6.4 (patch 20221231).