Class: GOffice::CanvasGroup
- Inherits:
-
CanvasItem
- Object
- CanvasItem
- GOffice::CanvasGroup
- Defined in:
- (unknown)
Instance Method Summary collapse
-
#add_child(item) ⇒ nil
Adds item as a new child to parent.
-
#adjust_bounds(x0, y0, x1, y1) ⇒ nil
Adds group horizontal offset to x0 and x1, and vertical offset to y0 and y1.
-
#adjust_coords(x, y) ⇒ nil
Adds group horizontal offset to x0, and vertical offset to y0.
-
#cairo_transform(cr, x, y) ⇒ nil
Translates cr current context so that operations start at (x,y), which are group relative coordinates, and is scaled according to the containing Goc::Canvas current scale (see goc_canvas_get_pixels_per_unit()).
-
#children ⇒ Array<GOffice::CanvasItem>
the items in group.
-
#clear ⇒ nil
Destroys all group children.
-
#find_child(item) ⇒ Integer
The index of item in group, or -1 if item is not in group.
- #freeze(freeze) ⇒ nil
-
#get_child(n) ⇒ GOffice::CanvasItem
group or nil if n is too big.
-
#new ⇒ GOffice::CanvasGroup
Creates a new Goc::Group as a child of parent.
-
#remove_child(item) ⇒ nil
Removes item from parent.
-
#set_clip_path(clip_path, clip_rule) ⇒ nil
Clips the drawing inside path.
-
#x ⇒ Float
X.
- #x=(x) ⇒ Float
-
#y ⇒ Float
Y.
- #y=(y) ⇒ Float
Methods inherited from CanvasItem
#bounds_changed, #canvas, #canvas=, #copy, #destroy, #distance, #draw, #draw_region, #duplicate, #get_bounds, #grab, #hide, #initialize, #invalidate, #is_visible, #lower, #lower_to_bottom, #operator, #operator=, #parent, #parent=, #raise, #raise_to_top, #set, #show, #style_context, #transform=, #ungrab, #visible=, #window
Constructor Details
This class inherits a constructor from GOffice::CanvasItem
Instance Method Details
#add_child(item) ⇒ nil
Adds item as a new child to parent.
#adjust_bounds(x0, y0, x1, y1) ⇒ nil
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,
#adjust_coords(x, y) ⇒ nil
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,
#cairo_transform(cr, x, y) ⇒ nil
Translates cr current context so that operations start at (x,y), which are group relative coordinates, and is scaled according to the containing Goc::Canvas current scale (see goc_canvas_get_pixels_per_unit()). The translation takes all group ancestors into account.
This function does not call cairo_save().
#children ⇒ Array<GOffice::CanvasItem>
the items in group.
#clear ⇒ nil
Destroys all group children.
#find_child(item) ⇒ Integer
Returns The index of item in group, or -1 if item is not in group.
#freeze(freeze) ⇒ nil
#get_child(n) ⇒ GOffice::CanvasItem
group or nil if n is too big.
#new ⇒ GOffice::CanvasGroup
Creates a new Goc::Group as a child of parent.
#remove_child(item) ⇒ nil
Removes item from parent. This function will fail if item is not a child of parent.
#set_clip_path(clip_path, clip_rule) ⇒ nil
Clips the drawing inside path.
#x ⇒ Float
Returns x.
#x=(x) ⇒ Float
#y ⇒ Float
Returns y.