Interface for a class DiagramShapeStyle
boolean
Enables/disables the bold style of text
string
Sets the font color of a text
string
Sets the fill color of a shape/path
string
Sets the font type of a text
number
Defines the font size of a text
GradientModel
| LinearGradientModel
| RadialGradientModel
Defines the gradient of a shape/path
boolean
Enables/disables the italic style of text
number
Sets the opacity of a shape/path
string
Sets the stroke color of a shape/path
string
Defines the pattern of dashes and spaces to stroke the path/shape
<div id='diagram'></div>
let nodes: NodeModel[] = [{ id: 'node', width: 100, height: 100, offsetX: 100, offsetY: 100,
style: { fill: 'red', strokeColor: 'blue', strokeWidth: 5,
strokeDashArray: '2 2', opacity: 0.6 } as ShapeStyleModel,
}];
let diagram: Diagram = new Diagram({
...
nodes: nodes,
...
});
diagram.appendTo('#diagram');
number
Defines the stroke width of the path/shape
string
Defines how the text should be aligned within its bounds
string
Defines how the text should be decorated. For example, with underline/over line
string
Defines how to handle the text when it exceeds the given size.
string
Defines how the text should be wrapped, when the text size exceeds some specific bounds
string
Defines how the white space and new line characters have to be handled