Skip to main content

RelativeRect Structure

Defines a rectangle that may be defined relative to a containing element.

Definition

Namespace: Avalonia
Assembly: Avalonia.Base (in Avalonia.Base.dll)

public readonly struct RelativeRect : IEquatable<RelativeRect>
View Source
InheritanceObjectValueType → RelativeRect
ImplementsIEquatable(RelativeRect)

Constructors

RelativeRect(Rect, RelativeUnit)Initializes a new instance of the RelativeRect structure.
RelativeRect(Size, RelativeUnit)Initializes a new instance of the RelativeRect structure.
RelativeRect(Point, Point, RelativeUnit)Initializes a new instance of the RelativeRect structure.
RelativeRect(Point, Size, RelativeUnit)Initializes a new instance of the RelativeRect structure.
RelativeRect(Double, Double, Double, Double, RelativeUnit)Initializes a new instance of the RelativeRect structure.

Properties

RectGets the rectangle.
UnitGets the unit of the rectangle.

Methods

Equals(Object)Checks if the RelativeRect equals another object.
(Overrides ValueType.Equals(Object))
Equals(RelativeRect)Checks if the RelativeRect equals another rectangle.
GetHashCode()Gets a hashcode for a RelativeRect.
(Overrides ValueType.GetHashCode())
GetType()Gets the Type of the current instance.
(Inherited from Object)
Parse(String)Parses a RelativeRect string.
ToPixels(Rect)Converts a RelativeRect into pixels.
ToPixels(Size)Converts a RelativeRect into pixels.
ToString()Returns the fully qualified type name of this instance.
(Inherited from ValueType)

Operators

Equality(RelativeRect, RelativeRect)Checks for equality between two RelativeRects.
Inequality(RelativeRect, RelativeRect)Checks for inequality between two RelativeRects.

Fields

FillA rectangle that represents 100% of an area.

See Also

Reference

Avalonia Namespace