DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH PRINT BOOK
 
ETI panels

Fetching panels above or below given panels

The following functions return a pointer to the panel immediately above or below the given panel. They are helpful in walking the panel deck from top to bottom or vice versa.

SYNOPSIS

   PANEL *panel_above (panel)
   PANEL *panel;           /* Get panel above this one */
   

PANEL *panel_below (panel) PANEL *panel; /* Get panel below this one */

Because hidden panels have no depth, they are excluded from these traversals.

Function panel_above returns the panel immediately above the given panel. If its argument is NULL, it returns the bottommost panel. The function returns NULL if the given panel is on top or hidden, or if there are no visible panels.

Function panel_below returns the panel immediately below the given panel. If its argument is NULL, it returns the topmost panel. The function returns NULL if the given panel is on the bottom of the deck of panels or hidden, or if there are no visible panels at all. There may be no visible panels at all if

If you want to do something to all panels or to search all of them for one with a particular attribute, you can place one of these functions in a loop. For example, to hide all panels (perhaps to display stdscr alone), you can write
   {
    PANEL *panel, *pnl;
   

for (panel = panel_above (NULL); panel; panel = panel_above(pnl)) { pnl = panel; hide_panel(panel); } }


Next topic: Setting and fetching the panel user pointer
Previous topic: Reinstating panels

© 2004 The SCO Group, Inc. All rights reserved.
UnixWare 7 Release 7.1.4 - 27 April 2004