1notcurses_stdplane(3)                                    notcurses_stdplane(3)
2
3
4

NAME

6       notcurses_stdplane - acquire the standard ncplane
7
8   SYNOPSIS
9       #include <notcurses/notcurses.h>
10
11       struct ncplane* notcurses_stdplane(struct notcurses* nc);
12
13       const  struct ncplane* notcurses_stdplane_const(const struct notcurses*
14       nc);
15
16       static inline struct ncplane* notcurses_stddim_yx(struct notcurses* nc,
17       int* restrict y, int* restrict x);
18
19       static  inline  const  struct  ncplane* notcurses_stddim_yx_const(const
20       struct notcurses* nc, int* restrict y, int* restrict x);
21
22       int notcurses_enter_alternate_screen(struct notcurses* nc);
23
24       int notcurses_leave_alternate_screen(struct notcurses* nc);
25

DESCRIPTION

27       notcurses_stdplane returns a handle to the  standard  ncplane  for  the
28       context  nc.   The standard plane always exists, and is always the same
29       size as the screen.  It is an error  to  call  ncplane_destroy(3),  nc‐
30       plane_resize(3),  or  ncplane_move(3) on the standard plane, but it can
31       be freely moved along the z-axis.
32
33       The standard plane's virtual cursor is initialized  to  its  uppermost,
34       leftmost cell unless NCOPTION_PRESERVE_CURSOR is provided (see notcurs‐
35       es_init(3)), in which case it is placed wherever  the  terminal's  real
36       cursor was at startup.
37
38       notcurses_stddim_yx provides the same function, but also writes the di‐
39       mensions of the standard plane (and thus the real drawable  area)  into
40       any non-NULL parameters among y and x.
41
42       notcurses_stdplane_const allows a const notcurses to be safely used.
43
44       A  resize event does not invalidate these references.  They can be used
45       until notcurses_stop(3) is called on the associated nc.
46
47       notcurses_enter_alternate_screen  and  notcurses_leave_alternate_screen
48       only have meaning if the terminal implements the "alternate screen" via
49       the smcup and rmcup terminfo(5) capabilities  (see  the  discussion  of
50       NCOPTION_NO_ALTERNATE_SCREEN  in  notcurses_init(3)).  If not currently
51       using the alternate screen, and assuming it is supported, notcurses_en‐
52       ter_alternate_screen will switch to the alternate screen.  This redraws
53       the contents, repositions the cursor, and usually makes scrollback  un‐
54       available.  The standard plane will have scrolling disabled upon a move
55       to the alternate plane.
56

RETURN VALUES

58       notcurses_enter_alternate_screen will return -1 if the alternate screen
59       is  unavailable.  Both it and notcurses_leave_alternate_screen will re‐
60       turn -1 on an I/O failure.
61
62       Other functions cannot fail when provided  a  valid  struct  notcurses.
63       They will always return a valid pointer to the standard plane.
64

SEE ALSO

66       notcurses(3), notcurses_init(3), notcurses_plane(3), notcurses_stop(3),
67       terminfo(5)
68

AUTHORS

70       nick black <nickblack@linux.com>.
71
72
73
74                                    v2.4.9               notcurses_stdplane(3)
Impressum