Inherits System::Object.
Public Member Functions | |
ASPOSECPP_SHARED_API | Region () |
Constructs a new instance of Region class. More... | |
ASPOSECPP_SHARED_API | Region (const RectangleF &rect) |
ASPOSECPP_SHARED_API | Region (const Rectangle &rect) |
ASPOSECPP_SHARED_API | Region (const SharedPtr< Drawing2D::GraphicsPath > &path) |
ASPOSECPP_SHARED_API | Region (const SkPath &path) |
ASPOSECPP_SHARED_API | Region (const SharedPtr< Drawing2D::RegionData > ®ion_data) |
virtual ASPOSECPP_SHARED_API | ~Region () |
Destructor. More... | |
ASPOSECPP_SHARED_API ArrayPtr< RectangleF > | GetRegionScans (const SharedPtr< Drawing2D::Matrix > &matrix) const |
ASPOSECPP_SHARED_API RectangleF | GetBounds (const SharedPtr< Graphics > &graphics) const |
ASPOSECPP_SHARED_API void | Union (const RectangleF &rect) |
ASPOSECPP_SHARED_API void | Union (const Rectangle &rect) |
ASPOSECPP_SHARED_API void | Union (const SharedPtr< Drawing2D::GraphicsPath > &path) |
ASPOSECPP_SHARED_API void | Union (const SharedPtr< Region > ®ion) |
ASPOSECPP_SHARED_API SharedPtr< Region > | Clone () const |
Returns a copy of the current object. More... | |
ASPOSECPP_SHARED_API void | Intersect (const RectangleF &rect) |
ASPOSECPP_SHARED_API void | Intersect (const Rectangle &rect) |
ASPOSECPP_SHARED_API void | Intersect (const SharedPtr< Drawing2D::GraphicsPath > &path) |
ASPOSECPP_SHARED_API void | Intersect (const SharedPtr< Region > ®ion) |
ASPOSECPP_SHARED_API void | Exclude (const RectangleF &rect) |
ASPOSECPP_SHARED_API void | Exclude (const Rectangle &rect) |
ASPOSECPP_SHARED_API void | Exclude (const SharedPtr< Drawing2D::GraphicsPath > &path) |
ASPOSECPP_SHARED_API void | Exclude (const SharedPtr< Region > ®ion) |
ASPOSECPP_SHARED_API void | Translate (int dx, int dy) |
ASPOSECPP_SHARED_API void | Translate (float dx, float dy) |
ASPOSECPP_SHARED_API void | Transform (const SharedPtr< Drawing2D::Matrix > &matrix) |
ASPOSECPP_SHARED_API void | Transform (const SkMatrix &matrix) |
ASPOSECPP_SHARED_API void | Complement (const RectangleF &rect) |
ASPOSECPP_SHARED_API void | Complement (const Rectangle &rect) |
ASPOSECPP_SHARED_API void | Complement (const SharedPtr< Drawing2D::GraphicsPath > &path) |
ASPOSECPP_SHARED_API void | Complement (const SharedPtr< Region > ®ion) |
ASPOSECPP_SHARED_API void | Xor (const RectangleF &rect) |
ASPOSECPP_SHARED_API void | Xor (const Rectangle &rect) |
ASPOSECPP_SHARED_API void | Xor (const SharedPtr< Drawing2D::GraphicsPath > &path) |
ASPOSECPP_SHARED_API void | Xor (const SharedPtr< Region > ®ion) |
ASPOSECPP_SHARED_API bool | Equals (const SharedPtr< Region > &r, const SharedPtr< Graphics > &g) |
ASPOSECPP_SHARED_API bool | IsEmpty (const SharedPtr< Graphics > &g) const |
ASPOSECPP_SHARED_API bool | IsInfinite (const SharedPtr< Graphics > &g) const |
ASPOSECPP_SHARED_API bool | IsVisible (const Point &point) const |
ASPOSECPP_SHARED_API bool | IsVisible (const PointF &point) const |
ASPOSECPP_SHARED_API bool | IsVisible (const Rectangle &rect) |
ASPOSECPP_SHARED_API bool | IsVisible (const RectangleF &rect) |
ASPOSECPP_SHARED_API bool | IsVisible (const Point &point, const SharedPtr< Graphics > &graphics) const |
ASPOSECPP_SHARED_API bool | IsVisible (const PointF &point, const SharedPtr< Graphics > &graphics) const |
ASPOSECPP_SHARED_API bool | IsVisible (const Rectangle &rect, const SharedPtr< Graphics > &graphics) |
ASPOSECPP_SHARED_API bool | IsVisible (const RectangleF &rect, const SharedPtr< Graphics > &graphics) |
ASPOSECPP_SHARED_API bool | IsVisible (float x, float y) const |
ASPOSECPP_SHARED_API bool | IsVisible (float x, float y, const SharedPtr< Graphics > &graphics) const |
void | Dispose () |
Releases all operating system resources acquired by the current object. More... | |
ASPOSECPP_SHARED_API void | MakeInfinite () |
Initializes this region object to an infinite interior. More... | |
ASPOSECPP_SHARED_API void | MakeEmpty () |
Initializes the current object to empty interior. More... | |
ASPOSECPP_SHARED_API SharedPtr< Drawing2D::RegionData > | GetRegionData () const |
Public Member Functions inherited from System::Object | |
ASPOSECPP_SHARED_API | Object () |
Creates object. Initializes all internal data structures. More... | |
virtual ASPOSECPP_SHARED_API | ~Object () |
Destroys object. Frees all internal data structures. More... | |
ASPOSECPP_SHARED_API | Object (Object const &x) |
Copy constructor. Doesn't copy anything, really, just initializes new object and enables copy constructing subclasses. More... | |
Object & | operator= (Object const &x) |
Assignment operator. Doesn't copy anything, really, just initializes new object and enables copy constructing subclasses. More... | |
Object * | SharedRefAdded () |
Increments shared reference count. Shouldn't be called directly; instead, use smart pointers or ThisProtector. More... | |
int | SharedRefRemovedSafe () |
Decrements and returns shared reference count. Shouldn't be called directly; instead, use smart pointers or ThisProtector. More... | |
int | RemovedSharedRefs (int count) |
Decreases shared reference count by specified value. More... | |
Detail::SmartPtrCounter * | WeakRefAdded () |
Increments weak reference count. Shouldn't be called directly; instead, use smart pointers or ThisProtector. More... | |
void | WeakRefRemoved () |
Decrements weak reference count. Shouldn't be called directly; instead, use smart pointers or ThisProtector. More... | |
Detail::SmartPtrCounter * | GetCounter () |
Gets reference counter data structure associated with the object. More... | |
int | SharedCount () const |
Gets current value of shared reference counter. More... | |
ASPOSECPP_SHARED_API void | Lock () |
Implements C# lock() statement locking. Call directly or use LockContext sentry object. More... | |
ASPOSECPP_SHARED_API void | Unlock () |
Implements C# lock() statement unlocking. Call directly or use LockContext sentry object. More... | |
virtual ASPOSECPP_SHARED_API bool | Equals (ptr obj) |
Compares objects using C# Object.Equals semantics. More... | |
virtual ASPOSECPP_SHARED_API int32_t | GetHashCode () const |
Analog of C# Object.GetHashCode() method. Enables hashing of custom objects. More... | |
virtual ASPOSECPP_SHARED_API String | ToString () const |
Analog of C# Object.ToString() method. Enables converting custom objects to string. More... | |
virtual ASPOSECPP_SHARED_API ptr | MemberwiseClone () const |
Analog of C# Object.MemberwiseClone() method. Enables cloning custom types. More... | |
virtual ASPOSECPP_SHARED_API const TypeInfo & | GetType () const |
Gets actual type of object. Analog of C# System.Object.GetType() call. More... | |
virtual ASPOSECPP_SHARED_API bool | Is (const TypeInfo &targetType) const |
Check if object represents an instance of type described by targetType. Analog of C# 'is' operator. More... | |
virtual ASPOSECPP_SHARED_API void | SetTemplateWeakPtr (uint32_t argument) |
Set n'th template argument a weak pointer (rather than shared). Allows switching pointers in containers to weak mode. More... | |
virtual ASPOSECPP_SHARED_API bool | FastCast (const Details::FastRttiBase &helper, void **out_ptr) const |
For internal purposes only. More... | |
template<> | |
bool | Equals (float const &objA, float const &objB) |
template<> | |
bool | Equals (double const &objA, double const &objB) |
template<> | |
bool | ReferenceEquals (String const &str, std::nullptr_t) |
template<> | |
bool | ReferenceEquals (String const &str1, String const &str2) |
Additional Inherited Members | |
Public Types inherited from System::Object | |
typedef SmartPtr< Object > | ptr |
Alias for smart pointer type. More... | |
Static Public Member Functions inherited from System::Object | |
static bool | ReferenceEquals (ptr const &objA, ptr const &objB) |
Compares objects by reference. More... | |
template<typename T > | |
static std::enable_if<!IsSmartPtr< T >::value, bool >::type | ReferenceEquals (T const &objA, T const &objB) |
Compares objects by reference. More... | |
template<typename T > | |
static std::enable_if<!IsSmartPtr< T >::value, bool >::type | ReferenceEquals (T const &objA, std::nullptr_t) |
Reference-compares value type object with nullptr. More... | |
template<typename T1 , typename T2 > | |
static std::enable_if< IsSmartPtr< T1 >::value &&IsSmartPtr< T2 >::value, bool >::type | Equals (T1 const &objA, T2 const &objB) |
Compares reference type objects in C# style. More... | |
template<typename T1 , typename T2 > | |
static std::enable_if<!IsSmartPtr< T1 >::value &&!IsSmartPtr< T2 >::value, bool >::type | Equals (T1 const &objA, T2 const &objB) |
Compares value type objects in C# style. More... | |
static const TypeInfo & | Type () |
Implements C# typeof(System.Object) construct. More... | |
Represents the interior of a graphic shape. Objects of this class should only be allocated using System::MakeObject() function. Never create instance of this type on stack or using operator new, as it will result in runtime errors and/or assertion faults. Always wrap this class into System::SmartPtr pointer and use this pointer to pass it to functions as argument.
ASPOSECPP_SHARED_API System::Drawing::Region::Region | ( | ) |
Constructs a new instance of Region class.
ASPOSECPP_SHARED_API System::Drawing::Region::Region | ( | const RectangleF & | rect | ) |
Constructs a new instance of Region class that represents a region defined by the specified rectangle.
rect | A rectangle that defines the region |
ASPOSECPP_SHARED_API System::Drawing::Region::Region | ( | const Rectangle & | rect | ) |
Constructs a new instance of Region class that represents a region defined by the specified rectangle.
rect | A rectangle that defines the region |
ASPOSECPP_SHARED_API System::Drawing::Region::Region | ( | const SharedPtr< Drawing2D::GraphicsPath > & | path | ) |
Constructs a new instance of Region class that represents a region defined by the specified path.
path | A path that defines the region |
ASPOSECPP_SHARED_API System::Drawing::Region::Region | ( | const SkPath & | path | ) |
ASPOSECPP_SHARED_API System::Drawing::Region::Region | ( | const SharedPtr< Drawing2D::RegionData > & | region_data | ) |
Constructs a new instance of Region class that represents a region defined by the specified RegionData object.
region_data | A RegionData object that defines the region |
|
virtual |
Destructor.
Returns a copy of the current object.
ASPOSECPP_SHARED_API void System::Drawing::Region::Complement | ( | const RectangleF & | rect | ) |
Replaces the region represented by the current object with the portion of the region defined by the specified recangle that does not intersect with this region.
rect | A rectangle that defines a region to complement |
ASPOSECPP_SHARED_API void System::Drawing::Region::Complement | ( | const Rectangle & | rect | ) |
Replaces the region represented by the current object with the portion of the region defined by the specified recangle that does not intersect with this region.
rect | A rectangle that defines a region to complement |
ASPOSECPP_SHARED_API void System::Drawing::Region::Complement | ( | const SharedPtr< Drawing2D::GraphicsPath > & | path | ) |
Replaces the region represented by the current object with the portion of the region defined by the specified path that does not intersect with this region.
path | A path that defines a region to complement |
Replaces the region represented by the current object with the portion of the specified region that does not intersect with this region.
region | A region to complement |
|
inline |
Releases all operating system resources acquired by the current object.
ASPOSECPP_SHARED_API bool System::Drawing::Region::Equals | ( | const SharedPtr< Region > & | r, |
const SharedPtr< Graphics > & | g | ||
) |
Determines whether the specified region is identical to the region represented by the current object on the specified drawing surface.
r | The region to compare this region with |
g | A drawing surface |
g
parameter is applied; otherwise - false ASPOSECPP_SHARED_API void System::Drawing::Region::Exclude | ( | const RectangleF & | rect | ) |
Replaces the region represented by the current object with the result of exclusion of the region defined by the specified rectange from it
rect | A rectangle that defines a region to exclude |
ASPOSECPP_SHARED_API void System::Drawing::Region::Exclude | ( | const Rectangle & | rect | ) |
Replaces the region represented by the current object with the result of exclusion of the region defined by the specified rectange from it
rect | A rectangle that defines a region to exclude |
ASPOSECPP_SHARED_API void System::Drawing::Region::Exclude | ( | const SharedPtr< Drawing2D::GraphicsPath > & | path | ) |
Replaces the region represented by the current object with the result of exclusion of the region defined by the specified path from it
path | A path that defines a region to exclude |
Replaces the region represented by the current object with the result of exclusion of the specified region from it
region | A region to exclude |
ASPOSECPP_SHARED_API RectangleF System::Drawing::Region::GetBounds | ( | const SharedPtr< Graphics > & | graphics | ) | const |
Gets a RectangleF structure that represents a rectangle that bounds this Region on the drawing surface of a Graphics object.
ASPOSECPP_SHARED_API SharedPtr<Drawing2D::RegionData> System::Drawing::Region::GetRegionData | ( | ) | const |
Returns a RegionData object containing data that defines the region represented by the current object.
ASPOSECPP_SHARED_API ArrayPtr<RectangleF> System::Drawing::Region::GetRegionScans | ( | const SharedPtr< Drawing2D::Matrix > & | matrix | ) | const |
Returns an array of RectangleF structures that approximate this Region after the specified matrix transformation is applied.
matrix | A Matrix that represents a geometric transformation to apply to the region. |
ASPOSECPP_SHARED_API void System::Drawing::Region::Intersect | ( | const RectangleF & | rect | ) |
Replaces the region represented by the current object with the result of intersection of this region and a region defined by the specified rectangle.
rect | A rectangle that defines a region to intersect this region with |
ASPOSECPP_SHARED_API void System::Drawing::Region::Intersect | ( | const Rectangle & | rect | ) |
Replaces the region represented by the current object with the result of intersection of this region and a region defined by the specified rectangle.
rect | A rectangle that defines a region to intersect this region with |
ASPOSECPP_SHARED_API void System::Drawing::Region::Intersect | ( | const SharedPtr< Drawing2D::GraphicsPath > & | path | ) |
Replaces the region represented by the current object with the result of intersection of this region and a region defined by the specified path.
path | A path that defines a region to intersect this region with |
Replaces the region represented by the current object with the result of intersection of this region and the specified region.
region | A region to intersect this region with |
Determines wheter the region represented by the current object has empty interior on the specified drawing surface.
g | A drawing surface |
ASPOSECPP_SHARED_API bool System::Drawing::Region::IsInfinite | ( | const SharedPtr< Graphics > & | g | ) | const |
Determines wheter the region represented by the current object has infinite interior on the specified drawing surface.
g | A drawing surface |
ASPOSECPP_SHARED_API bool System::Drawing::Region::IsVisible | ( | const Point & | point | ) | const |
Determines if the specified point is contained within the region represented by the current object.
point | The point to check |
ASPOSECPP_SHARED_API bool System::Drawing::Region::IsVisible | ( | const PointF & | point | ) | const |
Determines if the specified point is contained within the region represented by the current object.
point | The point to check |
ASPOSECPP_SHARED_API bool System::Drawing::Region::IsVisible | ( | const Rectangle & | rect | ) |
Determines if any portion the specified rectangle is contained within the region represented by the current object.
rect | The rectangle to check |
ASPOSECPP_SHARED_API bool System::Drawing::Region::IsVisible | ( | const RectangleF & | rect | ) |
Determines if any portion the specified rectangle is contained within the region represented by the current object.
rect | The rectangle to check |
ASPOSECPP_SHARED_API bool System::Drawing::Region::IsVisible | ( | const Point & | point, |
const SharedPtr< Graphics > & | graphics | ||
) | const |
Determines if the specified point is contained within the region represented by the current object using the specified graphics.
point | The point to check |
graphics | The graphics context |
ASPOSECPP_SHARED_API bool System::Drawing::Region::IsVisible | ( | const PointF & | point, |
const SharedPtr< Graphics > & | graphics | ||
) | const |
Determines if the specified point is contained within the region represented by the current object using the specified graphics.
point | The point to check |
graphics | The graphics context |
ASPOSECPP_SHARED_API bool System::Drawing::Region::IsVisible | ( | const Rectangle & | rect, |
const SharedPtr< Graphics > & | graphics | ||
) |
Determines if any portion the specified rectangle is contained within the region represented by the current object using the specified graphics.
rect | The rectangle to check |
graphics | The graphics context |
ASPOSECPP_SHARED_API bool System::Drawing::Region::IsVisible | ( | const RectangleF & | rect, |
const SharedPtr< Graphics > & | graphics | ||
) |
Determines if any portion the specified rectangle is contained within the region represented by the current object using the specified graphics.
rect | The rectangle to check |
graphics | The graphics context |
ASPOSECPP_SHARED_API bool System::Drawing::Region::IsVisible | ( | float | x, |
float | y | ||
) | const |
Determines if the specified point is contained within the region represented by the current object.
x | The X coordinate of the point to check |
y | The Y coordinate of the point to check |
ASPOSECPP_SHARED_API bool System::Drawing::Region::IsVisible | ( | float | x, |
float | y, | ||
const SharedPtr< Graphics > & | graphics | ||
) | const |
Determines if the specified point is contained within the region represented by the current object using the specified graphics.
x | The X coordinate of the point to check |
y | The Y coordinate of the point to check |
graphics | The graphics context |
ASPOSECPP_SHARED_API void System::Drawing::Region::MakeEmpty | ( | ) |
Initializes the current object to empty interior.
ASPOSECPP_SHARED_API void System::Drawing::Region::MakeInfinite | ( | ) |
Initializes this region object to an infinite interior.
ASPOSECPP_SHARED_API void System::Drawing::Region::Transform | ( | const SharedPtr< Drawing2D::Matrix > & | matrix | ) |
Transforms this region by the specified matrix.
matrix | Transformation matrix |
ASPOSECPP_SHARED_API void System::Drawing::Region::Transform | ( | const SkMatrix & | matrix | ) |
Transforms this region by the specified matrix.
matrix | Transformation matrix |
ASPOSECPP_SHARED_API void System::Drawing::Region::Translate | ( | int | dx, |
int | dy | ||
) |
Moves the coordinates of the region by the specified amount.
dx | Specifies the amount to move the region by horizontally |
dy | Specifies the amount to move the region by vertically |
ASPOSECPP_SHARED_API void System::Drawing::Region::Translate | ( | float | dx, |
float | dy | ||
) |
Moves the coordinates of the region by the specified amount.
dx | Specifies the amount to move the region by horizontally |
dy | Specifies the amount to move the region by vertically |
ASPOSECPP_SHARED_API void System::Drawing::Region::Union | ( | const RectangleF & | rect | ) |
Replaces the region represented by the current object with the result of union operation of this region and a region defined by the specified rectangle.
rect | A rectangle that defines a region to unite this region with |
ASPOSECPP_SHARED_API void System::Drawing::Region::Union | ( | const Rectangle & | rect | ) |
Replaces the region represented by the current object with the result of union of this region and a region defined by the specified rectangle.
rect | A rectangle that defines a region to unite this region with |
ASPOSECPP_SHARED_API void System::Drawing::Region::Union | ( | const SharedPtr< Drawing2D::GraphicsPath > & | path | ) |
Replaces the region represented by the current object with the result of union of this region and a region defined by the specified path.
path | A path that defines a region to unite this region with |
Replaces the region represented by the current object with the result of union of this region and and the specified region.
region | A region to unite this region with |
ASPOSECPP_SHARED_API void System::Drawing::Region::Xor | ( | const RectangleF & | rect | ) |
Replaces the region represented by the current object with the portions of this region and the region defined by the specified recangle that do not intersect.
rect | A rectangle that defines a region to xor with the region represented by the current object |
ASPOSECPP_SHARED_API void System::Drawing::Region::Xor | ( | const Rectangle & | rect | ) |
Replaces the region represented by the current object with the portions of this region and the region defined by the specified recangle that do not intersect.
rect | A rectangle that defines a region to xor with the region represented by the current object |
ASPOSECPP_SHARED_API void System::Drawing::Region::Xor | ( | const SharedPtr< Drawing2D::GraphicsPath > & | path | ) |
Replaces the region represented by the current object with the portions of this region and the region defined by the specified path that do not intersect.
path | A path that defines a region to xor with the region represented by the current object |
Replaces the region represented by the current object with the portions of this region and the specified region that do not intersect.
region | A region to xor with the region represented by the current object |