Watermark constructor

const Watermark({
  1. Key? key,
  2. required String text,
  3. WatermarkStyle style = const WatermarkStyle(),
  4. bool enabled = true,
  5. required Widget child,
})

Creates a watermark overlay over child.

The text is tiled across the child area according to style. Set enabled to false to hide the watermark without removing the widget from the tree.

Implementation

const Watermark({
  super.key,
  required this.text,
  this.style = const WatermarkStyle(),
  this.enabled = true,
  required this.child,
});