VSetButtonLoc


 
Name
  VSetButtonLoc - sets the location of the Button Item within a window.
 
Synopsis
  VSetButtonLoc(item, x, y)
  BUTTON *item;
  int x, y;
 
Description
  VSetButtonLoc sets the x,y location of the Button Item within a window. The
location is relative to the window coordinate system. Please note that 
VSetButtonLoc cannot be used for a panel button.
 
Structures
  typedef struct _button {
        Window  win;            /*window in which item resides*/
        short   type;           /*type of button(0=button, 1=toggle, etc..)*/
        short   x,y;            /*location of upper-left corner of item*/
        short   w;              /*width of the item area in fonts*/
        short   h;              /*height of the item area in fonts*/
        short   label_width;    /*width of label in pixels*/
        short   label_height;   /*height of label*/
        short   label_ascent;   /*ascent dimension of font*/
        short   label_x;        /*position of the label*/
        short   label_y;
        short   thick;          /*thickness of frame*/
        short   width;          /*width of item in pixels*/
        short   height;         /*height of item in pixels*/
        int     fw,fh;          /*size of font*/
        char    label[150];     /*label of the button item*/
        short   state;          /*indicates if button item is OFF(0) / ON(1)*/
        short   mode;           /*0=RELEASED, 1=PRESSED*/
        int     (*func)();      /*notify procedure*/
        struct _button *next;   /*next button item*/
  } BUTTON;
 
Return Value
  0 - work successfully.
  266 - invalid Button Item ID.
 
Parameters
  item - ID for the Button Item.
  x, y - new location of the Button Item (within the Item window); if the 
	location is outside the window, it is ignored.
 
Side Effects
  Changes the x,y fields in the Button Item referred to by ID.
 
Entry Conditions
  None.
 
Related Functions
VAddButton.