Represents a pair of single-precision floating point values that represent width and height of an image. This type should be allocated on stack and passed to functions by value or by reference. Never use System::SmartPtr class to manage objects of this type.
More...
#include <size_f.h>
|
| | SizeF () |
| | Constructs a new SizeF object and initializes its width and height values with 0. More...
|
| |
| | SizeF (const PointF &point) |
| | Constructs a new SizeF object and initializes its width and height values with the values of X and Y coordinates of the specifide point correspondingly. More...
|
| |
| | SizeF (float width, float height) |
| | Constructs a new SizeF object and initializes it with the specified value. More...
|
| |
| bool | get_IsEmpty () const |
| | Determines if both width and hegiht values are equal to 0. More...
|
| |
| float | get_Width () const |
| | Returns the value of width represented by the current object. More...
|
| |
| float | get_Height () const |
| | Returns the value of height represented by the current object. More...
|
| |
| void | set_Width (float value) |
| | Sets the value of width represented by the current object. More...
|
| |
| void | set_Height (float value) |
| | Sets the value of height represented by the current object. More...
|
| |
| bool | Equals (const SizeF &size) const |
| | Determines if the current object and the specified object are equal, i.e. represent the same pair of width and hegiht values. More...
|
| |
| PointF | ToPointF () const |
| | Converts the current object to an instance of Point object by initializing its X and Y coordinate with the current object's width and height values correspondingly. More...
|
| |
| Size | ToSize () const |
| | Constructs a Size object from the current SizeF object by truncating the SizeF object's width and height values to the next lower integer values. More...
|
| |
| System::String | ToString () const |
| | Returns the string representation of the pair of width and hegiht values represented by the current object. More...
|
| |
| int32_t | GetHashCode () const |
| | Returns a hash code for the current object. More...
|
| |
| | operator PointF () const |
| | Converts the current object to an instance of Point object by initializing its X and Y coordinate with the current object's width and height values correspondingly. More...
|
| |
| SizeF & | operator+= (const SizeF &size) |
| | Adds the specified SizeF object's width and height values to the width and height values of the current SizeF object correspondingly. More...
|
| |
|
| static SizeF | Add (const SizeF &size1, const SizeF &size2) |
| | Returns a new SizeF object that is a sum of the specified SizeF objects, i.e. whose width value is equal to the sum of width values of the specified objects and height value is equal to the sum of height values of the specified objects. More...
|
| |
| static SizeF | Subtract (const SizeF &size1, const SizeF &size2) |
| | Returns a new SizeF object that is the results of subctraction of size2 from size1, i.e. whose width value is the result of subtraction of size2's width value from size1's width value and height value is the result of subtraction of size2's height value from size1's height value. More...
|
| |
Represents a pair of single-precision floating point values that represent width and height of an image. This type should be allocated on stack and passed to functions by value or by reference. Never use System::SmartPtr class to manage objects of this type.
◆ SizeF() [1/3]
| System::Drawing::SizeF::SizeF |
( |
| ) |
|
Constructs a new SizeF object and initializes its width and height values with 0.
◆ SizeF() [2/3]
| System::Drawing::SizeF::SizeF |
( |
const PointF & |
point | ) |
|
Constructs a new SizeF object and initializes its width and height values with the values of X and Y coordinates of the specifide point correspondingly.
- Parameters
-
| point | A Point object whose X and Y coordinates are used to initialize width and height value of the SizeF object being created |
◆ SizeF() [3/3]
| System::Drawing::SizeF::SizeF |
( |
float |
width, |
|
|
float |
height |
|
) |
| |
Constructs a new SizeF object and initializes it with the specified value.
- Parameters
-
| width | The value to width |
| height | The value of height |
◆ Add()
| static SizeF System::Drawing::SizeF::Add |
( |
const SizeF & |
size1, |
|
|
const SizeF & |
size2 |
|
) |
| |
|
static |
Returns a new SizeF object that is a sum of the specified SizeF objects, i.e. whose width value is equal to the sum of width values of the specified objects and height value is equal to the sum of height values of the specified objects.
- Parameters
-
| size1 | The first operand |
| size2 | The second operand |
- Returns
- The SizeF object which is the sum of
size1 and size2
◆ Equals()
| bool System::Drawing::SizeF::Equals |
( |
const SizeF & |
size | ) |
const |
Determines if the current object and the specified object are equal, i.e. represent the same pair of width and hegiht values.
- Parameters
-
| size | The object to compare the current object with |
- Returns
- True if the objects are equal, otherwise - false
◆ get_Height()
| float System::Drawing::SizeF::get_Height |
( |
| ) |
const |
|
inline |
Returns the value of height represented by the current object.
◆ get_IsEmpty()
| bool System::Drawing::SizeF::get_IsEmpty |
( |
| ) |
const |
|
inline |
Determines if both width and hegiht values are equal to 0.
- Returns
- True if both width and height represented by the current object are 0; otherwise - false
◆ get_Width()
| float System::Drawing::SizeF::get_Width |
( |
| ) |
const |
|
inline |
Returns the value of width represented by the current object.
◆ GetHashCode()
| int32_t System::Drawing::SizeF::GetHashCode |
( |
| ) |
const |
Returns a hash code for the current object.
◆ operator PointF()
| System::Drawing::SizeF::operator PointF |
( |
| ) |
const |
Converts the current object to an instance of Point object by initializing its X and Y coordinate with the current object's width and height values correspondingly.
◆ operator+=()
| SizeF & System::Drawing::SizeF::operator+= |
( |
const SizeF & |
size | ) |
|
Adds the specified SizeF object's width and height values to the width and height values of the current SizeF object correspondingly.
- Parameters
-
- Returns
- A reference to the self
◆ set_Height()
| void System::Drawing::SizeF::set_Height |
( |
float |
value | ) |
|
|
inline |
Sets the value of height represented by the current object.
- Parameters
-
◆ set_Width()
| void System::Drawing::SizeF::set_Width |
( |
float |
value | ) |
|
|
inline |
Sets the value of width represented by the current object.
- Parameters
-
◆ Subtract()
| static SizeF System::Drawing::SizeF::Subtract |
( |
const SizeF & |
size1, |
|
|
const SizeF & |
size2 |
|
) |
| |
|
static |
Returns a new SizeF object that is the results of subctraction of size2 from size1, i.e. whose width value is the result of subtraction of size2's width value from size1's width value and height value is the result of subtraction of size2's height value from size1's height value.
- Parameters
-
| size1 | The SizeF object to subtract from |
| size2 | The SizeF object to subtract |
- Returns
- The SizeF object which is the result of subtraction of
size2 from size1
◆ ToPointF()
| PointF System::Drawing::SizeF::ToPointF |
( |
| ) |
const |
Converts the current object to an instance of Point object by initializing its X and Y coordinate with the current object's width and height values correspondingly.
◆ ToSize()
| Size System::Drawing::SizeF::ToSize |
( |
| ) |
const |
Constructs a Size object from the current SizeF object by truncating the SizeF object's width and height values to the next lower integer values.
- Returns
- A Size object constructed from the current object
◆ ToString()
Returns the string representation of the pair of width and hegiht values represented by the current object.
◆ Empty
| const SizeF System::Drawing::SizeF::Empty |
|
static |
An empty instance of SizeF class whose width and height values are 0.