Hot Door CORE  0.7.0
Adobe® Illustrator® Plug-in Library
Public Member Functions | Public Attributes | Friends | List of all members
hdi::core::Size Class Reference

Contains a width and height for a rectangular shape. More...

#include <hdicoreSize.h>

Public Member Functions

 Size ()
 Default Size constructor; sets width and height to 0.0. More...
 
 Size (const double width_, const double height_)
 Size constructor, taking width and height arguments. More...
 
 Size (const Size &size_)
 Size copy constructor. More...
 
virtual ~Size ()
 Size destructor. More...
 
virtual Sizeoperator= (const Size &rhs_)
 Sets a Size object from another Size object. More...
 
virtual bool operator== (const Size &rhs_) const
 Tests whether a given Size object is the same as another. More...
 
virtual bool operator!= (const Size &rhs_) const
 Tests whether a given Size object is not the same as another. More...
 
virtual Size operator+ (const Size &rhs_) const
 Allows two sizes to have their width and height values added using the + operator. More...
 
virtual Sizeoperator+= (const Size &rhs_)
 Allows two sizes to have their width and height values added and assigned using the += operator. More...
 
virtual Size operator- (const Size &rhs_) const
 Allows two sizes to have their width and height values subtracted using the - operator. More...
 
virtual Sizeoperator-= (const Size &rhs_)
 Allows two sizes to have their width and height values subtracted and assigned using the -= operator. More...
 
virtual Angle diagonalAngle () const
 Gets the angle from the top-left to the bottom-right of the "box" made by the Size object. More...
 
virtual double diagonalLength () const
 Gets the length of the hypotenuse formed from the top-left to the bottom-right of the "box" made by the width and height. More...
 

Public Attributes

double width
 Width of the item.
 
double height
 

Friends

geo::Size * __accessImpl (const Size &)
 
Size __accessCtor (const geo::Size &)
 

Detailed Description

Contains a width and height for a rectangular shape.

Constructor & Destructor Documentation

hdi::core::Size::Size ( )

Default Size constructor; sets width and height to 0.0.

Author
GW
Date
08/2013
hdi::core::Size::Size ( const double  width_,
const double  height_ 
)

Size constructor, taking width and height arguments.

Author
GW
Date
08/2013
Parameters
width_Width of the item
height_Height of the item
hdi::core::Size::Size ( const Size size_)

Size copy constructor.

Author
GW
Date
08/2013
Parameters
size_Existing Size object to copy
virtual hdi::core::Size::~Size ( )
virtual

Size destructor.

Author
GW
Date
08/2013

Member Function Documentation

virtual Angle hdi::core::Size::diagonalAngle ( ) const
virtual

Gets the angle from the top-left to the bottom-right of the "box" made by the Size object.

Author
GW
Date
08/2013
Returns
The angle from the top-left to the bottom-right
virtual double hdi::core::Size::diagonalLength ( ) const
virtual

Gets the length of the hypotenuse formed from the top-left to the bottom-right of the "box" made by the width and height.

Author
GW
Date
08/2013
Returns
The length from the top-left to the bottom-right
virtual bool hdi::core::Size::operator!= ( const Size rhs_) const
virtual

Tests whether a given Size object is not the same as another.

Author
GW
Date
08/2013
Parameters
rhs_Size to compare against (righthand side of inequality operator)
Returns
true for the target and rhs_ being different sizes, false otherwise
virtual Size hdi::core::Size::operator+ ( const Size rhs_) const
virtual

Allows two sizes to have their width and height values added using the + operator.

Author
GW
Date
08/2013
Parameters
rhs_Righthand side of the + operator
Returns
A copy of the target Size, with all width and height values summed together
virtual Size& hdi::core::Size::operator+= ( const Size rhs_)
virtual

Allows two sizes to have their width and height values added and assigned using the += operator.

Author
GW
Date
08/2013
Parameters
rhs_Righthand side of the += operator
Returns
The lefthand side of the += operator, with all width and height values summed together
virtual Size hdi::core::Size::operator- ( const Size rhs_) const
virtual

Allows two sizes to have their width and height values subtracted using the - operator.

Author
GW
Date
08/2013
Parameters
rhs_Righthand side of the - operator
Returns
A copy of the target Size, with rhs_ width and height values subtracted from this width and height
virtual Size& hdi::core::Size::operator-= ( const Size rhs_)
virtual

Allows two sizes to have their width and height values subtracted and assigned using the -= operator.

Author
GW
Date
08/2013
Parameters
rhs_Righthand side of the -= operator
Returns
The lefthand side of the -= operator, with rhs_ width and height values subtracted from this width and height
virtual Size& hdi::core::Size::operator= ( const Size rhs_)
virtual

Sets a Size object from another Size object.

Author
GW
Date
08/2013
Parameters
rhs_Righthand side of the = operator; Size object to pull values from
Returns
The target Size object, but with its value updated
virtual bool hdi::core::Size::operator== ( const Size rhs_) const
virtual

Tests whether a given Size object is the same as another.

Author
GW
Date
08/2013
Parameters
rhs_Size to compare against (righthand side of equality operator)
Returns
true for the target and rhs_ being the same size, false otherwise

Member Data Documentation

double hdi::core::Size::height

brief Height of the item