@DATABASE "Control of GadTools Gadgets"

@NODE MAIN "Contrôle of GadTools Gadgets"

@FONT Topaz 11@{FG Shine}				    @{u}GADTOOLS GADGETS@{uu}

@{FG Text}
	Gadtools gadgets were created to allows standard creation of GUI.
    There are more complex than intuition ones but more complete.


@{BG Fill}
	@{" _ggad Def Body    " Link _ggad_Def_Body}
	@{" _ggad Def Text    " Link _ggad_Def_Text}
	@{" _ggad Def Id      " Link _ggad_Def_Id}
	@{" _ggad Def Flags   " Link _ggad_Def_Flags}
	@{" _ggad Def User    " Link _ggad_Def_User}		@{" _gt Refresh Wnd   " Link _gt_Refresh_Wnd}
	@{" _ggad Def Vinf    " Link _ggad_Def_Vinf}		@{" _gt Begin Refresh " Link _gt_Begin_Refresh}
	@{" _ggad Def Font    " Link _ggad_Def_Font}		@{" _gt End Refresh   " Link _gt_End_Refresh}

	@{" _ggad What Attrs  " Link _ggad_What_Attrs}
	@{" _ggad Wdef Left   " Link _ggad_Wdef_Left}
	@{" _ggad Wdef Top    " Link _ggad_Wdef_Top}		@{" _ggad Set Attrs   " Link _ggad_Set_Attrs}
	@{" _ggad Wdef Width  " Link _ggad_Wdef_Width}		@{" _ggad Context     " Link _ggad_Context}
	@{" _ggad Wdef Height " Link _ggad_Wdef_Height}		@{" _ggad Create      " Link _ggad_Create}
	@{" _ggad Wdef Text   " Link _ggad_Wdef_Text}		@{" _ggad Draw Box    " Link _ggad_Draw_Box}
	@{" _ggad Wdef Font   " Link _ggad_Wdef_Font}		@{" _ggad Free        " Link _ggad_Free}
	@{" _ggad Wdef Id     " Link _ggad_Wdef_Id}		@{" _ggad Vinf Free   " Link _ggad_Vinf_Free}
	@{" _ggad Wdef Flags  " Link _ggad_Wdef_Flags}		@{" _ggad Vinf Get    " Link _ggad_Vinf_Get}
	@{" _ggad Wdef User   " Link _ggad_Wdef_User}		@{" _ggad Add         " Link _ggad_Add}
	@{" _ggad Wdef Vinf   " Link _ggad_Wdef_Vinf}		@{" _ggad Refresh     " Link _ggad_Refresh}
@ENDNODE

@NODE _ggad_Def_Body "_ggad Def Body"
@{BG Text}@{FG Fill}_ggad Def Body
@{BG Background}@{FG Text}
  This function sets body caracteristics of gadget by default.

	_ggad Def Body X,Y,W,H

	X,Y	-> Left, Top of corner
	W	-> Width
	H	-> Height

@ENDNODE

@NODE _ggad_Def_Text "_ggad Def Text"
@{BG Text}@{FG Fill}_ggad Def Text
@{BG Background}@{FG Text}
  This function sets gadget's text by default.

	_ggad Def Text PTXT

	PTXT	-> String address

@ENDNODE

@NODE _ggad_Def_Id "_ggad Def Id"
@{BG Text}@{FG Fill}_ggad Def Id
@{BG Background}@{FG Text}
  This function sets gadget identifier by default.

	_ggad Def Id ID

	ID	-> Identifier (0 to 65535)

@ENDNODE

@NODE _ggad_Def_Flags "_ggad Def Flags"
@{BG Text}@{FG Fill}_ggad Def Flags
@{BG Background}@{FG Text}
  This function sets gadget flags by default.

	_ggad Def Flags FLAGS

	FLAGS	-> Flags

@ENDNODE

@NODE _ggad_Def_User "_ggad Def User"
@{BG Text}@{FG Fill}_ggad Def User
@{BG Background}@{FG Text}
  This function sets user data by default.

	_ggad Def User DATA

	DATA	-> User data

@ENDNODE

@NODE _ggad_Def_Vinf "_ggad Def Vinf"
@{BG Text}@{FG Fill}_ggad Def Vinf
@{BG Background}@{FG Text}
  This function sets VisualInfo structure by default.

	_ggad Def Vinf VINFO

	VINF	-> Pointer of VisualInfo structure

