Telogis.GeoBase.Canvas.Group |
Canvas.Group inherits from AbstractDOMEntity.
A class for managing and rendering a group of primitive shapes to a VML (Internet Explorer v8 or less) or SVG (Webkit) element. This class renders to a <group> element in VML or <g> element in SVG. Shapes can be added to or removed from a group. A group of shapes can be shown/hidden altogether.
Type | Description |
---|---|
Errors.ArgumentTypeError | If no valid canvas was passed to the Canvas.Group constructor, or any of the shapes passed in isn't an instance of Canvas.Shapes.AbstractShape. |
Name | Description |
---|---|
Canvas.Group(canvas, shapes) | Arguments
|
Name | Description |
---|---|
destroy () | Destroys all shapes of this Canvas.Group, and then destroy the group itself. |
draw () | Displays any changes to the properties of all Canvas.Shapes.AbstractShape in this Canvas.Group. This method is called automatically by Canvas.update. |
hide () | Hide this Canvas.Group. |
pushShape (Canvas.Shapes.AbstractShape shape) | Add a given Canvas.Shapes.AbstractShape to this Canvas.Group. Arguments
|
removeShape (Canvas.Shapes.AbstractShape shape) | Remove a given Canvas.Shapes.AbstractShape from this Canvas.Group. Arguments
|
show () | Show this Canvas.Group. Note if this group's MapLayers.CanvasLayer is hidden, calling this method will not show this group until its MapLayers.CanvasLayer is shown again. |