[Contents] [Index] [Help] [Retrace] [Browse <] [Browse >]

The AddGList() function adds gadgets to Intuition's internal lists but do
not display their imagery.  Subsequently calls to RefreshGList() must be
made to draw the gadgets into the window or requester.

Programs may use RefreshGList() to update the display after making changes
to their gadgets.  The supported changes include (not an exhaustive list):
changing the GFLG_SELECTED flag for boolean gadgets to implement mutually
exclusive gadgets, changing the GadgetText of a gadget to change its
label, changing the GFLG_DISABLED flag, and changing the contents of the
StringInfo structure Buffer of a string gadget.  When making changes to a
gadget, be sure to remove the gadget from the system with RemoveGList()
before altering it.  Remember to add the gadget back and refresh its
imagery.

Boolean gadgets rendered with borders, instead of images, or highlighted
with surrounding boxes (GFLG_GADGHBOX) are handled very simply by
Intuition, and complicated transitions done by the program can get the
rendering out of phase.  Applications should avoid modifying the imagery
and refreshing gadgets that may be highlighted due to selection by the
user.  Such operations may leave pixels highlighted when the gadget is no
longer selected.  The problems with such transitions can often be avoided
by providing imagery, either image or border, that covers all pixels in
the select box.  For GFLG_GADGHIMAGE gadgets, the select imagery should
cover all pixels covered in the normal imagery.

 Updating a Gadget's Imagery    gadget Refresh Function