Aspose::Pdf::Engine::Presentation::Graphics::Size Class Reference

Represents size. More...

Inherits System::Object.

Public Member Functions

bool get_IsEmpty ()
 Gets a value indicating whether this Aspose::Pdf::Engine::Presentation::Graphics::Size has width and height of 0. More...
 
int32_t get_Width ()
 Gets the horizontal component of this Aspose::Pdf::Engine::Presentation::Graphics::Size. More...
 
void set_Width (int32_t value)
 Sets the horizontal component of this Aspose::Pdf::Engine::Presentation::Graphics::Size. More...
 
int32_t get_Height ()
 Gets the vertical component of this Aspose::Pdf::Engine::Presentation::Graphics::Size. More...
 
void set_Height (int32_t value)
 Sets the vertical component of this Aspose::Pdf::Engine::Presentation::Graphics::Size. More...
 
 Size (Point point)
 Initializes a new instance of the Aspose::Pdf::Engine::Presentation::Graphics::Size structure from the specified Aspose::Pdf::Engine::Presentation::Graphics::Point. More...
 
 Size (int32_t width, int32_t height)
 Initializes a new instance of the Aspose::Pdf::Engine::Presentation::Graphics::Size structure from the specified dimensions. More...
 
virtual int32_t GetHashCode () const
 Returns a hash code for this Aspose::Pdf::Engine::Presentation::Graphics::Size structure. More...
 
virtual System::String ToString () const
 Creates a human-readable string that represents this Aspose::Pdf::Engine::Presentation::Graphics::Size. More...
 
 Size ()
 
- 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...
 
Objectoperator= (Object const &x)
 Assignment operator. Doesn't copy anything, really, just initializes new object and enables copy constructing subclasses. More...
 
ObjectSharedRefAdded ()
 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 refernce 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 String ToString () ASPOSE_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 TypeInfoGetType () 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 (unsigned int argument)
 Set n'th template argument a weak pointer (rather than shared). Allows switching pointers in containers to weak mode. 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)
 

Static Public Member Functions

static Size get_Empty ()
 Gets a new instance of the Aspose::Pdf::Engine::Presentation::Graphics::Size structure that has Aspose::Pdf::Engine::Presentation::Graphics::Size::Width and Aspose::Pdf::Engine::Presentation::Graphics::Size::Height values set to zero. More...
 
static SizeF to_SizeF (Size size)
 
static Point to_Point (Size size)
 
static Size Add (Size size1, Size size2)
 Adds the width and height of one Aspose::Pdf::Engine::Presentation::Graphics::Size structure to the width and height of another Aspose::Pdf::Engine::Presentation::Graphics::Size structure. More...
 
static Size Ceiling (SizeF size)
 Converts the specified Aspose::Pdf::Engine::Presentation::Graphics::SizeF structure to a Aspose::Pdf::Engine::Presentation::Graphics::Size structure by rounding the values of the Aspose::Pdf::Engine::Presentation::Graphics::Size structure to the next higher integer values. More...
 
static Size Subtract (Size size1, Size size2)
 Subtracts the width and height of one Aspose::Pdf::Engine::Presentation::Graphics::Size structure from the width and height of another Aspose::Pdf::Engine::Presentation::Graphics::Size structure. More...
 
static Size Truncate (SizeF size)
 Converts the specified Aspose::Pdf::Engine::Presentation::Graphics::SizeF structure to a Aspose::Pdf::Engine::Presentation::Graphics::Size structure by truncating the values of the Aspose::Pdf::Engine::Presentation::Graphics::SizeF structure to the next lower integer values. More...
 
static Size Round (SizeF size)
 Converts the specified Aspose::Pdf::Engine::Presentation::Graphics::SizeF structure to a Aspose::Pdf::Engine::Presentation::Graphics::Size structure by rounding the values of the Aspose::Pdf::Engine::Presentation::Graphics::SizeF structure to the nearest integer values. 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 TypeInfoType ()
 Impleemnts C# typeof(System.Object) construct. More...
 

