Skip to main content

Module length_percentage

Module length_percentage 

Source
Expand description

<length-percentage> computed values, and related ones.

The over-all design is a tagged pointer, with the lower bit of the pointer being non-zero if it is a non-calc value. See tagged_numeric for the shared implementation details.

Re-exports§

pub use super::calc::ComputedLeaf;

Structs§

CalcLengthPercentage
The representation of a calc() function with mixed lengths and percentages.
CalcLengthPercentageResolution
Result of resolving CalcLengthPercentage
LengthPercentage
A <length-percentage> value. This can be either a <length>, a <percentage>, or a combination of both via calc().

Enums§

AllowAnchorPosResolutionInCalcPercentage
What anchor positioning functions are allowed to resolve in calc percentage values.
LengthPercentageTag
The discriminator used for inline LengthPercentage variants.
Serializable 🔒
An unpacked <length-percentage> that owns the calc() variant, for serialization purposes.
Unpacked
An unpacked <length-percentage> that borrows the calc() variant.
UnpackedMut 🔒
An unpacked <length-percentage> that mutably borrows the calc() variant.

Type Aliases§

CalcAnchorSide
Type for anchor side in calc() and other math fucntions.
CalcNode
The computed version of a calc() node for <length-percentage> values.
NonNegativeLengthPercentage
A wrapper of LengthPercentage, whose value must be >= 0.