DroidDiagram Programmer's Guide
ContainerNode Class
Remarks See Also
 






Implements nodes that can contain other nodes.

Namespace: com.mindfusion.diagramming
Package: com.mindfusion.diagramming

 Syntax

Java  Copy Code

public class ContainerNode extends DiagramNode implements InplaceEditable

 Remarks

Users can drag nodes into a container interactively. When a dragged node is over a container, the container frame is painted using the HighlightPen property to indicate that the node would be added to the container.

Call the add method to add a node to container programmatically. Call the remove method to remove a node from the container. The getContainer static method returns the container that contains a node.

AutoShrink specifies whether the size of a container should shrink when a node is removed from it. The container node will not shrink to a size smaller than MinimumSize, even if it does not contain any items.

A container node can be folded and unfolded, either interactively or programmatically, as specified through the Foldable and Folded properties. When a container is folded, it occupies a minimal area and its child nodes are hidden. You can get the original size of a folded container using the getUnfoldedSize method.

The Caption property specifies the caption text of a container node, and CaptionBrush specifies its color. Use the CaptionFormat property to define the alignment and position of the caption text. The height of the caption area of a container can be set using the CaptionHeight property.

 Inheritance Hierarchy

java.lang.Object
    com.mindfusion.diagramming.DiagramItem
        com.mindfusion.diagramming.DiagramNode
            com.mindfusion.diagramming.ContainerNode

 See Also

ContainerNode Members
com.mindfusion.diagramming Namespace