@ENDNODE

@NODE _ggad_Def_Font "_ggad Def Font"
@{BG Text}@{FG Fill}_ggad Def Font
@{BG Background}@{FG Text}
  This function sets gadget font by default.

	_ggad Def Font TEXTATTR

	TEXTATTR-> Pointer of TextAttr structure

@ENDNODE

@NODE _ggad_Set_Attrs "_ggad Set Attrs"
@{BG Text}@{FG Fill}_ggad Set Attrs
@{BG Background}@{FG Text}
  This function sets gadget attributes.

	_ggad Set Attrs GAD,WND,REQ,TAGLIST

	GAD	-> Pointer of Gadtools Gadget
	WND	-> Pointer of Window
	REQ	-> Pointer of Requeter
	TAGLIST	-> Pointer of TAG List

@ENDNODE

@NODE _ggad_Context "_ggad Context"
@{BG Text}@{FG Fill}_ggad Context
@{BG Background}@{FG Text}
  This function creates a context gadget that contains all necessary datas
for gadtools gadgets. It returns a pointer on this gadget that must be the
first creation of gadtools gadget list.

	CGAD=_ggad Context(GLIST)

	GLIST	-> Pointer of empty gadget structure that will be use like the
		   first gadget.

@ENDNODE

@NODE _ggad_Create "_ggad Create"
@{BG Text}@{FG Fill}_ggad Create
@{BG Background}@{FG Text}
  This function create a gadtools gadget and adds it to the list. it returns
the pointer of created gadget.

 o	GAD=_ggad Create(TYPE,PGAD,TAGLIST)

	This function uses default settings.
	TYPE	-> Gadget type
	PGAD	-> Pointer of previous gadget
	TAGLIST	-> Pointer of TAG list

 o	GAD=_ggad Create(NEWGAD,TYPE,PGAD,TAGLIST)

	NEWGAD	-> Pointer of NewGadget structure
	TYPE	-> Gadget type
	PGAD	-> Pointer of previous gadget
	TAGLIST	-> Pointer of TAG list

@ENDNODE

@NODE _ggad_Draw_Box "_ggad Draw Box"
@{BG Text}@{FG Fill}_ggad Draw Box
@{BG Background}@{FG Text}
  This function draws a beveled box.

	_ggad Draw Box RPORT,X,Y,W,H,TAGLIST

	RPORT	-> RastPort
	X,Y	-> Left, Top corner
	W	-> Width
	H	-> Heigth
	TAGLIST	-> Pointer of TAG list

@ENDNODE

@NODE _ggad_Free "_ggad Free"
@{BG Text}@{FG Fill}_ggad Free
@{BG Background}@{FG Text}
  This function frees gadtools gadget list.

	_ggad Free GLIST

	GLIST	-> Pointer of first gadget

@ENDNODE

@NODE _ggad_Vinf_Free "_ggad Vinf Free"
@{BG Text}@{FG Fill}_ggad Vinf Free
@{BG Background}@{FG Text}
  This function frees VisualInfo structure.

	_ggad Vinf Free VINF

	VINF	-> Pointer of VisualInfo structure

@ENDNODE

@NODE _ggad_Vinf_Get "_ggad Vinf Get"
@{BG Text}@{FG Fill}_ggad Vinf Get
@{BG Background}@{FG Text}
  This function allocates and initializes VisualInfo structure, and then
returns its pointer.

	VINF=_ggad Vinf Get(SCR,TAGLIST)

	SCR	-> Pointer of Screen
	TAGLIST	-> Pointer of TAG list

@ENDNODE

@NODE _gt_Refresh_Wnd "_gt Refresh Wnd"
@{BG Text}@{FG Fill}_gt Refresh Wnd
@{BG Background}@{FG Text}
  This function redraws all contents of a window or a requester.

	_gt Refresh Wnd WND,REQ

	WND	-> Pointer of Window
	REQ	-> Pointer of Requester

@ENDNODE

@NODE _gt_Begin_Refresh "_gt Begin Refresh"
@{BG Text}@{FG Fill}_gt Begin Refresh
@{BG Background}@{FG Text}
  This function indicates that you are beginning the redrawing of the window.

	_gt Begin Refresh WND

	WND	-> Pointer of Window

@ENDNODE

