Class DimFill
Represents a dimension that fills the dimension, leaving the specified margin.
public record DimFill : Dim, IEqualityOperators<Dim, Dim, bool>, IEquatable<Dim>, IEquatable<DimFill>
- Inheritance
-
DimFill
- Implements
- Inherited Members
Remarks
This is a low-level API that is typically used internally by the layout system. Use the various static methods on the Dim class to create Dim objects instead.
When the SuperView uses DimAuto, a DimFill SubView does not contribute to the auto-sizing calculation by default. Because DimFill derives its size from the SuperView's ContentSize, and DimAuto computes the ContentSize from its SubViews, a circular dependency arises: the DimFill SubView will be sized to 0 unless MinimumContentDim is specified.
Set MinimumContentDim to ensure the SubView contributes a minimum size to the auto-sizing calculation. See the Dim.Auto Deep Dive for details.
Constructors
- DimFill(Dim, Dim?, View?)
Represents a dimension that fills the dimension, leaving the specified margin.
Properties
- Margin
The margin to not fill.
- MinimumContentDim
The minimum dimension the filled view will be constrained to. When the SuperView uses DimAuto, this minimum will contribute to the auto-sizing calculation, ensuring the SuperView is at least large enough to accommodate the minimum.
- To
The view to fill up to. When specified, the fill will stop at the position of this view (either its X or Y coordinate depending on the dimension being calculated).
Methods
- HasInner<TDim>(out TDim)
Searches nested Dim objects for the specified type. Override in subclasses that contain other Dim objects to enable Has<TDim>(out TDim) to find nested types.