1curs_touch(3X)                                                  curs_touch(3X)
2
3
4

NAME

6       touchwin, touchline, untouchwin, wtouchln, is_linetouched,
7       is_wintouched - curses refresh control routines
8

SYNOPSIS

10       #include <curses.h>
11       int touchwin(WINDOW *win);
12       int touchline(WINDOW *win, int start, int count);
13       int untouchwin(WINDOW *win);
14       int wtouchln(WINDOW *win, int y, int n, int changed);
15       bool is_linetouched(WINDOW *win, int line);
16       bool is_wintouched(WINDOW *win);
17

DESCRIPTION

19       The touchwin and touchline routines throw away all optimization  infor‐
20       mation about which parts of the window have been touched, by pretending
21       that the entire window has been drawn on.  This is sometimes  necessary
22       when  using  overlapping  windows, since a change to one window affects
23       the other window, but the records of which lines have been  changed  in
24       the other window do not reflect the change.  The routine touchline only
25       pretends that count lines have been changed, beginning with line start.
26
27       The untouchwin routine marks all lines in the window as unchanged since
28       the last call to wrefresh.
29
30       The  wtouchln  routine makes n lines in the window, starting at line y,
31       look as if they have (changed=1) or have not (changed=0)  been  changed
32       since the last call to wrefresh.
33
34       The is_linetouched and is_wintouched routines return TRUE if the speci‐
35       fied line/window was modified since the last call to  wrefresh;  other‐
36       wise  they  return  FALSE.   In addition, is_linetouched returns ERR if
37       line is not valid for the given window.
38

RETURN VALUE

40       All routines return the integer ERR upon failure and an  integer  value
41       other  than  ERR  upon successful completion, unless otherwise noted in
42       the preceding routine descriptions.
43
44       X/Open does not define any error conditions.  In this implementation
45
46          is_linetouched
47               returns an error if the window pointer is null, or if the  line
48               number is outside the window.
49
50               The constant ERR is distinct from TRUE and FALSE, which are the
51               normal return values of this function.   Because  the  function
52               returns a bool, returning ERR (which is neither TRUE nor FALSE)
53               may not be supported by the compiler.
54
55               To provide error-checking and also match  the  X/Open  function
56               prototype, the ERR is provided by a macro named is_linetouched.
57               The actual function returns FALSE when it detects an error.
58
59          wtouchln
60               returns an error if the window pointer is null, or if the  line
61               number is outside the window.
62

PORTABILITY

64       These  functions  were  introduced  by SVr4.  The Solaris curses header
65       file, for instance, defines both an actual function and macro for each.
66       The  macros  give the same result as the actual functions.  SVr4 curses
67       does not check the window parameter win to ensure that it is not  NULL;
68       otherwise this implementation behaves the same as SVr4.
69
70       The XSI Curses standard, Issue 4 describes these functions, but defines
71       no error conditions.
72

NOTES

74       All of these routines except wtouchln may be macros.
75

SEE ALSO

77       curses(3X), curs_refresh(3X), curs_variables(3X).
78
79
80
81                                                                curs_touch(3X)
Impressum