public class FreeFormNodeBuilder
extends java.lang.Object
Constructor and Description |
---|
FreeFormNodeBuilder()
Initializes a new instance of the FreeFormNodeBuilder class.
|
FreeFormNodeBuilder(FreeFormNode instance)
Initializes a new instance of the FreeFormNodeBuilder class.
|
Modifier and Type | Method and Description |
---|---|
FreeFormNodeBuilder |
allowIncomingLinks(boolean value)
Sets a value indicating whether users are allowed to draw links to this node.
|
FreeFormNodeBuilder |
allowOutgoingLinks(boolean value)
Sets a value indicating whether users are allowed to draw links from this node.
|
FreeFormNodeBuilder |
anchorPattern(AnchorPattern value)
Sets the anchor points to which link end points are aligned when
links connect to this node.
|
FreeFormNodeBuilder |
brush(Brush value)
Sets the brush used to fill the item's interior.
|
FreeFormNodeBuilder |
brush(java.awt.Color color) |
FreeFormNodeBuilder |
brush(java.awt.Color color1,
java.awt.Color color2,
int angle) |
FreeFormNodeBuilder |
closed(boolean value)
Sets if the node's shape is closed.
|
FreeFormNodeBuilder |
constraints(NodeConstraints value)
Sets constraints to the node size and movement direction.
|
FreeFormNode |
create()
Creates a new object with the attributes accumulated by this builder.
|
FreeFormNodeBuilder |
enabledHandles(java.util.EnumSet<NodeHandleType> value)
Sets a combination of
NodeHandleType members identifying which manipulation
handles are enabled for a node. |
FreeFormNodeBuilder |
expandable(boolean value)
Sets a value indicating whether users are allowed to expand or collapse
the tree branch that starts from this node.
|
FreeFormNodeBuilder |
expanded(boolean value)
Expands or collapses the tree branch that starts from a node.
|
FreeFormNodeBuilder |
font(java.awt.Font value)
Sets the font used to draw the text of an item.
|
FreeFormNodeBuilder |
font(java.lang.String fontName,
float fontSize) |
FreeFormNode |
get()
Returns an existing object passed for initialization to this builder.
|
FreeFormNodeBuilder |
handlesStyle(HandlesStyle value)
Sets the style of the box selection handles.
|
FreeFormNodeBuilder |
hyperLink(java.lang.String value)
Sets the hyperlink associated with an item.
|
FreeFormNodeBuilder |
id(java.lang.Object value)
Assigns user-defined identifier to this item.
|
FreeFormNodeBuilder |
ignoreLayout(boolean value)
Sets a value indicating whether an item should be ignored
by the automatic layout algorithms.
|
FreeFormNodeBuilder |
layerIndex(int value)
Sets the zero-based index of the layer this item is associated
with, or -1, if the item is not associated with any layer.
|
FreeFormNodeBuilder |
locked(boolean value)
Sets a value indicating whether users are allowed to modify an item.
|
FreeFormNodeBuilder |
obstacle(boolean value)
Sets a value indicating whether the link routing algorithm
should consider this node an obstacle.
|
FreeFormNodeBuilder |
pen(Pen value)
Sets the pen used to draw the item frame lines.
|
FreeFormNodeBuilder |
points(java.util.ArrayList<java.awt.geom.Point2D.Float> value)
Sets the node's outline points.
|
FreeFormNodeBuilder |
printable(boolean value)
Sets a value indicating whether an item will be printed.
|
FreeFormNodeBuilder |
rotationAngle(float value)
Sets the rotation angle of a node.
|
FreeFormNodeBuilder |
selected(boolean value)
Selects or deselects an item.
|
FreeFormNodeBuilder |
shadowBrush(Brush value)
Sets the color of the item's shadow.
|
FreeFormNodeBuilder |
shadowBrush(java.awt.Color color) |
FreeFormNodeBuilder |
shadowBrush(java.awt.Color color1,
java.awt.Color color2,
int angle) |
FreeFormNodeBuilder |
shadowOffsetX(float value)
Sets the horizontal distance between a shadow and the item that casts it.
|
FreeFormNodeBuilder |
shadowOffsetY(float value)
Sets the vertical distance between a shadow and the item that casts it.
|
FreeFormNodeBuilder |
style(DiagramItemStyle value)
Sets the style associated with the item.
|
FreeFormNodeBuilder |
tag(java.lang.Object value)
Assigns user-defined data to an item.
|
FreeFormNodeBuilder |
text(java.lang.String value)
Sets the text label displayed inside this node.
|
FreeFormNodeBuilder |
textBrush(Brush value)
Sets the brush used to paint texts inside the item.
|
FreeFormNodeBuilder |
textBrush(java.awt.Color color) |
FreeFormNodeBuilder |
textBrush(java.awt.Color color1,
java.awt.Color color2,
int angle) |
FreeFormNodeBuilder |
textPadding(Thickness value)
Sets the spacing between the item boundaries and its text.
|
FreeFormNodeBuilder |
toolTip(java.lang.String value)
Sets the tooltip text that should be displayed when the mouse
pointer rests over an item.
|
FreeFormNodeBuilder |
visible(boolean value)
Sets a value indicating whether an item is visible.
|
FreeFormNodeBuilder |
weight(float value)
Sets a weight value used in layout and path-finding algorithms.
|
FreeFormNodeBuilder |
zIndex(int value)
Sets the position of an item within the diagram's Z order.
|
public FreeFormNodeBuilder()
public FreeFormNodeBuilder(FreeFormNode instance)
public FreeFormNodeBuilder zIndex(int value)
value
- An integer value specifying the position of the item
within the diagram Z order.public FreeFormNodeBuilder allowIncomingLinks(boolean value)
value
- true
if incoming links can be drawn to this node,
otherwise false
.public FreeFormNodeBuilder allowOutgoingLinks(boolean value)
value
- true
if outgoing links can be drawn from
this node, otherwise false
.public FreeFormNodeBuilder anchorPattern(AnchorPattern value)
value
- An AnchorPattern
object that defines
the anchor points for this node.public FreeFormNodeBuilder brush(Brush value)
value
- A Brush
-derived object representing the item's brush.public FreeFormNodeBuilder brush(java.awt.Color color)
public FreeFormNodeBuilder brush(java.awt.Color color1, java.awt.Color color2, int angle)
public FreeFormNodeBuilder closed(boolean value)
value
- true if the node should be drawn as a closed polygon and filled, or false otherwise.public FreeFormNodeBuilder constraints(NodeConstraints value)
value
- A NodeConstraints
object.public FreeFormNodeBuilder enabledHandles(java.util.EnumSet<NodeHandleType> value)
NodeHandleType
members identifying which manipulation
handles are enabled for a node. This effectively controls what kind of
modifications users are allowed to perform on this node.value
- A set of NodeHandleType
members.public FreeFormNodeBuilder expandable(boolean value)
value
- true
if the tree branch that starts from this node
can be expanded or collapsed by users, otherwise false
.public FreeFormNodeBuilder expanded(boolean value)
value
- true
if the tree branch that starts from
this node should be expanded, otherwise false
.public FreeFormNodeBuilder font(java.awt.Font value)
value
- A Font
object representing the font
used to draw this item's text.public FreeFormNodeBuilder font(java.lang.String fontName, float fontSize)
public FreeFormNodeBuilder handlesStyle(HandlesStyle value)
value
- A member of the HandlesStyle
enumeration.public FreeFormNodeBuilder hyperLink(java.lang.String value)
value
- A String
containing the hyperlink.public FreeFormNodeBuilder id(java.lang.Object value)
DiagramListener.serializeTag(com.mindfusion.diagramming.SerializeTagEvent)
event.value
- An Object
containing custom data.public FreeFormNodeBuilder ignoreLayout(boolean value)
value
- true
if the item should be ignored by
automatic layout algorithms, otherwise false
.public FreeFormNodeBuilder layerIndex(int value)
value
- An integer value specifying the layer index.public FreeFormNodeBuilder locked(boolean value)
value
- true
if the item should not be modified,
otherwise false
.public FreeFormNodeBuilder obstacle(boolean value)
value
- true
if auto-routed links should go around
this node, otherwise false
.public FreeFormNodeBuilder pen(Pen value)
value
- A Pen
object representing the item's pen.public FreeFormNodeBuilder points(java.util.ArrayList<java.awt.geom.Point2D.Float> value)
value
- An ArrayListpublic FreeFormNodeBuilder printable(boolean value)
value
- true
if the item should be drawn
when printing the diagram, otherwise false
.public FreeFormNodeBuilder rotationAngle(float value)
value
- A float value specifying the node rotation angle.public FreeFormNodeBuilder selected(boolean value)
value
- true
if the item should be selected,
otherwise false
.public FreeFormNodeBuilder shadowBrush(Brush value)
value
- A Brush
object representing the brush of the item's shadow.public FreeFormNodeBuilder shadowBrush(java.awt.Color color)
public FreeFormNodeBuilder shadowBrush(java.awt.Color color1, java.awt.Color color2, int angle)
public FreeFormNodeBuilder shadowOffsetX(float value)
value
- A float value representing the horizontal offset of the item's shadow.public FreeFormNodeBuilder shadowOffsetY(float value)
value
- A float value representing the vertical offset of the item's shadow.public FreeFormNodeBuilder style(DiagramItemStyle value)
public FreeFormNodeBuilder tag(java.lang.Object value)
DiagramListener.serializeTag(com.mindfusion.diagramming.SerializeTagEvent)
event.value
- An Object
containing custom data.public FreeFormNodeBuilder text(java.lang.String value)
value
- A String
containing the label text.public FreeFormNodeBuilder textBrush(Brush value)
public FreeFormNodeBuilder textBrush(java.awt.Color color)
public FreeFormNodeBuilder textBrush(java.awt.Color color1, java.awt.Color color2, int angle)
public FreeFormNodeBuilder textPadding(Thickness value)
value
- A Thickness
instance specifying the size of the padding space left around the text.public FreeFormNodeBuilder toolTip(java.lang.String value)
value
- A String
that contains the tooltip text.public FreeFormNodeBuilder visible(boolean value)
value
- true
if the item should be visible,
otherwise false
.public FreeFormNodeBuilder weight(float value)
value
- A float value representing the item's weight.public FreeFormNode create()
public FreeFormNode get()