Customizing the border of a node shape

Properties for customizing a node border

The border of the shape is controlled by the properties borderColor , borderWidth , borderLineStyle , borderEndCap , borderLineJoin , borderMiterLimit , and borderLineStylePhase .
The borderColor property sets the color used to paint the border.
The other properties are used to create an instance of java.awt.BasicStroke :
  • borderWidth specifies the width of the border.
  • borderLineStyle is used to create dashed or dotted borders. It is an array of floating-point values that specify the lengths of the alternate painted and transparent segments.
  • borderEndCap specifies the shape of the ends of the dash segments.
  • borderLineJoin and borderMiterLimit control the appearance of the border at the angles between two segments.
See the Java™ documentation of the java.awt.BasicStroke class for more details on these properties.

How to control the border of a user-defined business object

The following CSS file creates a dashed blue border with rounded segment ends, visible segments that have a length of 4, and transparent segments that have a length of 2.
#Node {
  borderColor: blue;
  borderLineStyle: "4, 2";
  borderEndCap: CAP_ROUND;
}