| GOffice Reference Manual | ||||
|---|---|---|---|---|
| Top | Description | Object Hierarchy | Properties | ||||
GocGroup; GocGroupClass; void goc_group_add_child (GocGroup *parent,GocItem *item); void goc_group_adjust_bounds (GocGroup const *group,double *x0,double *y0,double *x1,double *y1); void goc_group_adjust_coords (GocGroup const *group,double *x,double *y); void goc_group_cairo_transform (GocGroup const *group,cairo_t *cr,double x,double y); void goc_group_clear (GocGroup *group); GocGroup * goc_group_new (GocGroup *parent); void goc_group_remove_child (GocGroup *parent,GocItem *item); void goc_group_set_clip_path (GocGroup *group,GOPath *clip_path,cairo_fill_rule_t clip_rule);
A GocGroup is a GocItem which just contains other items.
The contents of the canvas are stored as a tree where GocGroup items are branches and other items are leafs.
void goc_group_add_child (GocGroup *parent,GocItem *item);
Adds item as a new child to parent.
void goc_group_adjust_bounds (GocGroup const *group,double *x0,double *y0,double *x1,double *y1);
Adds group horizontal offset to x0 and x1, and vertical offset to y0
and y1. This function is called recursively so that when returning x0,
y0, x1, and y1 are absolute coordinates in canvas space,
|
GocGroup |
|
first horizontal coordinate |
|
first vertical coordinate |
|
last horizontal coordinate |
|
last vertical coordinate |
void goc_group_adjust_coords (GocGroup const *group,double *x,double *y);
Adds group horizontal offset to x0, and vertical offset to y0.
This function is called recursively so that when returning x0 and
y0 are absolute coordinates in canvas space,
|
GocGroup |
|
horizontal coordinate |
|
vertical coordinate |
void goc_group_cairo_transform (GocGroup const *group,cairo_t *cr,double x,double y);
Translates cr current context so that operations start at (x,y), which
are group relative coordinates, and is scaled according to the containing
GocCanvas current scale (see goc_canvas_get_pixels_per_unit()). The
translation takes all group ancestors into account.
This function does not call cairo_save().
void goc_group_clear (GocGroup *group);
Destroys all group children.
|
GocGroup |
GocGroup * goc_group_new (GocGroup *parent);
Creates a new GocGroup as a child of parent.
void goc_group_remove_child (GocGroup *parent,GocItem *item);
Removes item from parent. This function will fail if item is not a
child of parent.
void goc_group_set_clip_path (GocGroup *group,GOPath *clip_path,cairo_fill_rule_t clip_rule);
Clips the drawing inside path.
|
GocGroup |
|
GOPath |
|
cairo_fill_rule_t |