BubbleBox constructor
BubbleBox({
- required Widget child,
- Key? key,
- double pointerBias = 0.5,
- double opacity = 0.5,
- double strokeWidth = 1.2,
- Color color = Colors.black,
- Color strokeColor = Colors.white,
- double borderRadius = 8,
- double peakRadius = 3,
- double pointerWidth = 10,
- double pointerHeight = 6,
- double startPadding = 0,
- double endPadding = 0,
- bool isUpward = true,
- bool isWrapped = true,
- ImageFilter? filter,
- BlendMode blendMode = BlendMode.srcOver,
Implementation
BubbleBox({
required Widget child,
Key? key,
this.pointerBias = 0.5,
this.opacity = 0.5,
this.strokeWidth = 1.2,
this.color = Colors.black,
this.strokeColor = Colors.white,
this.borderRadius = 8,
this.peakRadius = 3,
this.pointerWidth = 10,
this.pointerHeight = 6,
this.startPadding = 0,
this.endPadding = 0,
this.isUpward = true,
this.isWrapped = true,
this.filter,
this.blendMode = BlendMode.srcOver,
}) : super(
key: key,
child: Padding(
padding: isWrapped
? EdgeInsets.only(
top: isUpward ? pointerHeight : 0,
bottom: isUpward ? 0 : pointerHeight) +
EdgeInsets.all(borderRadius)
: EdgeInsets.zero,
child: child,
),
);