Static Protected Attributes

static System::String SizeFormat
 

Friends

ASPOSE_PDF_SHARED_API Size operator+ (Size size1, Size size2)
 
ASPOSE_PDF_SHARED_API Size operator- (Size size1, Size size2)
 
ASPOSE_PDF_SHARED_API bool operator== (Size const &size1, Size const &size2)
 
ASPOSE_PDF_SHARED_API bool operator!= (Size const &size1, Size const &size2)
 

Additional Inherited Members

- Public Types inherited from System::Object
typedef SmartPtr< Objectptr
 Alias for smart pointer type. More...
 
typedef System::Details::SharedMembersType shared_members_type
 structure to keep list of shared pointers contained in object. More...
 

Detailed Description

Represents size.

Constructor & Destructor Documentation

◆ Size() [1/3]

Aspose::Pdf::Engine::Presentation::Graphics::Size::Size ( Point  point)

◆ Size() [2/3]

Aspose::Pdf::Engine::Presentation::Graphics::Size::Size ( int32_t  width,
int32_t  height 
)

Initializes a new instance of the Aspose::Pdf::Engine::Presentation::Graphics::Size structure from the specified dimensions.

Parameters
widthThe width component of the new Aspose::Pdf::Engine::Presentation::Graphics::Size.
heightThe height component of the new Aspose::Pdf::Engine::Presentation::Graphics::Size.

◆ Size() [3/3]

Aspose::Pdf::Engine::Presentation::Graphics::Size::Size ( )

Member Function Documentation

◆ Add()

static Size Aspose::Pdf::Engine::Presentation::Graphics::Size::Add ( Size  size1,
Size  size2 
)
static

Adds the width and height of one Aspose::Pdf::Engine::Presentation::Graphics::Size structure to the width and height of another Aspose::Pdf::Engine::Presentation::Graphics::Size structure.

Parameters
size1The first Aspose::Pdf::Engine::Presentation::Graphics::Size to add.
size2The second Aspose::Pdf::Engine::Presentation::Graphics::Size to add.
Returns
A Aspose::Pdf::Engine::Presentation::Graphics::Size structure that is the result of the addition operation.

◆ Ceiling()

static Size Aspose::Pdf::Engine::Presentation::Graphics::Size::Ceiling ( SizeF  size)
static

Converts the specified Aspose::Pdf::Engine::Presentation::Graphics::SizeF structure to a Aspose::Pdf::Engine::Presentation::Graphics::Size structure by rounding the values of the Aspose::Pdf::Engine::Presentation::Graphics::Size structure to the next higher integer values.

Parameters
sizeThe Aspose::Pdf::Engine::Presentation::Graphics::SizeF structure to convert.
Returns
The Aspose::Pdf::Engine::Presentation::Graphics::Size structure this method converts to.

◆ get_Empty()

static Size Aspose::Pdf::Engine::Presentation::Graphics::Size::get_Empty ( )
static

Gets a new instance of the Aspose::Pdf::Engine::Presentation::Graphics::Size structure that has Aspose::Pdf::Engine::Presentation::Graphics::Size::Width and Aspose::Pdf::Engine::Presentation::Graphics::Size::Height values set to zero.

◆ get_Height()

int32_t Aspose::Pdf::Engine::Presentation::Graphics::Size::get_Height ( )

Gets the vertical component of this Aspose::Pdf::Engine::Presentation::Graphics::Size.

◆ get_IsEmpty()

bool Aspose::Pdf::Engine::Presentation::Graphics::Size::get_IsEmpty ( )

Gets a value indicating whether this Aspose::Pdf::Engine::Presentation::Graphics::Size has width and height of 0.

◆ get_Width()

int32_t Aspose::Pdf::Engine::Presentation::Graphics::Size::get_Width ( )

Gets the horizontal component of this Aspose::Pdf::Engine::Presentation::Graphics::Size.

◆ GetHashCode()

virtual int32_t Aspose::Pdf::Engine::Presentation::Graphics::Size::GetHashCode ( ) const
virtual

