C# Class System.Drawing.RectangleF

Show file Open project: dotnet/corefx Class Usage Examples

Public Properties

Property Type Description
Empty RectangleF
Empty System.Drawing.RectangleF

Public Methods

Method Description
Contains ( System pt ) : bool
Equals ( object obj ) : bool

Tests whether obj is a with the same location and size of this .

FromLTRB ( float left, float top, float right, float bottom ) : RectangleF

Creates a new with the specified location and size.

FromLTRB ( float left, float top, float right, float bottom ) : System.Drawing.RectangleF
GetHashCode ( ) : int

Gets the hash code for this .

Inflate ( RectangleF rect, float x, float y ) : RectangleF

Creates a that is inflated by the specified amount.

Inflate ( System rect, float x, float y ) : System.Drawing.RectangleF
Inflate ( SizeF size ) : void

Inflates this by the specified amount.

Inflate ( System size ) : void
Inflate ( float x, float y ) : void

Inflates this by the specified amount.

Intersect ( System a, System b ) : System.Drawing.RectangleF
Intersect ( RectangleF rect ) : void

Creates a Rectangle that represents the intersection between this Rectangle and rect.

Intersect ( System rect ) : void
IntersectsWith ( System rect ) : bool
Offset ( PointF pos ) : void

Adjusts the location of this rectangle by the specified amount.

Offset ( System pos ) : void
Offset ( float x, float y ) : void

Adjusts the location of this rectangle by the specified amount.

RectangleF ( System location, System size )
RectangleF ( float x, float y, float width, float height )
RectangleF ( PointF location, SizeF size ) : System.Diagnostics.Contracts

Initializes a new instance of the class with the specified location and size.

RectangleF ( float x, float y, float width, float height ) : System.Diagnostics.Contracts

Initializes a new instance of the class with the specified location and size.

ToString ( ) : string

Converts the and of this to a human-readable string.

Union ( System a, System b ) : System.Drawing.RectangleF
operator ( ) : bool

Tests whether two objects have equal location and size.

Private Methods

Method Description
Contains ( PointF pt ) : bool
Contains ( RectangleF rect ) : bool
Contains ( float x, float y ) : bool
Intersect ( RectangleF a, RectangleF b ) : RectangleF
IntersectsWith ( RectangleF rect ) : bool
Union ( RectangleF a, RectangleF b ) : RectangleF

Method Details

Contains() public method

public Contains ( System pt ) : bool
pt System
return bool

Equals() public method

Tests whether obj is a with the same location and size of this .

public Equals ( object obj ) : bool
obj object
return bool

FromLTRB() public static method

Creates a new with the specified location and size.

public static FromLTRB ( float left, float top, float right, float bottom ) : RectangleF
left float
top float
right float
bottom float
return RectangleF

FromLTRB() public static method

public static FromLTRB ( float left, float top, float right, float bottom ) : System.Drawing.RectangleF
left float
top float
right float
bottom float
return System.Drawing.RectangleF

GetHashCode() public method

Gets the hash code for this .
public GetHashCode ( ) : int
return int

Inflate() public static method

Creates a that is inflated by the specified amount.

public static Inflate ( RectangleF rect, float x, float y ) : RectangleF
rect RectangleF
x float
y float
return RectangleF

Inflate() public static method

public static Inflate ( System rect, float x, float y ) : System.Drawing.RectangleF
rect System
x float
y float
return System.Drawing.RectangleF

Inflate() public method

Inflates this by the specified amount.
public Inflate ( SizeF size ) : void
size SizeF
return void

Inflate() public method

public Inflate ( System size ) : void
size System
return void

Inflate() public method

Inflates this by the specified amount.

public Inflate ( float x, float y ) : void
x float
y float
return void

Intersect() public static method

public static Intersect ( System a, System b ) : System.Drawing.RectangleF
a System
b System
return System.Drawing.RectangleF

Intersect() public method

Creates a Rectangle that represents the intersection between this Rectangle and rect.
public Intersect ( RectangleF rect ) : void
rect RectangleF
return void

Intersect() public method

public Intersect ( System rect ) : void
rect System
return void

IntersectsWith() public method

public IntersectsWith ( System rect ) : bool
rect System
return bool

Offset() public method

Adjusts the location of this rectangle by the specified amount.
public Offset ( PointF pos ) : void
pos PointF
return void

Offset() public method

public Offset ( System pos ) : void
pos System
return void

Offset() public method

Adjusts the location of this rectangle by the specified amount.
public Offset ( float x, float y ) : void
x float
y float
return void

RectangleF() public method

public RectangleF ( System location, System size )
location System
size System

RectangleF() public method

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

RectangleF() public method

Initializes a new instance of the class with the specified location and size.

public RectangleF ( PointF location, SizeF size ) : System.Diagnostics.Contracts
location PointF
size SizeF
return System.Diagnostics.Contracts

RectangleF() public method

Initializes a new instance of the class with the specified location and size.

public RectangleF ( float x, float y, float width, float height ) : System.Diagnostics.Contracts
x float
y float
width float
height float
return System.Diagnostics.Contracts

ToString() public method

Converts the and of this to a human-readable string.
public ToString ( ) : string
return string

Union() public static method

public static Union ( System a, System b ) : System.Drawing.RectangleF
a System
b System
return System.Drawing.RectangleF

operator() public static method

Tests whether two objects have equal location and size.

public static operator ( ) : bool
return bool

Property Details

Empty public static property

Initializes a new instance of the class.
public static RectangleF,System.Drawing Empty
return RectangleF

Empty public static property

public static System.Drawing.RectangleF Empty
return System.Drawing.RectangleF