TextLayerData constructor

TextLayerData({
  1. required String text,
  2. TextStyle? textStyle,
  3. LayerBackgroundMode? colorMode,
  4. double? colorPickerPosition,
  5. Color color = Colors.white,
  6. Color background = Colors.transparent,
  7. TextAlign align = TextAlign.left,
  8. double fontScale = 1.0,
  9. Offset? offset,
  10. double? rotation,
  11. double? scale,
  12. String? id,
  13. bool? flipX,
  14. bool? flipY,
})

Creates a new text layer with customizable properties.

The text parameter specifies the text content of the layer. The colorMode parameter sets the color mode for the text. The colorPickerPosition parameter sets the position of the color picker (if applicable). The color parameter specifies the text color (default is Colors.white). The background parameter defines the background color for the text (default is Colors.transparent). The align parameter determines the text alignment within the layer (default is TextAlign.left). The other optional parameters such as textStyle, offset, rotation, scale, id, flipX, and flipY can be used to customize the position, appearance, and behavior of the text layer.

Implementation

TextLayerData({
  required this.text,
  this.textStyle,
  this.colorMode,
  this.colorPickerPosition,
  this.color = Colors.white,
  this.background = Colors.transparent,
  this.align = TextAlign.left,
  this.fontScale = 1.0,
  super.offset,
  super.rotation,
  super.scale,
  super.id,
  super.flipX,
  super.flipY,
});