Table of Contents

Class RectangleF

Namespace
Geotab.Drawing
Assembly
Geotab.Checkmate.ObjectModel.dll

A Rectangle with a float X, Y, Width and Height.

public class RectangleF
Inheritance
RectangleF
Inherited Members

Constructors

RectangleF(float, float, float, float)

Initializes a new instance of the RectangleF class.

public RectangleF(float x, float y, float width, float height)

Parameters

x float

The x.

y float

The y.

width float

The width.

height float

The height.

Fields

Empty

An empty rectangle.

public static readonly RectangleF Empty

Field Value

RectangleF

Properties

Bottom

Gets the bottom (Y) of the rectangle.

public float Bottom { get; }

Property Value

float

The bottom.

Height

Gets the height of the rectangle.

public float Height { get; }

Property Value

float

The height.

Left

Gets the left (X) of the rectangle.

public float Left { get; }

Property Value

float

The left.

Location

Gets the location (top left) of the rectangle.

public PointF Location { get; }

Property Value

PointF

The location.

Right

Gets the right (X) of the rectangle.

public float Right { get; }

Property Value

float

The right.

Top

Gets the top (Y) of the rectangle.

public float Top { get; }

Property Value

float

The top.

Width

Gets the width of the rectangle.

public float Width { get; }

Property Value

float

The width.

X

Gets the X coordinate of the rectangle.

public float X { get; }

Property Value

float

The x.

Y

Gets the Y coordinate of the rectangle.

public float Y { get; }

Property Value

float

The y.

Methods

Equals(object?)

Determines whether the specified object, is equal to this instance.

public override bool Equals(object? obj)

Parameters

obj object

The object to compare with this instance.

Returns

bool

true if the specified object is equal to this instance; otherwise, false.

FromLtrb(float, float, float, float)

Gets a rectangle from left top right bottom.

public static RectangleF FromLtrb(float left, float top, float right, float bottom)

Parameters

left float

The left.

top float

The top.

right float

The right.

bottom float

The bottom.

Returns

RectangleF

The RectangleF.

GetHashCode()

Returns a hash code for this instance.

public override int GetHashCode()

Returns

int

A hash code for this instance, suitable for use in hashing algorithms and data structures like a hash table.

Offset(PointF)

Gets a new rectangle that is offset from the current by the point p.

public RectangleF Offset(PointF p)

Parameters

p PointF

The p.

Returns

RectangleF

The RectangleF with offset applied.

ToBoundingBox()

Converts to equivalent BoundingBox object.

public BoundingBox ToBoundingBox()

Returns

BoundingBox

BoundingBox.