SignaturePad constructor
SignaturePad({
- required dynamic onSave(),
- Key? key,
- String saveButtonText = "Save",
- String clearButtonText = "Clear",
- Color backgroundColor = Colors.white,
- Color strokeColor = Colors.black,
- double minStrokeWidth = 1.0,
- double maxStrokeWidth = 4.0,
- Border? border = const Border.fromBorderSide(BorderSide(color: Colors.grey)),
- BorderRadius borderRadius = const BorderRadius.all(Radius.circular(8)),
- EdgeInsets margin = const EdgeInsets.all(10),
- EdgeInsets padding = const EdgeInsets.all(8),
- ButtonStyle? buttonStyle,
- Widget? saveButtonIcon,
- Widget? clearButtonIcon,
- double spacing = 10.0,
- MainAxisAlignment alignment = MainAxisAlignment.center,
- TextStyle? errorTextStyle,
- dynamic onError()?,
- double pixelRatio = 3.0,
- BoxConstraints? constraints,
Implementation
SignaturePad({
required this.onSave,
super.key,
this.saveButtonText = "Save",
this.clearButtonText = "Clear",
this.backgroundColor = Colors.white,
this.strokeColor = Colors.black,
this.minStrokeWidth = 1.0,
this.maxStrokeWidth = 4.0,
this.border = const Border.fromBorderSide(BorderSide(color: Colors.grey)),
this.borderRadius = const BorderRadius.all(Radius.circular(8)),
this.margin = const EdgeInsets.all(10),
this.padding = const EdgeInsets.all(8),
this.buttonStyle,
this.saveButtonIcon,
this.clearButtonIcon,
this.spacing = 10.0,
this.alignment = MainAxisAlignment.center,
this.errorTextStyle,
this.onError,
this.pixelRatio = 3.0,
this.constraints,
});