Returns a hash code for this Aspose::Pdf::Engine::Presentation::Graphics::Size structure.

Returns
An integer value that specifies a hash value for this Aspose::Pdf::Engine::Presentation::Graphics::Size structure.

Reimplemented from System::Object.

◆ Round()

static Size Aspose::Pdf::Engine::Presentation::Graphics::Size::Round ( SizeF  size)
static

Converts the specified Aspose::Pdf::Engine::Presentation::Graphics::SizeF structure to a Aspose::Pdf::Engine::Presentation::Graphics::Size structure by rounding the values of the Aspose::Pdf::Engine::Presentation::Graphics::SizeF structure to the nearest integer values.

Parameters
sizeThe Aspose::Pdf::Engine::Presentation::Graphics::SizeF structure to convert.
Returns
The Aspose::Pdf::Engine::Presentation::Graphics::Size structure this method converts to.

◆ set_Height()

void Aspose::Pdf::Engine::Presentation::Graphics::Size::set_Height ( int32_t  value)

Sets the vertical component of this Aspose::Pdf::Engine::Presentation::Graphics::Size.

◆ set_Width()

void Aspose::Pdf::Engine::Presentation::Graphics::Size::set_Width ( int32_t  value)

Sets the horizontal component of this Aspose::Pdf::Engine::Presentation::Graphics::Size.

◆ Subtract()

static Size Aspose::Pdf::Engine::Presentation::Graphics::Size::Subtract ( Size  size1,
Size  size2 
)
static

Subtracts the width and height of one Aspose::Pdf::Engine::Presentation::Graphics::Size structure from the width and height of another Aspose::Pdf::Engine::Presentation::Graphics::Size structure.

Parameters
size1The Aspose::Pdf::Engine::Presentation::Graphics::Size structure on the left side of the subtraction operator.
size2The Aspose::Pdf::Engine::Presentation::Graphics::Size structure on the right side of the subtraction operator.
Returns
The Aspose::Pdf::Engine::Presentation::Graphics::Size that is a result of the subtraction operation.

◆ to_Point()

static Point Aspose::Pdf::Engine::Presentation::Graphics::Size::to_Point ( Size  size)
static

◆ to_SizeF()

static SizeF Aspose::Pdf::Engine::Presentation::Graphics::Size::to_SizeF ( Size  size)
static

◆ ToString()

virtual System::String Aspose::Pdf::Engine::Presentation::Graphics::Size::ToString ( ) const
virtual

Creates a human-readable string that represents this Aspose::Pdf::Engine::Presentation::Graphics::Size.

Returns
A string that represents this Aspose::Pdf::Engine::Presentation::Graphics::Size.

◆ Truncate()

static Size Aspose::Pdf::Engine::Presentation::Graphics::Size::Truncate ( SizeF  size)
static

Converts the specified Aspose::Pdf::Engine::Presentation::Graphics::SizeF structure to a Aspose::Pdf::Engine::Presentation::Graphics::Size structure by truncating the values of the Aspose::Pdf::Engine::Presentation::Graphics::SizeF structure to the next lower integer values.

Parameters
sizeThe Aspose::Pdf::Engine::Presentation::Graphics::SizeF structure to convert.
Returns
The Aspose::Pdf::Engine::Presentation::Graphics::Size structure this method converts to.

Friends And Related Function Documentation

◆ operator!=

ASPOSE_PDF_SHARED_API bool operator!= ( Size const &  size1,
Size const &  size2 
)
friend

◆ operator+

ASPOSE_PDF_SHARED_API Size operator+ ( Size  size1,
Size  size2 
)
friend

◆ operator-

ASPOSE_PDF_SHARED_API Size operator- ( Size  size1,
Size  size2 
)
friend

◆ operator==

ASPOSE_PDF_SHARED_API bool operator== ( Size const &  size1,
Size const &  size2 
)
friend

Member Data Documentation

◆ SizeFormat

System::String Aspose::Pdf::Engine::Presentation::Graphics::Size::SizeFormat
staticprotected