esvg::Dimension Class Reference
#include <Dimension.hpp>
Public Member Functions | |
Dimension () | |
Dimension (const vec2 &_size, enum esvg::distance _type=esvg::distance_pixel) | |
Dimension (const std::string &_config) | |
Dimension (const std::string &_configX, const std::string &_configY) | |
~Dimension () | |
operator std::string () const | |
const vec2 & | getValue () const |
enum distance | getType () const |
void | set (const vec2 &_size, enum distance _type) |
void | set (std::string _config) |
void | set (std::string _configX, std::string _configY) |
vec2 | getPixel (const vec2 &_upperSize) const |
const Dimension & | operator= (const Dimension &_obj) |
bool | operator== (const Dimension &_obj) const |
bool | operator!= (const Dimension &_obj) const |
Detailed Description
in the dimention class we store the data as the more usefull unit (pixel) but one case need to be dynamic the %, then when requested in % the register the % value
Constructor & Destructor Documentation
§ Dimension() [1/4]
esvg::Dimension::Dimension | ( | ) |
Constructor (default :0,0 mode pixel)
§ Dimension() [2/4]
esvg::Dimension::Dimension | ( | const vec2 & | _size, |
enum esvg::distance | _type = esvg::distance_pixel |
||
) |
Constructor.
- Parameters
-
[in] _size Requested dimention [in] _type Unit of the Dimention
§ Dimension() [3/4]
|
inline |
Constructor.
- Parameters
-
[in] _config dimension configuration.
§ Dimension() [4/4]
|
inline |
Constructor.
- Parameters
-
[in] _configX dimension X configuration. [in] _configY dimension Y configuration.
§ ~Dimension()
esvg::Dimension::~Dimension | ( | ) |
Destructor.
Member Function Documentation
§ getPixel()
get the current dimention in pixel
- Parameters
-
[in] _upperSize Size in pixel of the upper value
- Returns
- dimention in Pixel
§ getType()
|
inline |
get the dimension type
- Returns
- the type
§ getValue()
|
inline |
get the current dimention.
- Returns
- dimention requested.
§ operator std::string()
esvg::Dimension::operator std::string | ( | ) | const |
string cast :
§ set() [1/3]
set the current dimention in requested type
- Parameters
-
[in] _size Dimention to set [in] _type Type of unit requested.
§ set() [2/3]
void esvg::Dimension::set | ( | std::string | _config | ) |
set the current dimention in requested type
- Parameters
-
[in] _config dimension configuration.
§ set() [3/3]
void esvg::Dimension::set | ( | std::string | _configX, |
std::string | _configY | ||
) |
set the current dimention in requested type
- Parameters
-
[in] _configX dimension X configuration. [in] _configY dimension Y configuration.
The documentation for this class was generated from the following file:
- framework/atria-soft/esvg/esvg/Dimension.hpp