NeumorphicContainerPainter constructor
NeumorphicContainerPainter({
- Gradient? gradient,
- List<
Shadow> shadows = const <Shadow>[], - List<
Shadow> innerShadows = const <Shadow>[], - ShapeBorder shape = const ContinuousRectangleBorder(),
- double blur = 0,
- double borderBlur = 0,
- Color color = const Color.fromARGB(0, 0, 0, 0),
- double strokeWidth = 0,
- Gradient? borderGradient,
- Color? accentColor,
- double accentIntensity = 0,
- Alignment? accentAlignment,
Implementation
NeumorphicContainerPainter(
{Gradient? gradient,
List<Shadow> shadows = const <Shadow>[],
List<Shadow> innerShadows = const <Shadow>[],
ShapeBorder shape = const ContinuousRectangleBorder(),
double blur = 0,
double borderBlur = 0,
Color color = const Color.fromARGB(0, 0, 0, 0),
double strokeWidth = 0,
Gradient? borderGradient,
Color? accentColor,
double accentIntensity = 0,
Alignment? accentAlignment}) {
shadowPainter = NeumorphicShadowPainter(
shadows: shadows, shape: shape, strokeWidth: strokeWidth);
surfacePainter = NeumorphicSurfacePainter(
shape: shape,
gradient: gradient,
color: color,
borderGradient: borderGradient,
blur: blur,
borderBlur: borderBlur,
strokeWidth: strokeWidth);
if (accentColor != null && accentAlignment != null && accentIntensity > 0) {
accentPainter = NeumorphicAccentPainter(
alignment: accentAlignment,
value: accentIntensity,
color: accentColor,
shape: shape,
strokeWidth: strokeWidth);
}
innerShadowPainter = NeumorphicInnerShadowPainter(
innerShadows: innerShadows, shape: shape, strokeWidth: strokeWidth);
}