[]
Represents the host and origin of a coordinate system for LayoutView objects.
public class LayoutHost
Initializes a new instance of the LayoutHost object.
public LayoutHost(object tag = null)
tag
objectThe object that contains data about the LayoutHost.
Gets a value indicating if the LayoutHost contains rectangles with unresolved changes.
public bool Dirty { get; }
Gets a value indicating if the LayoutHost does not allow any modifications or recalculations.
public bool Frozen { get; }
Gets or sets the object that contains data about the LayoutHost.
public object Tag { get; set; }
Gets or sets a value indicating whether a LayoutException should be thrown if the width or height of some LayoutRect becomes negative.
The default is true.
public bool ThrowIfNotFit { get; set; }
Gets or sets a value for which all absolute numbers smaller than are considered equal to zero.
Possible values are between 0.00001f and 1f. The default is 0.01f.
public float ZeroTolerance { get; set; }
Creates a new LayoutView and associates it with the LayoutHost.
public LayoutView CreateView(float width, float height, Matrix transform = null, object tag = null)
width
floatThe width of the view rectangle.
height
floatThe height of the view rectangle.
transform
MatrixThe transformation matrix for the LayoutView.
tag
objectThe object that contains data about the LayoutView.
The created LayoutView object.
Releases all memory resources required for recalculating the layout.
public void Freeze()
Recalculates the layout of all "dirty" LayoutRect objects in the LayoutHost.
public bool PerformLayout()
true if successful, false if the width or height of any LayoutRect has become negative and the ThrowIfNotFit is false.