Click or drag to resize

RectangleD2D Structure

A rectangle in 2D space.
Inheritance Hierarchy
SystemObject
  SystemValueType
    Altaxo.GeometryRectangleD2D

Namespace: Altaxo.Geometry
Assembly: AltaxoCore (in AltaxoCore.dll) Version: 4.8.3179.0 (4.8.3179.0)
Syntax
C#
[SerializableAttribute]
public struct RectangleD2D : IEquatable<RectangleD2D>

The RectangleD2D type exposes the following members.

Constructors
 NameDescription
Public methodRectangleD2D(PointD2D, PointD2D) Initializes a new instance of the RectangleD2D struct.
Public methodRectangleD2D(Double, Double, Double, Double) Initializes a new instance of the RectangleD2D struct.
Top
Properties
 NameDescription
Public propertyBottom Gets the y coordinate of the bottom.
Public propertyBottomHalf Gets a new rectangle that is the bottom half of this rectangle.
Public propertyCenterBottom Gets the center(x)-bottom(y) point of the rectangle.
Public propertyCenterCenter Gets the center(x)-center(y) point of the rectangle.
Public propertyCenterTop Gets the center(x)-top(y) point of the rectangle.
Public propertyStatic memberEmpty Gets the empty rectangle with the location (0, 0).
Public propertyHeight Gets or sets the height of the rectangle.
Public propertyIsEmpty Gets a value indicating whether the rectangle is empty. Per definition, it is empty if both width and height are zero.
Public propertyLeft Gets the x coordinate of the left.
Public propertyLeftBottom Gets the left(x)-bottom(y) point of the rectangle.
Public propertyLeftCenter Gets the left(x)-center(y) point of the rectangle.
Public propertyLeftHalf Gets a new rectangle that is the left half of this rectangle.
Public propertyLeftTop Gets the left(x)-top(y) point of the rectangle.
Public propertyLocation Gets or sets the location (of the left-top corner of the rectangle).
Public propertyOuterCircleBoundingBoxGets a rectangle that includes the smallest circle around this rectangle.
Public propertyRight Gets the x coordinate of the right.
Public propertyRightBottom Gets the right(x)-bottom(y) point of the rectangle.
Public propertyRightCenter Gets the right(x)-center(y) point of the rectangle.
Public propertyRightHalf Gets a new rectangle that is the right half of this rectangle.
Public propertyRightTop Gets the right(x)-top(y) point of the rectangle.
Public propertySize Gets or sets the size of the rectangle.
Public propertyTop Gets the y coordinate of the top.
Public propertyTopHalf Gets a new rectangle that is the top half of this rectangle.
Public propertyVertices Gets the vertices in binary order (x: 0th digit, y: 1st digit).
Public propertyWidth Gets or sets the width of the rectangle.
Public propertyX Gets or sets the x location (the x coordinate of the left side).
Public propertyY Gets or sets the y location (the y coordinate of the top side).
Top
Methods
 NameDescription
Public methodContains(PointD2D) 
Public methodContains(RectangleD2D) 
Public methodEquals(Object)Indicates whether this instance and a specified object are equal.
(Overrides ValueTypeEquals(Object))
Public methodEquals(RectangleD2D)Indicates whether the current object is equal to another object of the same type.
Public methodExpandExpands the rectangle by the specified margin.
Public methodExpandToInclude(PointD2D) Expands this rectangle, so that it contains the point p.
Public methodExpandToInclude(RectangleD2D) Expands this rectangle, so that it now includes its former shape, and the rectangle provided in the argument.
Public methodStatic memberExpandToInclude(NullableRectangleD2D, NullableRectangleD2D) Gets the rectangular bounding box that includes both rectangles.
Public methodStatic memberFromLTRB(PointD2D, PointD2D) Creates a rectangle from the left, top, right and bottom coordinate values.
Public methodStatic memberFromLTRB(Double, Double, Double, Double) Creates a rectangle from the left, top, right and bottom coordinate values.
Public methodGetHashCodeReturns the hash code for this instance.
(Overrides ValueTypeGetHashCode)
Public methodGetTypeGets the Type of the current instance.
(Inherited from Object)
Public methodInflateInflates the rectangle by the specified values x and y.
Public methodIntersectsWith Tests if this rectangle and the provided rectangle intersects.
Public methodStatic memberNewRectangleIncludingAllPoints Creates a rectangle that includes all the provided points.
Public methodOffsetChanges the location of the rectangle by the specified values for x and y.
Public methodToStringReturns the fully qualified type name of this instance.
(Overrides ValueTypeToString)
Top
Operators
Extension Methods
 NameDescription
Public Extension MethodGetIncludedTransformedRectangle Calculates the dimensions of the greatest (by area) rectangle included in an outer rectangle, where the inner rectangle is rotated/sheared/scaled.
(Defined by RectangleD2DExtensions)
Public Extension MethodToGdi
(Defined by GeometryToSystemDrawingConversions)
Public Extension MethodToGdiRectangle
(Defined by GeometryToSystemDrawingConversions)
Top
See Also