|
NAMEAG_Notebook —
agar notebook container widget
SYNOPSIS#include <agar/core.h> #include <agar/gui.h> DESCRIPTIONTheAG_Notebook widget maintains a set of
AG_Box(3)
containers, only one of which is visible at any given time. The user can
select the visible container by clicking on a tab, or it can be selected
programmatically.
INHERITANCE HIERARCHYAG_Object(3) -> AG_Widget(3) ->AG_Notebook .
INITIALIZATIONAG_Notebook *AG_NotebookNew (AG_Widget
*parent, Uint flags);
The
By default, tabs are drawn at the top of the widget.
enum ag_notebook_tab_alignment { AG_NOTEBOOK_TABS_TOP, AG_NOTEBOOK_TABS_BOTTOM, AG_NOTEBOOK_TABS_LEFT, AG_NOTEBOOK_TABS_RIGHT };
TAB MANAGEMENTAG_NotebookTab *AG_NotebookAdd (AG_Notebook
*nb, const char
*name, enum ag_box_type
type);
The EVENTSTheAG_Notebook widget does not generate any event.
EXAMPLESThe following code fragment creates a notebook with two tabs:AG_Notebook *nb; AG_Notebook *ntab; nb = AG_NotebookNew(parent, AG_NOTEBOOK_EXPAND); { ntab = AG_NotebookAdd(nb, "Tab #1", AG_BOX_VERT); AG_LabelNew(ntab, 0, "This is Tab #1"); ntab = AG_NotebookAdd(nb, "Tab #2", AG_BOX_VERT); AG_LabelNew(ntab, 0, "This is Tab #2"); } SEE ALSOAG_Intro(3), AG_Widget(3), AG_Window(3)HISTORYTheAG_Notebook widget first appeared in Agar 1.0.
Visit the GSP FreeBSD Man Page Interface. |