window parentwindow(control c); /* where is this control? */ void show(control c); /* make visible */ void hide(control c); /* make invisible */ int isvisible(control c); /* is this visible? */ void enable(control c); /* allow user to use it */ void disable(control c); /* user cannot use it */ int isenabled(control c); /* can user user it? */ void check(control c); /* check box, radio or menu */ void uncheck(control c); /* uncheck it */ int ischecked(control c); /* is it checked? */ void highlight(control c); /* highlight the control */ void unhighlight(control c); /* return to normal */ int ishighlighted(control c); /* is it highlighted? */ void flashcontrol(control c); /* highlight then unhighlight */ void activatecontrol(control c); /* call action function */ void setvalue(control c, int value); /* set integer */ int getvalue(control c); /* return integer */ void setdata(control c, void *data); /* set pointer */ void * getdata(control c); /* return pointer */ void setforeground(control c, rgb fg); /* change fg colour */ rgb getforeground(control c); /* find fg colour */ void setbackground(control c, rgb bg); /* change bg colour */ rgb getbackground(control c); /* find bg colour */ void settextfont(control c, font f); /* change font */ font gettextfont(control c); /* find font */ void clear(control c); /* clear to bg colour */ void draw(control c); /* draw the control */ void redraw(control c); /* clear then draw it */ void resize(control c, rect r); /* change size and location */ int getwidth(control c); /* return width */ int getheight(control c); /* return height */ rect getrect(control c); /* return rectangle */ int getdepth(control c); /* return pixel depth */
The above is a list of the functions which will work on many different kinds of controls and windows. See the individual sections for details on each function.