SpacingChildSize class
A spacing unit that references the size of a child element.
This allows spacing to be based on the dimensions of another child in the layout, identified by an optional key.
- Implemented types
- Available extensions
Constructors
- SpacingChildSize([Object? key])
-
Creates a child-size-based spacing unit.
const
Properties
Methods
-
clamp(
{SpacingUnit min = const SpacingFixed(0), SpacingUnit max = const SpacingFixed(double.infinity)}) → SpacingUnit -
Available on SpacingUnit, provided by the SpacingUnitExtension extension
Constrains this spacing unit within the specified min and max bounds. -
computeSpacing(
{required ParentLayout parent, required LayoutAxis axis, required double viewportSize}) → double -
Computes the actual spacing value.
override
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toCodeString(
) → String -
Returns a code string representation of this spacing unit.
override
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator *(
Object other) → SpacingUnit -
Available on SpacingUnit, provided by the SpacingUnitExtension extension
Multiplies two spacing units. -
operator +(
SpacingUnit other) → SpacingUnit -
Available on SpacingUnit, provided by the SpacingUnitExtension extension
Adds two spacing units together. -
operator -(
SpacingUnit other) → SpacingUnit -
Available on SpacingUnit, provided by the SpacingUnitExtension extension
Subtracts one spacing unit from another. -
operator /(
SpacingUnit other) → SpacingUnit -
Available on SpacingUnit, provided by the SpacingUnitExtension extension
Divides one spacing unit by another. -
operator ==(
Object other) → bool -
The equality operator.
inherited
-
operator unary-(
) → SpacingUnit -
Available on SpacingUnit, provided by the SpacingUnitExtension extension
Negates this spacing unit (equivalent to 0 - this).