Main index | Section 3 | Options |
cc [flags] sourcefiles -lpanel -lncurses
PANEL *new_panel(WINDOW *win);
int bottom_panel(PANEL *pan);
int top_panel(PANEL *pan);
int show_panel(PANEL *pan);
void update_panels(void);
int hide_panel(PANEL *pan);
WINDOW *panel_window(const PANEL *pan);
int replace_panel(PANEL *pan, WINDOW *window);
int move_panel(PANEL *pan, int starty, int startx);
int panel_hidden(const PANEL *pan);
PANEL *panel_above(const PANEL *pan);
PANEL *panel_below(const PANEL *pan);
int set_panel_userptr(PANEL *pan, const void *ptr);
const void *panel_userptr(const PANEL *pan);
int del_panel(PANEL *pan);
/* ncurses-extensions */
PANEL *ground_panel(SCREEN *sp);
PANEL *ceiling_panel(SCREEN *sp);
A window is associated with every panel. The panel routines enable you to create, move, hide, and show panels, as well as position a panel at any desired location in the stack.
Panel routines are a functional layer added to curses(3X), make only high-level curses calls, and work anywhere terminfo curses does.
update_panels may be called more than once before a call to doupdate, but doupdate is the function responsible for updating the physical screen.
Except as noted, the pan and window parameters must be non-null. If those are null, an error is returned.
The move_panel function uses mvwin(3X), and will return an error if mvwin returns an error.
The functions show_panel and top_panel are identical in this implementation, and work equally well with displayed or hidden panels. In the native System V implementation, show_panel is intended for making a hidden panel visible (at the top of the stack) and top_panel is intended for making an already-visible panel move to the top of the stack. You are cautioned to use the correct function to ensure compatibility with native panel libraries.
The panel facility was documented in SVr4.2 in Character User Interface Programming (UNIX SVR4.2).
It is not part of X/Open Curses.
A few implementations exist:
» | Systems based on SVr4 source code, e.g., Solaris, provide this library. |
» | ncurses (since version 0.6 in 1993) and PDCurses (since version 2.2 in 1995) provide a panel library whose common ancestor was a public domain implementation by Warren Tucker published in u386mon 2.20 (1990). |
According to Tucker, the SystemV panel library was first released in SVr3.2 (1988), and his implementation helped with a port to SVr3.1 (1987). | |
Several developers have improved each of these; they are no longer the same as Tucker's implementation. | |
» | NetBSD 8 (2018) has a panel library begun by Valery Ushakov in 2015. This is based on the AT&T documentation. |
panel.h interface for the panels library
libpanel.a the panels library itself
Originally written by Warren Tucker <wht@n4hgf.mt-park.ga.us>, primarily to assist in porting u386mon to systems without a native panels library.
Repackaged for ncurses by Zeyd ben-Halim.
Juergen Pfeifer and Thomas E. Dickey revised/improved the library.
panel (3X) |
Main index | Section 3 | Options |
Please direct any comments about this manual page service to Ben Bullock. Privacy policy.
“ | How do you pronounce UNIX ? You Nix ! | ” |