abstract class %ZEN.SVGComponent.abstractSVGGroup
extends %XML.Adaptor
Base implementation of SVG group behavior.
parameter DEFAULTLAYOUT;
Subclasses can set this to change default layout for a group.
parameter NAMESPACE = "http://www.intersystems.com/zen";
XML namespace used for library components.
property children
as list of svgComponent(XMLELEMENTREF=1,XMLPROJECTION="ELEMENT",XMLTYPECONSTRAINT="CHOICE",ZENSETTING=0);
Set of svg components within this group.
property disabled
as %ZEN.Datatype.boolean [ InitialExpression = 0 ];
If true, this group and its children are disabled.
property layout
as %ZEN.Datatype.string(VALUELIST=",vertical,horizontal,flow,none") [ InitialExpression = ..#DEFAULTLAYOUT ];
Specifies how components within this group should be layed out.
"none" indicates that no layout is provided.
"vertical" indicates that components within this group are layed out vertically.
"horizontal" indicates that components within this group are layed out horizontally.
"flow" indicates that components within this group are placed within multiple rows.
Items are placed horizontally until the width of the container is exceeded and then components are placed on the next row.
method %AddChild(pComponent As %ZEN.Component.object)
Add a child component pComponent to this group.
This is called when the server component tree is being created.
This also adds pComponent to the page that this group
belongs to; this group must be added to a page before adding any child
components to it. In addition, the id property
of the component must be set before calling this method.
method %RemoveChild(pComponent As %ZEN.Component.object)
as %Boolean
Remove child component pComponent from this group.
Returns true if the component was found and removed.
method addChild(component)
[ Language = javascript ]
Client-side method.
Dynamically add a component to this group on the client.
method layoutChildren()
[ Language = javascript ]
Apply layout to the child components within this group.
Updates the value of width and height for this group;
method removeChild(component)
[ Language = javascript ]
Client-side method.
Dynamically remove a component from this group on the client.
final method renderSVG(document, parent)
[ Language = javascript ]
Draw an enclosing SVG group and then render the SVG children of the group.
method setOverlayMode(mode)
[ Language = javascript ]
Set overlay mode for each child of this group.
method setPropertyAll(property, value, value2)
[ Language = javascript ]
Apply the given value to the specified property for
this group and all of its children.
Note that this will not work for 'disabled'; for that
use setProperty.