TextElementDefinition class final

Standalone text: a frame filled by one body text slot of textType, with no shape surface.

Constructors

TextElementDefinition({String? type, DiagramTextDefinition textType = const PlainTextDefinition(), String? placeholder = 'Type something…', ShapeConnectionDefinition connection = const ShapeConnectionDefinition.outline(), DiagramTextFontSizeRange fontSizeRange = const DiagramTextFontSizeRange(), ShapeTextCreation textCreation = const ShapeTextCreation(clickSizingMode: DiagramTextSizingMode.autoWidth), DiagramSize minimumSize = const DiagramSize(24, diagramDefaultLineHeight), DiagramSize size = const DiagramSize(160, diagramDefaultLineHeight), ShapeBehavior behavior = const ShapeBehavior(textSizing: ShapeTextSizing.growHeight)})

Properties

behavior → ShapeBehavior
final
connection → ShapeConnectionDefinition
final
fontSizeRange → DiagramTextFontSizeRange
final
hashCode → int
The hash code for this object.
no setterinherited
layers → List<ShapeTextLayerDefinition>
The one body text slot, filling the frame.
latefinal
minimumSize → DiagramSize
final
placeholder → String?
Editor-only hint shown while the text is empty.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
size → DiagramSize
final
textCreation → ShapeTextCreation
final
textType → DiagramTextDefinition
The text filling the element.
final
type → String
The registered element type; defaults to textType's type, such as text for plain text and richText for rich text.
final

Methods

createTextStory(String elementId) → TextStory
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
textFor(String slotId) → DiagramTextDefinition
The text filling slotId.
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited