BoxDecorationMix class final

Mix representation of BoxDecoration.

Inheritance
Mixed-in types
Annotations
  • @mixable

Constructors

BoxDecorationMix({BoxBorderMix<BoxBorder>? border, BorderRadiusGeometryMix<BorderRadiusGeometry>? borderRadius, BoxShape? shape, BlendMode? backgroundBlendMode, Color? color, DecorationImageMix? image, GradientMix<Gradient>? gradient, List<BoxShadowMix>? boxShadow})
BoxDecorationMix.backgroundBlendMode(BlendMode backgroundBlendMode)
Creates with blend mode only.
BoxDecorationMix.border(BoxBorderMix<BoxBorder> border)
Creates with border only.
BoxDecorationMix.borderRadius(BorderRadiusGeometryMix<BorderRadiusGeometry> borderRadius)
Creates with border radius only.
BoxDecorationMix.boxShadow(List<BoxShadowMix> boxShadow)
Creates a box decoration with only the box shadows specified.
BoxDecorationMix.color(Color color)
Creates with color only.
BoxDecorationMix.create({Prop<BoxBorder>? border, Prop<BorderRadiusGeometry>? borderRadius, Prop<BoxShape>? shape, Prop<BlendMode>? backgroundBlendMode, Prop<Color>? color, Prop<DecorationImage>? image, Prop<Gradient>? gradient, Prop<List<BoxShadow>>? boxShadow})
const
BoxDecorationMix.gradient(GradientMix<Gradient> gradient)
Creates a box decoration with only the gradient specified.
BoxDecorationMix.image(DecorationImageMix image)
Creates a box decoration with only the background image specified.
BoxDecorationMix.shape(BoxShape shape)
Creates with shape only.
BoxDecorationMix.value(BoxDecoration decoration)
Creates a BoxDecorationMix from an existing BoxDecoration.

Properties

$backgroundBlendMode → Prop<BlendMode>?
final
$border → Prop<BoxBorder>?
final
$borderRadius → Prop<BorderRadiusGeometry>?
final
$boxShadow → Prop<List<BoxShadow>>?
no setterinherited
$color → Prop<Color>?
no setterinherited
$gradient → Prop<Gradient>?
no setterinherited
$image → Prop<DecorationImage>?
no setterinherited
$shape → Prop<BoxShape>?
final
defaultValue → BoxDecoration
The default value to use when no explicit value is available.
no setteroverride
hashCode → int
Overrides the hash code getter to compute hash code based on properties.
no setterinherited
isMergeable → bool
True if mergeable with other types.
no setteroverride
mergeKey → Object
The key used to identify compatible types for merging.
no setterinherited
props → List<Object?>
The properties based on which equality and hash code are computed.
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
stringify → bool
Whether to use a detailed string representation of the object.
no setterinherited

Methods

backgroundBlendMode(BlendMode value) → BoxDecorationMix
Returns a copy with the specified background blend mode.
border(BoxBorderMix<BoxBorder> value) → BoxDecorationMix
Returns a copy with the specified border.
override
borderRadius(BorderRadiusGeometryMix<BorderRadiusGeometry> value) → BoxDecorationMix
Returns a copy with the specified border radius.
override
boxShadow(List<BoxShadowMix> value) → BoxDecorationMix
Returns a copy with the specified box shadows.
override
color(Color value) → BoxDecorationMix
Returns a copy with the specified color.
override
debugFillProperties(DiagnosticPropertiesBuilder properties) → void
Add additional properties associated with the node.
inherited
getDiff(Equatable other) → Map<String, String>
Returns a map of properties that differ between this object and another.
inherited
gradient(GradientMix<Gradient> value) → BoxDecorationMix
Returns a copy with the specified gradient.
override
image(DecorationImageMix image) → BoxDecorationMix
Returns a copy with the specified background image.
override
merge(covariant BoxDecorationMix? other) → BoxDecorationMix
Merges with another BoxDecorationMix.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
resolve(BuildContext context) → BoxDecoration
Resolves to BoxDecoration using context.
inherited
shape(BoxShape value) → BoxDecorationMix
Returns a copy with the specified shape.
override
toDiagnosticsNode({String? name, DiagnosticsTreeStyle? style}) → DiagnosticsNode
Returns a debug representation of the object that is used by debugging tools and by DiagnosticsNode.toStringDeep.
inherited
toString({DiagnosticLevel minLevel = DiagnosticLevel.info}) → String
A string representation of this object.
inherited
toStringShort() → String
A brief description of this object, usually just the runtimeType and the hashCode.
inherited

Operators

operator ==(Object other) → bool
Overrides the equality operator to compare based on the properties.
inherited

Static Methods

maybeValue(BoxDecoration? decoration) → BoxDecorationMix?
Creates a BoxDecorationMix from a nullable BoxDecoration.
override