typedef struct _GooDemoItem GooDemoItem;
typedef struct _GooDemoItemClass GooDemoItemClass;
+typedef void (*GooDemoItemPaintFunc) (cairo_t *cr, void *, double width, double height);
+
struct _GooDemoItem
{
GooCanvasItemSimple parent_object;
-
- gdouble x, y, width, height;
+ double width;
+ double height;
+ GooDemoItemPaintFunc paint;
+ void *closure;
};
struct _GooDemoItemClass
GType goo_demo_item_get_type (void) G_GNUC_CONST;
-GooCanvasItem* goo_demo_item_new (GooCanvasItem *parent,
- gdouble x,
- gdouble y,
- gdouble width,
- gdouble height,
+GooCanvasItem* goo_demo_item_new (GooCanvasItem *parent,
+ gdouble x,
+ gdouble y,
+ gdouble width,
+ gdouble height,
+ GooDemoItemPaintFunc paint,
+ void *closure,
...);
+
G_END_DECLS
#endif /* __GOO_DEMO_ITEM_H__ */