Xforms4Perl

 view release on metacpan or  search on metacpan

X11/Xforms/Xforms.h  view on Meta::CPAN

/*
 * Mirror of FL_FORM structure that gives fields as arrays
 * - obviously pretty vulnerable to changes!!!
 */

typedef struct 
{
    void *fdui;			/* for fdesign              */
    void *u_vdata;		/* for application          */
#if FL_INCLUDE_VERSION >= 87
	char *u_cdata;
#endif
    long u_ldata;

    char *label;		/* window title             */
    unsigned long window;	/* X resource ID for window */
    FL_Coord	flf_flc[6];
    /* FL_Coord x, y, w, h;	/* current geometry info    */
    /* FL_Coord hotx, hoty;	/* hot-spot of the form     */

    FL_OBJECT *flf_flo[3];

X11/Xforms/Xforms.h  view on Meta::CPAN

/*
 * Mirror of FL_OBJECT structure that gives fields as arrays
 * - obviously pretty vulnerable to changes!!!
 */

typedef struct
{
    struct forms_ *form;	/* the form this object belong        */
    void *u_vdata;		/* anything user likes                */
#if FL_INCLUDE_VERSION >= 87
	char *u_cdata;
#endif
    long u_ldata;		/* anything user lines                */

    int flo_int2[3];
/*    int objclass;		/* class of object, button, slider etc */
/*    int type;			/* type within the class              */
/*    int boxtype;		/* what kind of box type              */
    FL_Coord flo_flc[5];
/*    FL_Coord x, y, w, h;	/* obj. location and size             */
/*    FL_Coord bw;*/

X11/Xforms/Xforms.h  view on Meta::CPAN

/*    int input;*/
/*    int wantkey;*/
/*    int radio;*/
/*    int automatic;*/
/*    int redraw;*/
/*    int visible;*/
/*    int clip;*/
    unsigned long click_timeout;
    void *c_vdata;		/* for class use  */
#if FL_INCLUDE_VERSION >= 87
	char *c_cdata;		/* for class use  */
#endif
    long c_ldata;		/* for class use  */
#if FL_INCLUDE_VERSION >= 87
    unsigned int spec_size;	/* for internal use         */
    FL_COLOR aux_col1, aux_col2;/* aux colors               */
    FL_COLOR dbl_background;    /* double buffer background */
	int how_return;
#endif
    int reserved[6];           /* for future use */

X11/Xforms/Xforms.pm.skel  view on Meta::CPAN

 h                 rw
 has_auto          rw
 hotx              rw
 hoty              rw
 icon_mask         rw
 icon_pixmap       rw
 label             rw
 last              ro
 prop              rw
 top               rw
 u_cdata           rw     
 u_ldata           rw    
 u_vdata           rw    
 use_pixmap        rw
 visible           rw
 vmode             rw
 w                 rw
 window            ro
 wm_border         rw
 x                 rw
 y                 rw

Be warned that the u_cdata field is treated exactly as 
defined - as a character string - and not as a void pointer. Therefore
when writing its value from Perl, be sure to provide a valid character 
string.

=item FL_OBJECT

 active            rw
 align             rw
 argument          rw
 automatic         rw

X11/Xforms/Xforms.pm.skel  view on Meta::CPAN

 nwgravity         rw
 objclass          rw
 parent            ro
 prev              ro
 pushed            rw
 radio             rw
 redraw            rw
 resize            rw
 segravity         rw
 type              rw
 u_cdata           rw
 u_ldata           rw    
 u_vdata           rw
 use_pixmap        rw
 visible           rw
 w                 rw
 wantkey           rw
 window            ro
      (virtual field equivalent to $obj->form->window)
 x                 rw
 y                 rw

Be warned that the u_cdata field is treated exactly as 
defined - as a character string - and not as a void pointer. Therefore
when writing its value from Perl, be sure to provide a valid character 
string.

=item FL_IOPT

All fields in this structure are available as read-
write fields. In addition, there is an extra method
provided that returns a reference to a blank FL_IOPT 
object:

X11/Xforms/Xforms.xs  view on Meta::CPAN

			ObjRWfld(((FLF_ARRAY *)form)->flf_int[ix]);
		}
	}
	OUTPUT:
	RETVAL


char * 
fl_form_label(...)
	ALIAS:
		u_cdata = 1
	CODE:
	{
		int	rw;
		FLForm * 	form; 

		rw = update_field(items);
		form = (FLForm *)chk_bless(ST(0), X11XformsFLForm);
		
		if (ix == 0)
		{
			RETVAL = form->label;
			if (rw)
				form->label = SvPV(ST(1),na);
		}
		else
#if FL_INCLUDE_VERSION < 87
			croak("Field \"%s\" not in FL_FORM structure in your version of xforms", GvNAME(CvGV(cv)));
#else
		{
			RETVAL = form->u_cdata;
			if (rw)
				form->u_cdata = SvPV(ST(1),na);
		}
#endif
	}
	OUTPUT:
	RETVAL

FLObject *
fl_form_first(form)
	FLForm *	form
	ALIAS:

X11/Xforms/Xforms.xs  view on Meta::CPAN

			break;
#endif
		}
	}
	OUTPUT:
	RETVAL

char *
fl_object_label(...)
	ALIAS:
		u_cdata	= 1
	CODE:
	{
				int     rw;
		FLObject * 	object; 

		rw = update_field(items);
		object = (FLObject *)chk_bless(ST(0), X11XformsFLObject);
		
		if (ix == 0)
		{
			RETVAL = object->label;
			if (rw)
				object->label = SvPV(ST(1),na);
		}
		else
#if FL_INCLUDE_VERSION < 87
			croak("Field \"%s\" not in FL_OBJECT structure in your version of xforms", GvNAME(CvGV(cv)));
#else
		{
			RETVAL = object->u_cdata;
			if (rw)
				object->u_cdata = SvPV(ST(1),na);
		}
#endif
	}
	OUTPUT:
	RETVAL

Window
fl_object_window(object)
	FLObject *	object
	CODE:



( run in 0.525 second using v1.01-cache-2.11-cpan-454fe037f31 )