1form_hook(3CURSES)         Curses Library Functions         form_hook(3CURSES)
2
3
4

NAME

6       form_hook,    set_form_init,   form_init,   set_form_term,   form_term,
7       set_field_init, field_init, set_field_term, field_term - assign  appli‐
8       cation-specific routines for invocation by forms
9

SYNOPSIS

11       cc [ flag... ] file... -lform  -lcurses  [ library... ]
12       #include <form.h>
13
14
15
16       int set_form_init(FORM *form, void (*func)(FORM*));
17
18
19       void (*form_init)(FORM *form);
20
21
22       int set_form_term(FORM *form, void (*func)(FORM*));
23
24
25       void (*form_term)(FORM *form);
26
27
28       int set_field_init(FORM *form, void (*func)(FORM*));
29
30
31       void (*field_init)(FORM *form);
32
33
34       int set_field_term(FORM *form, void (*func)(FORM*));
35
36
37       void (*field_term)(FORM *form);
38
39

DESCRIPTION

41       These routines allow the programmer to assign application specific rou‐
42       tines to be executed automatically at  initialization  and  termination
43       points in the forms application. The user need not specify any applica‐
44       tion-defined initialization or termination routines at  all,  but  they
45       may  be  helpful  for  displaying  messages  or  page numbers and other
46       chores.
47
48
49       set_form_init() assigns an application-defined initialization  function
50       to  be  called  when  the  form is posted and just after a page change.
51       form_init() returns a pointer to the initialization function, if any.
52
53
54       set_form_term() assigns an application-defined function  to  be  called
55       when  the  form  is unposted and just before a page change. form_term()
56       returns a pointer to the function, if any.
57
58
59       set_field_init() assigns an application-defined function to  be  called
60       when  the  form  is  posted  and  just after the current field changes.
61       field_init() returns a pointer to the function, if any.
62
63
64       set_field_term() assigns an application-defined function to  be  called
65       when  the  form  is unposted and just before the current field changes.
66       field_term() returns a pointer to the function, if any.
67

RETURN VALUES

69       Routines that return pointers always return  NULL  on  error.  Routines
70       that return an integer return one of the following:
71
72       E_OK              The function returned successfully.
73
74
75       E_SYSTEM_ERROR    System error.
76
77

ATTRIBUTES

79       See attributes(5) for descriptions of the following attributes:
80
81
82
83
84       ┌─────────────────────────────┬─────────────────────────────┐
85       │      ATTRIBUTE TYPE         │      ATTRIBUTE VALUE        │
86       ├─────────────────────────────┼─────────────────────────────┤
87       │MT-Level                     │Unsafe                       │
88       └─────────────────────────────┴─────────────────────────────┘
89

SEE ALSO

91       curses(3CURSES), forms(3CURSES), attributes(5)
92

NOTES

94       The  header  <form.h>  automatically  includes the headers  <eti.h> and
95       <curses.h>.
96
97
98
99SunOS 5.11                        31 Dec 1996               form_hook(3CURSES)
Impressum