Velaptor.Graphics.RectShape
Velaptor
Velaptor.Graphics
RectShape Struct
Represents a rectangular shape with various attributes.
public struct RectShape :
System.IEquatable<Velaptor.Graphics.RectShape>
Implements System.IEquatable<RectShape>
Constructors
RectShape() Constructor
Initializes a new instance of the RectShape struct.
public RectShape();
Properties
BorderThickness
Gets or sets the thickness of the rectangle's border.
public float BorderThickness { get; set; }
Property Value
Remarks
Ignored if the IsSolid property is set to true
.
The value of a corner will never be larger than the smallest half Width or half Height.
Bottom
Gets or sets the location of the bottom of the rectangle on the Y axis.
public float Bottom { get; set; }
Property Value
Remarks
Will automatically update the Position of the rectangle.
Color
Gets or sets the color of the rectangle.
public System.Drawing.Color Color { get; set; }
Property Value
Remarks
Ignored if the GradientType is set to any value other than None.
CornerRadius
Gets or sets the radius of each corner of the rectangle.
public Velaptor.Graphics.CornerRadius CornerRadius { get; set; }
Property Value
Remarks
The value of a corner will never be larger than the smallest half Width or half Height.
GradientStart
Gets or sets the starting color of the gradient.
public System.Drawing.Color GradientStart { get; set; }
Property Value
Remarks
This property is ignored if the GradientType is set to a value of None.
GradientStop
Gets or sets the ending color of the gradient.
public System.Drawing.Color GradientStop { get; set; }
Property Value
Remarks
This property is ignored if the GradientType is set to a value of None.
GradientType
Gets or sets the type of color gradient that will be applied to the rectangle.
public Velaptor.Graphics.ColorGradient GradientType { get; set; }
Property Value
Remarks
A value of None will use the Color
property and render the rectangle with a solid color.
A value of Horizontal will ignore the Color
property and use the GradientStartGradientStop properties.
This will render the rectangle with GradientStart color on the left side and gradually
render it to the right side as the GradientStop color.
A value of Vertical will ignore the Color
property and use the GradientStart and GradientStop properties.
This will render the rectangle with GradientStart color on the top and gradually
render it to the bottom as the GradientStop color.
HalfHeight
Gets the half height of the rectangle.
public float HalfHeight { get; }
Property Value
HalfWidth
Gets the half width of the rectangle.
public float HalfWidth { get; }
Property Value
Height
Gets or sets the height of the rectangle.
public float Height { get; set; }