@NODE _gt_End_Refresh "_gt End Refresh"
@{BG Text}@{FG Fill}_gt End Refresh
@{BG Background}@{FG Text}
  This function indicates that the window redrawing is finished.

	_gt End Refresh WND,COMPLETE

	WND	-> Pointer of Window
	COMPLETE-> Boolean value (-1 finish, 0 not yet)

@ENDNODE

@NODE _ggad_Add "_ggad Add"
@{BG Text}@{FG Fill}_ggad Add
@{BG Background}@{FG Text}
  This function adds a linked gadget list to the window one. it returns the
real position of the start of the list in the window one.

	POS=_ggad Add(GAD,WND,POS)

	GAD	-> Pointer of first gadget (GLIST by example)
	WND	-> Pointer of window
	POS	-> Required position

@ENDNODE

@NODE _ggad_Refresh "_ggad Refresh"
@{BG Text}@{FG Fill}_ggad Refresh
@{BG Background}@{FG Text}
  This function refreshes all gadgets starting with specified.

	_ggad Refresh GAD,WND,REQ

	GAD	-> Pointer of Gadget
	WND	-> Pointer of window
	REQ	-> Pointer of Requester

@ENDNODE

@NODE _ggad_What_Attrs "_ggad What Attrs"
@{BG Text}@{FG Fill}_ggad What Attrs
@{BG Background}@{FG Text}
  This function retruns gadget's attributes . In fact, the TAG list specifies
attributes that we want to know and TAG datas, pointers where this values
will be store. This function returns the number of processed attributes.

	NB=_ggad What Attrs(GAD,WND,REQ,TAGLIST)

	GAD	-> Pointer of Gadget
	WND	-> Pointer of window
	REQ	-> Pointer of Requester
	TAGLIST	-> Pointer of TAG List

@ENDNODE

@NODE _ggad_Wdef_Left "_ggad Wdef Left"
@{BG Text}@{FG Fill}_ggad Wdef Left
@{BG Background}@{FG Text}
  This function returns the abscissa by default of top left corner.

	X=_ggad Wdef Left

@ENDNODE

@NODE _ggad_Wdef_Top "_ggad Wdef Top"
@{BG Text}@{FG Fill}_ggad Wdef Top
@{BG Background}@{FG Text}
  This function returns the Y coordinate by default of top left corner.

	Y=_ggad Wdef Top

@ENDNODE

@NODE _ggad_Wdef_Width "_ggad Wdef Width"
@{BG Text}@{FG Fill}_ggad Wdef Width
@{BG Background}@{FG Text}
  This function returns the width by default.

	W=_ggad Wdef Width

@ENDNODE

@NODE _ggad_Wdef_Height "_ggad Wdef Height"
@{BG Text}@{FG Fill}_ggad Wdef Height
@{BG Background}@{FG Text}
  This function returns the height by default.

	H=_ggad Wdef Height

@ENDNODE

@NODE _ggad_Wdef_Text "_ggad Wdef Text"
@{BG Text}@{FG Fill}_ggad Wdef Text
@{BG Background}@{FG Text}
  This function returns the start address of text by default.

	PTXT=_ggad Wdef Text

@ENDNODE

@NODE _ggad_Wdef_Font "_ggad Wdef Font"
@{BG Text}@{FG Fill}_ggad Wdef Font
@{BG Background}@{FG Text}
  This function returns the font by default.

	TATTR=_ggad Wdef Font

@ENDNODE

@NODE _ggad_Wdef_Id "_ggad Wdef Id"
@{BG Text}@{FG Fill}_ggad Wdef Id
@{BG Background}@{FG Text}
  This function returns the identifier by default.

	ID=_ggad Wdef Id

@ENDNODE

@NODE _ggad_Wdef_Flags "_ggad Wdef Flags"
@{BG Text}@{FG Fill}_ggad Wdef Flags
@{BG Background}@{FG Text}
  This function returns the flags by default.

	FLAGS=_ggad Wdef Flags

@ENDNODE

@NODE _ggad_Wdef_User "_ggad Wdef User"
@{BG Text}@{FG Fill}_ggad Wdef User
@{BG Background}@{FG Text}
  This function returns the user data by default.

	USER=_ggad Wdef User

@ENDNODE

@NODE _ggad_Wdef_Vinf "_ggad Wdef Vinf"
@{BG Text}@{FG Fill}_ggad Wdef Vinf
@{BG Background}@{FG Text}
  This function returns the pointer of VisualInfo structure by default.

	VINF=_ggad Wdef Vinf


@ENDNODE

