Describes the interior of a graphics shape composed of rectangles and paths. This class cannot be inherited.
Public Constructors | |
region () | |
Initializes a new xtd::drawing::region. | |
region (const xtd::drawing::drawing_2d::graphics_path &path) | |
Initializes a new xtd::drawing::region with the specified xtd::drawing::graphics_path. | |
region (const xtd::drawing::rectangle &rect) | |
Initializes a new xtd::drawing::region from the specified xtd::drawing::rectangle structure. | |
region (const xtd::drawing::rectangle_f &rect) | |
Initializes a new xtd::drawing::region from the specified xtd::drawing::rectangle_f structure. | |
Public Properties | |
intptr | handle () const noexcept |
Gets the handle of the region. | |
Public Methods | |
void | complement (const xtd::drawing::drawing_2d::graphics_path &path) noexcept |
Updates this xtd::drawing::region to contain the portion of the specified xtd::drawing::graphics_path that does not intersect with this xtd::drawing::region. | |
void | complement (const xtd::drawing::rectangle &rect) noexcept |
Updates this xtd::drawing::region to contain the portion of the specified xtd::drawing::rectangle structure that does not intersect with this xtd::drawing::region. | |
void | complement (const xtd::drawing::rectangle_f &rect) noexcept |
Updates this xtd::drawing::region to contain the portion of the specified xtd::drawing::rectangle_f structure that does not intersect with this xtd::drawing::region. | |
void | complement (const xtd::drawing::region ®ion) noexcept |
Updates this xtd::drawing::region to contain the portion of the specified xtd::drawing::region that does not intersect with this xtd::drawing::region. | |
bool | equals (const region &value) const noexcept override |
void | exclude (const xtd::drawing::drawing_2d::graphics_path &path) noexcept |
Updates this xtd::drawing::region to contain only the portion of its interior that does not intersect with the specified xtd::drawing::graphics_path. | |
void | exclude (const xtd::drawing::rectangle &rect) noexcept |
Updates this xtd::drawing::region to contain only the portion of its interior that does not intersect with the specified xtd::drawing::rectangle structure. | |
void | exclude (const xtd::drawing::rectangle_f &rect) noexcept |
The xtd::drawing::rectangle_f structure to exclude from this xtd::drawing::region. | |
void | exclude (const xtd::drawing::region ®ion) noexcept |
Updates this xtd::drawing::region to contain only the portion of its interior that does not intersect with the specified xtd::drawing::region. | |
xtd::drawing::rectangle_f | get_bounds () const noexcept |
Gets a xtd::drawing::rectangle_f structure that represents a rectangle that bounds this xtd::drawing::region on the drawing surface of a xtd::drawing::graphics object. | |
xtd::drawing::rectangle_f | get_bounds (const xtd::drawing::graphics &g) const noexcept |
Gets a xtd::drawing::rectangle_f structure that represents a rectangle that bounds this xtd::drawing::region on the drawing surface of a xtd::drawing::graphics object. | |
intptr | get_hrgn (const xtd::drawing::graphics &g) const noexcept |
Returns a Windows handle to this xtd::drawing::region in the specified graphics context. | |
void | intersect (const xtd::drawing::drawing_2d::graphics_path &path) noexcept |
Updates this xtd::drawing::region to the intersection of itself with the specified xtd::drawing::graphics_path. | |
void | intersect (const xtd::drawing::rectangle &rect) noexcept |
Updates this xtd::drawing::region to the intersection of itself with the specified xtd::drawing::rectangle structure. | |
void | intersect (const xtd::drawing::rectangle_f &rect) noexcept |
Updates this xtd::drawing::region to the intersection of itself with the specified xtd::drawing::rectangle_f structure. | |
void | intersect (const xtd::drawing::region ®ion) noexcept |
Updates this xtd::drawing::region to the intersection of itself with the specified xtd::drawing::region. | |
bool | is_empty () const noexcept |
Tests whether this xtd::drawing::region has an empty interior. | |
bool | is_empty (const xtd::drawing::graphics &g) const noexcept |
Tests whether this xtd::drawing::region has an empty interior on the specified drawing surface. | |
bool | is_infinite () const noexcept |
Tests whether this xtd::drawing::region has an infinite interior. | |
bool | is_infinite (const xtd::drawing::graphics &g) const noexcept |
Tests whether this xtd::drawing::region has an infinite interior on the specified drawing surface. | |
bool | is_visible (const xtd::drawing::rectangle_f &rect, const xtd::drawing::graphics &g) const noexcept |
Tests whether any portion of the specified xtd::drawing::rectangle_f structure is contained within this xtd::drawing::region when drawn using the specified xtd::drawing::graphics. | |
bool | is_visible (float x, float y, float width, float height, const xtd::drawing::graphics &g) const noexcept |
Tests whether any portion of the specified rectangle is contained within this xtd::drawing::region when drawn using the specified xtd::drawing::graphics. | |
bool | is_visible (const xtd::drawing::rectangle &rect, const xtd::drawing::graphics &g) const noexcept |
Tests whether any portion of the specified xtd::drawing::rectangle structure is contained within this xtd::drawing::region when drawn using the specified xtd::drawing::graphics. | |
bool | is_visible (int32 x, int32 y, int32 width, int32 height, const xtd::drawing::graphics &g) const noexcept |
Tests whether any portion of the specified rectangle is contained within this xtd::drawing::region when drawn using the specified xtd::drawing::graphics. | |
bool | is_visible (const xtd::drawing::rectangle_f &rect) const noexcept |
Tests whether any portion of the specified xtd::drawing::rectangle_f structure is contained within this xtd::drawing::region. | |
bool | is_visible (float x, float y, float width, float height) const noexcept |
Tests whether any portion of the specified rectangle is contained within this xtd::drawing::region. | |
bool | is_visible (const xtd::drawing::rectangle &rect) const noexcept |
Tests whether any portion of the specified xtd::drawing::rectangle structure is contained within this xtd::drawing::region. | |
bool | is_visible (int32 x, int32 y, int32 width, int32 height) const noexcept |
Tests whether any portion of the specified rectangle is contained within this xtd::drawing::region. | |
bool | is_visible (xtd::drawing::point_f pt, const xtd::drawing::graphics &g) const noexcept |
Tests whether the specified PointF structure is contained within this xtd::drawing::region when drawn using the specified xtd::drawing::graphics. | |
bool | is_visible (float x, float y, const xtd::drawing::graphics &g) const noexcept |
Tests whether the specified point is contained within this xtd::drawing::region when drawn using the specified xtd::drawing::graphics. | |
bool | is_visible (xtd::drawing::point pt, const xtd::drawing::graphics &g) const noexcept |
Tests whether the specified Point structure is contained within this xtd::drawing::region when drawn using the specified xtd::drawing::graphics. | |
bool | is_visible (int32 x, int32 y, const xtd::drawing::graphics &g) const noexcept |
Tests whether the specified point is contained within this xtd::drawing::region when drawn using the specified xtd::drawing::graphics. | |
bool | is_visible (xtd::drawing::point_f pt) const noexcept |
Tests whether the specified PointF structure is contained within this xtd::drawing::region. | |
bool | is_visible (float x, float y) const noexcept |
Tests whether the specified point is contained within this xtd::drawing::region when drawn using the specified xtd::drawing::graphics. | |
bool | is_visible (xtd::drawing::point pt) const noexcept |
Tests whether the specified Point structure is contained within this xtd::drawing::region. | |
bool | is_visible (int32 x, int32 y) const noexcept |
Tests whether the specified point is contained within this xtd::drawing::region when drawn using the specified xtd::drawing::graphics. | |
void | make_empty () |
Initializes this xtd::drawing::region to an empty interior. | |
void | make_infinite () noexcept |
Initializes this xtd::drawing::region object to an infinite interior. | |
void | make_union (const xtd::drawing::drawing_2d::graphics_path &path) noexcept |
Updates this xtd::drawing::region to the union of itself and the specified xtd::drawing::graphics_path. | |
void | make_union (const xtd::drawing::rectangle &rect) noexcept |
Updates this xtd::drawing::region to the union of itself and the specified xtd::drawing::rectangle structure. | |
void | make_union (const xtd::drawing::rectangle_f &rect) noexcept |
Updates this xtd::drawing::region to the union of itself and the specified xtd::drawing::rectangle_f structure. | |
void | make_union (const xtd::drawing::region ®ion) noexcept |
Updates this xtd::drawing::region to the union of itself and the specified xtd::drawing::region. | |
void | make_xor (const xtd::drawing::drawing_2d::graphics_path &path) noexcept |
Updates this xtd::drawing::region to the union minus the intersection of itself with the specified xtd::drawing::graphics_path. | |
void | make_xor (const xtd::drawing::rectangle &rect) noexcept |
Updates this xtd::drawing::region to the union minus the intersection of itself with the specified xtd::drawing::rectangle structure. | |
void | make_xor (const xtd::drawing::rectangle_f &rect) noexcept |
Updates this xtd::drawing::region to the union minus the intersection of itself with the specified xtd::drawing::rectangle_f structure. | |
void | make_xor (const xtd::drawing::region ®ion) noexcept |
Updates this xtd::drawing::region to the union minus the intersection of itself with the specified xtd::drawing::region. | |
void | release_hrgn (intptr region_handle) |
Releases the handle of the xtd::drawing::region. | |
void | translate (int32 dx, int32 dy) noexcept |
Offsets the coordinates of this xtd::drawing::region by the specified amount. | |
void | translate (float dx, float dy) noexcept |
Offsets the coordinates of this xtd::drawing::region by the specified amount. | |
virtual bool | equals (const object &obj) const noexcept |
Determines whether the specified object is equal to the current object. | |
template<typename object_a_t , typename object_b_t > | |
static bool | equals (const object_a_t &object_a, const object_b_t &object_b) noexcept |
Determines whether the specified object instances are considered equal. | |
Public Static Methods | |
static xtd::drawing::region | from_hrgn (intptr hrgn) |
Initializes a new xtd::drawing::region from a handle to the specified existing GDI region. | |
Additional Inherited Members | |
Public Member Functions inherited from xtd::object | |
object ()=default | |
Create a new instance of the ultimate base class object. | |
virtual size_t | get_hash_code () const noexcept |
Serves as a hash function for a particular type. | |
virtual type_object | get_type () const noexcept |
Gets the type of the current instance. | |
template<typename object_t > | |
xtd::uptr< object_t > | memberwise_clone () const |
Creates a shallow copy of the current object. | |
virtual xtd::string | to_string () const noexcept |
Returns a xtd::string that represents the current object. | |
Public Member Functions inherited from xtd::iequatable< region > | |
virtual bool | equals (const region &) const noexcept=0 |
Indicates whether the current object is equal to another object of the same type. | |
Static Public Member Functions inherited from xtd::object | |
template<typename object_a_t , typename object_b_t > | |
static bool | equals (const object_a_t &object_a, const object_b_t &object_b) noexcept |
Determines whether the specified object instances are considered equal. | |
template<typename object_a_t , typename object_b_t > | |
static bool | reference_equals (const object_a_t &object_a, const object_b_t &object_b) noexcept |
Determines whether the specified object instances are the same instance. | |
xtd::drawing::region::region | ( | ) |
Initializes a new xtd::drawing::region.
|
explicit |
Initializes a new xtd::drawing::region with the specified xtd::drawing::graphics_path.
path | A xtd::drawing::graphics_path that defines the new xtd::drawing::region. |
|
explicit |
Initializes a new xtd::drawing::region from the specified xtd::drawing::rectangle structure.
rect | A xtd::drawing::rectangle structure that defines the interior of the new xtd::drawing::region. |
|
explicit |
Initializes a new xtd::drawing::region from the specified xtd::drawing::rectangle_f structure.
rect | A xtd::drawing::rectangle_f structure that defines the interior of the new xtd::drawing::region. |
|
noexcept |
Gets the handle of the region.
|
noexcept |
Updates this xtd::drawing::region to contain the portion of the specified xtd::drawing::graphics_path that does not intersect with this xtd::drawing::region.
path | The xtd::drawing::graphics_path to complement this xtd::drawing::region. |
|
noexcept |
Updates this xtd::drawing::region to contain the portion of the specified xtd::drawing::rectangle structure that does not intersect with this xtd::drawing::region.
rect | The xtd::drawing::rectangle structure to complement this xtd::drawing::region. |
|
noexcept |
Updates this xtd::drawing::region to contain the portion of the specified xtd::drawing::rectangle_f structure that does not intersect with this xtd::drawing::region.
rect | The xtd::drawing::rectangle_f structure to complement this xtd::drawing::region. |
|
noexcept |
Updates this xtd::drawing::region to contain the portion of the specified xtd::drawing::region that does not intersect with this xtd::drawing::region.
region | The xtd::drawing::region object to complement this xtd::drawing::region object. |
|
noexcept |
Updates this xtd::drawing::region to contain only the portion of its interior that does not intersect with the specified xtd::drawing::graphics_path.
path | The xtd::drawing::graphics_path to exclude from this xtd::drawing::region. |
|
noexcept |
Updates this xtd::drawing::region to contain only the portion of its interior that does not intersect with the specified xtd::drawing::rectangle structure.
rect | The xtd::drawing::rectangle structure to exclude from this xtd::drawing::region. |
|
noexcept |
The xtd::drawing::rectangle_f structure to exclude from this xtd::drawing::region.
|
noexcept |
Updates this xtd::drawing::region to contain only the portion of its interior that does not intersect with the specified xtd::drawing::region.
region | The xtd::drawing::region to exclude from this xtd::drawing::region. |
|
noexcept |
Gets a xtd::drawing::rectangle_f structure that represents a rectangle that bounds this xtd::drawing::region on the drawing surface of a xtd::drawing::graphics object.
g | The xtd::drawing::graphics on which this xtd::drawing::region is drawn. |
|
noexcept |
Gets a xtd::drawing::rectangle_f structure that represents a rectangle that bounds this xtd::drawing::region on the drawing surface of a xtd::drawing::graphics object.
g | The xtd::drawing::graphics on which this xtd::drawing::region is drawn. |
|
noexcept |
Returns a Windows handle to this xtd::drawing::region in the specified graphics context.
g | The xtd::drawing::graphics on which this xtd::drawing::region is drawn. |
|
noexcept |
Updates this xtd::drawing::region to the intersection of itself with the specified xtd::drawing::graphics_path.
path | The xtd::drawing::graphics_path to intersect with this xtd::drawing::region. |
|
noexcept |
Updates this xtd::drawing::region to the intersection of itself with the specified xtd::drawing::rectangle structure.
The | xtd::drawing::rectangle structure to intersect with this xtd::drawing::region. |
|
noexcept |
Updates this xtd::drawing::region to the intersection of itself with the specified xtd::drawing::rectangle_f structure.
rect | The xtd::drawing::rectangle_f structure to intersect with this xtd::drawing::region. |
|
noexcept |
Updates this xtd::drawing::region to the intersection of itself with the specified xtd::drawing::region.
region | The xtd::drawing::region to intersect with this xtd::drawing::region. |
|
noexcept |
Tests whether this xtd::drawing::region has an empty interior.
|
noexcept |
Tests whether this xtd::drawing::region has an empty interior on the specified drawing surface.
g | A xtd::drawing::graphics that represents a drawing surface. |
|
noexcept |
Tests whether this xtd::drawing::region has an infinite interior.
|
noexcept |
Tests whether this xtd::drawing::region has an infinite interior on the specified drawing surface.
g | A xtd::drawing::graphics that represents a drawing surface. |
|
noexcept |
Tests whether any portion of the specified xtd::drawing::rectangle_f structure is contained within this xtd::drawing::region when drawn using the specified xtd::drawing::graphics.
rect | The xtd::drawing::rectangle_f structure to test. |
g | A xtd::drawing::graphics that represents a graphics context. |
|
noexcept |
Tests whether any portion of the specified rectangle is contained within this xtd::drawing::region when drawn using the specified xtd::drawing::graphics.
x | The x-coordinate of the upper-left corner of the rectangle to test. |
y | The y-coordinate of the upper-left corner of the rectangle to test. |
width | The width of the rectangle to test. |
height | The height of the rectangle to test. |
g | A xtd::drawing::graphics that represents a graphics context. |
|
noexcept |
Tests whether any portion of the specified xtd::drawing::rectangle structure is contained within this xtd::drawing::region when drawn using the specified xtd::drawing::graphics.
rect | The xtd::drawing::rectangle structure to test. |
g | A xtd::drawing::graphics that represents a graphics context. |
|
noexcept |
Tests whether any portion of the specified rectangle is contained within this xtd::drawing::region when drawn using the specified xtd::drawing::graphics.
x | The x-coordinate of the upper-left corner of the rectangle to test. |
y | The y-coordinate of the upper-left corner of the rectangle to test. |
width | The width of the rectangle to test. |
height | The height of the rectangle to test. |
g | A xtd::drawing::graphics that represents a graphics context. |
|
noexcept |
Tests whether any portion of the specified xtd::drawing::rectangle_f structure is contained within this xtd::drawing::region.
rect | The xtd::drawing::rectangle_f structure to test. |
|
noexcept |
Tests whether any portion of the specified rectangle is contained within this xtd::drawing::region.
x | The x-coordinate of the upper-left corner of the rectangle to test. |
y | The y-coordinate of the upper-left corner of the rectangle to test. |
width | The width of the rectangle to test. |
height | The height of the rectangle to test. |
|
noexcept |
Tests whether any portion of the specified xtd::drawing::rectangle structure is contained within this xtd::drawing::region.
rect | The xtd::drawing::rectangle structure to test. |
|
noexcept |
Tests whether any portion of the specified rectangle is contained within this xtd::drawing::region.
x | The x-coordinate of the upper-left corner of the rectangle to test. |
y | The y-coordinate of the upper-left corner of the rectangle to test. |
width | The width of the rectangle to test. |
height | The height of the rectangle to test. |
|
noexcept |
Tests whether the specified PointF structure is contained within this xtd::drawing::region when drawn using the specified xtd::drawing::graphics.
pt | The PointF structure to test. |
g | A xtd::drawing::graphics that represents a graphics context. |
|
noexcept |
Tests whether the specified point is contained within this xtd::drawing::region when drawn using the specified xtd::drawing::graphics.
x | The x-coordinate of the point to test. |
y | The y-coordinate of the point to test. |
g | A xtd::drawing::graphics that represents a graphics context. |
|
noexcept |
Tests whether the specified Point structure is contained within this xtd::drawing::region when drawn using the specified xtd::drawing::graphics.
pt | The Point structure to test. |
g | A xtd::drawing::graphics that represents a graphics context. |
|
noexcept |
Tests whether the specified point is contained within this xtd::drawing::region when drawn using the specified xtd::drawing::graphics.
x | The x-coordinate of the point to test. |
y | The y-coordinate of the point to test. |
g | A xtd::drawing::graphics that represents a graphics context. |
|
noexcept |
Tests whether the specified PointF structure is contained within this xtd::drawing::region.
pt | The PointF structure to test. |
|
noexcept |
Tests whether the specified point is contained within this xtd::drawing::region when drawn using the specified xtd::drawing::graphics.
x | The x-coordinate of the point to test. |
y | The y-coordinate of the point to test. |
|
noexcept |
Tests whether the specified Point structure is contained within this xtd::drawing::region.
pt | The Point structure to test. |
Tests whether the specified point is contained within this xtd::drawing::region when drawn using the specified xtd::drawing::graphics.
x | The x-coordinate of the point to test. |
y | The y-coordinate of the point to test. |
void xtd::drawing::region::make_empty | ( | ) |
Initializes this xtd::drawing::region to an empty interior.
|
noexcept |
Initializes this xtd::drawing::region object to an infinite interior.
|
noexcept |
Updates this xtd::drawing::region to the union of itself and the specified xtd::drawing::graphics_path.
path | The xtd::drawing::graphics_path to unite with this xtd::drawing::region. |
|
noexcept |
Updates this xtd::drawing::region to the union of itself and the specified xtd::drawing::rectangle structure.
rect | The xtd::drawing::rectangle structure to unite with this xtd::drawing::region. |
|
noexcept |
Updates this xtd::drawing::region to the union of itself and the specified xtd::drawing::rectangle_f structure.
rect | The xtd::drawing::rectangle_f structure to unite with this xtd::drawing::region. |
|
noexcept |
Updates this xtd::drawing::region to the union of itself and the specified xtd::drawing::region.
region | The xtd::drawing::region to unite with this xtd::drawing::region. |
|
noexcept |
Updates this xtd::drawing::region to the union minus the intersection of itself with the specified xtd::drawing::graphics_path.
path | The xtd::drawing::graphics_path to Xor with this xtd::drawing::region. |
|
noexcept |
Updates this xtd::drawing::region to the union minus the intersection of itself with the specified xtd::drawing::rectangle structure.
path | The xtd::drawing::rectangle structure to Xor with this xtd::drawing::region. |
|
noexcept |
Updates this xtd::drawing::region to the union minus the intersection of itself with the specified xtd::drawing::rectangle_f structure.
path | The xtd::drawing::rectangle_f structure to Xor with this xtd::drawing::region. |
|
noexcept |
Updates this xtd::drawing::region to the union minus the intersection of itself with the specified xtd::drawing::region.
path | The xtd::drawing::region to Xor with this xtd::drawing::region. |
void xtd::drawing::region::release_hrgn | ( | intptr | region_handle | ) |
Releases the handle of the xtd::drawing::region.
region_handle | The handle to the xtd::drawing::region. |
Offsets the coordinates of this xtd::drawing::region by the specified amount.
dx | The amount to offset this xtd::drawing::region horizontally. |
dy | The amount to offset this xtd::drawing::region vertically. |
|
noexcept |
Offsets the coordinates of this xtd::drawing::region by the specified amount.
dx | The amount to offset this xtd::drawing::region horizontally. |
dy | The amount to offset this xtd::drawing::region vertically. |
|
static |
Initializes a new xtd::drawing::region from a handle to the specified existing GDI region.
hrgn | A handle to an existing xtd::drawing::region. |
|
virtualnoexcept |
Determines whether the specified object is equal to the current object.
obj | The object to compare with the current object. |
Reimplemented from xtd::object.
|
inlinestaticnoexcept |
Determines whether the specified object instances are considered equal.
object_a | The first object to compare. |
object_b | The second object to compare. |