CreateContext
SYNOPSIS
CreateContext(glistpointer)
struct Gadget * CreateContext(struct Gadget **);
DESCRIPTION
Creates a virtual first gadget to which all following gadgets must be
linked
INPUTS
glistpointer - pointer to a pointer to the virtual gadget. Use the
gadget pointer as NewWindow->FirstGadget or in
AddGList(). The gadget pointer must be initialized
to NULL before CreateContext() is called
RESULT
A point to the first gadget or NULL, if there was an error
CreateGadgetA
SYNOPSIS
CreateGadgetA(kind, previous, ng, taglist)
struct Gadget * CreateGadgetA(ULONG, struct Gadget *, struct NewGadget *, struct TagItem *);
DESCRIPTION
Creates a gadtools gadget
INPUTS
kind - Kind of gadget. See <libraries/gadtools.h> for a list of
all possible kinds.
previous - Pointer to the previous gadget in gadget-list. Create the
first "gadget" with CreateContext(). This may be NULL, in
which case CreateGadgetA() fails.
ng - Pointer to struct NewGadget. See <libraries/gadtools.h>.
taglist - Additional tags. See <libraries/gadtools.h>
RESULT
A pointer to a gadget or NULL to indicate an error
SEE ALSO
CreateMenusA
SYNOPSIS
CreateMenusA(newmenu, tagList)
struct Menu * CreateMenusA(struct NewMenu *, struct TagItem *);
DESCRIPTION
CreateMenusA() creates a complete menu or parts of a menu
INPUTS
newmenu - pointer to struct NewMenu
taglist - additional tags
RESULT
A pointer to a menu structure
NOTES
CreateMenusA() stores no position information in the menu structure.
You need to call LayoutMenusA() to retrieve them.
The strings supplied for the menu are not copied into a private
buffer. Therefore they must be preserved, until FreeMenus() was
called.
SEE ALSO
DrawBevelBoxA
SYNOPSIS
DrawBevelBoxA(rport, left, top, width, height, taglist)
void DrawBevelBoxA(struct RastPort *, WORD, WORD, WORD, WORD, struct TagItem *);
DESCRIPTION
DrawBevelBoxA() does just that. It draws a bevelled box
INPUTS
rport - rastport, in which the box should be drawn
left - left edge of the box
top - top edge of the box
width - width of the box
height - height og the box
taglist - additional tags
NOTES
Boxes drawn with DrawBevelBox() aren't refreshed automatically.
You have to refresh them yourself.
DrawBevelBoxA() might modify the rastport to guarantee fast drawing.
FreeGadgets
SYNOPSIS
FreeGadgets(glist)
VOID FreeGadgets(struct Gadget *);
DESCRIPTION
Frees all gadtools gadgets in a linked list of gadgets
INPUTS
glist - pointer to the first gadget to be freed, may be NULL
SEE ALSO
FreeMenus
SYNOPSIS
FreeMenus(menu)
VOID FreeMenus(struct Menu *);
DESCRIPTION
Frees the menus allocated by CreateMenusA
INPUTS
menu - pointer to the menu (or first MenuItem) to be freed, may be NULL
SEE ALSO
FreeVisualInfo
SYNOPSIS
FreeVisualInfo(vi)
void FreeVisualInfo(APTR);
DESCRIPTION
FreeVisualInfo() frees a visual info structure created with
GetVisualInfo
INPUTS
vi - the visual info structure to free, may be NULL
SEE ALSO
GT_BeginRefresh
SYNOPSIS
GT(win)
void GT(struct Window *);
DESCRIPTION
Refreshes the given window. This function must be used instead
of BeginRefresh(), if gadtools-gadgets are used. When you are
finished with refreshing the window, you must call GT_EndRefresh
INPUTS
win - window to refresh
NOTES
Due to the internal structure of gadtools, it is not possible
to use WFLG_NOCAREREFRESH with windows, which use gadtools-
gadgets.
You should simple rendering functions between GT_BeginRefresh() and
GT_EndRefresh() only. Do not render or change any gadgets.
EXAMPLE
case IDCMP_REFRESHWINDOW:
GT_BeginRefresh(mywin);
GT_EndRefresh(mywin, TRUE
SEE ALSO
GT_EndRefresh
SYNOPSIS
GT(win, complete)
void GT(struct Window *, BOOL);
DESCRIPTION
GT_EndRefresh() must be called, when a refresh initiated with
GT_BeginRefresh() is done
INPUTS
win - the refreshed window
complete - TRUE, if refreshing is finished
SEE ALSO
GT_FilterIMsg
SYNOPSIS
GT(imsg)
struct IntuiMessage * GT(struct IntuiMessage *);
DESCRIPTION
Processes an intuition message. Normally, you should not use this
function and call GT_GetIMsg() instead. If this functions returns
with a value != NULL, you have to call GT_PostFilterIMsg(), when
you are done with processing the message. If it return a NULL
pointer, you have to ReplyMsg() the message, you passed to
GT_FilterIMsg
INPUTS
imsg - pointer to the intuition message to process
RESULT
Either a pointer to a processed intuition message or NULL, in which
case the message had only meaning to gadtools
SEE ALSO
GT_GetGadgetAttrsA
SYNOPSIS
GT(gad, win, req, taglist)
LONG GT(struct Gadget *, struct Window *, struct Requester *, struct TagItem *);
DESCRIPTION
Get a list of attributes from a specific gadget
INPUTS
gad - the gadget from which to get attributes
win - the window, in which the gadget is
req - the requester, in which the gadget is, or NULL
taglist - the list of attributes to get. ti_Tag specifies the attribute
and ti_Data is a pointer to an IPTR, where the data is to be
stored
RESULT
The number of attributes, which were filled correctly
SEE ALSO
GT_GetIMsg
SYNOPSIS
GT(intuiport)
struct IntuiMessage * GT(struct MsgPort *);
DESCRIPTION
You must use this function instead of exec.library/GetMsg() to get
messages from a window, if you are using gadtools gadgets. After you
are done with reading the message, you have to call GT_ReplyIMsg
INPUTS
intuiport - UserPort of the window
RESULT
A pointer to a message or NULL, if there was no message or the messages
had only a meaning to gadtools
SEE ALSO
GT_PostFilterIMsg
SYNOPSIS
GT(modimsg)
struct IntuiMessage * GT(struct IntuiMessage *);
DESCRIPTION
Restores an intuition message formerly changed with GT_FilterIMsg
INPUTS
modimsg - The message returned from GT_FilterIMsg(). May be NULL
RESULT
The original intuition message or NULL, if NULL was passed in
SEE ALSO
GT_RefreshWindow
SYNOPSIS
GT(win, req)
void GT(struct Window *, struct Requester *);
DESCRIPTION
You have to call this function as soon as a window containing
gadtools gadgets was opened or after you have performed a
RefreshGList
INPUTS
win - Window to refresh.
req - Not used. Provide NULL for now
GT_ReplyIMsg
SYNOPSIS
GT(imsg)
void GT(struct IntuiMessage *);
DESCRIPTION
Replies a message gotten via GT_GetIMsg
INPUTS
imsg - The message to reply
SEE ALSO
GT_SetGadgetAttrsA
SYNOPSIS
GT(gad, win, req, tagList)
void GT(struct Gadget *, struct Window *, struct Requester *, struct TagItem *);
DESCRIPTION
Change the attribute of the given gadget according to the
attributes chosen in the tag list. If an attribute is not
provided in the tag list, its value remains unchanged
INPUTS
gad - Gadget, for which the specified attributes should be set for.
win - Window, in which the gadget is.
req - Not used. Specify NULL for now.
tagList - List of attributes to set
RESULT
The gadget may be set to the specified attributes
SEE ALSO
GetVisualInfoA
SYNOPSIS
GetVisualInfoA(screen, tagList)
APTR GetVisualInfoA(struct Screen *, struct TagItem *);
DESCRIPTION
GetVisualInfoA() creates a visual info structure, which is needed
by several gadtools functions. When you're done using it, you have
to call FreeVisualInfo
INPUTS
screen - pointer to the screen to create a visual info structure for
(may be NULL)
taglist - additional tags (none defined, yet
RESULT
A (private) visual info structure. NULL indicates an error
SEE ALSO
LayoutMenuItemsA
SYNOPSIS
LayoutMenuItemsA(menuitem, vi, tagList)
BOOL LayoutMenuItemsA(struct MenuItem *, APTR, struct TagItem *);
INPUTS
menuitem - Menu item to be layouted.
vi - Visual info to layout the menu item for.
tagList - Additional tags
RESULT
FALSE, if an error occured
SEE ALSO
LayoutMenusA
SYNOPSIS
LayoutMenusA(menu, vi, tagList)
BOOL LayoutMenusA(struct Menu *, APTR, struct TagItem *);
INPUTS
menu - Menu to be layouted.
vi - Visual info to layout the menu for.
tagList - Additional tags
RESULT
FALSE, if an error occured
SEE ALSO