[DEV] add debug on dimention
This commit is contained in:
parent
810abe02bc
commit
11515a82f5
2
external/etk
vendored
2
external/etk
vendored
@ -1 +1 @@
|
||||
Subproject commit b75f2ea69853af387d92374a0cd56fedf766ddbf
|
||||
Subproject commit 7dca8979c6548a6d0f355c2c33535c3a553ef8a0
|
@ -79,13 +79,17 @@ ewol::Dimension::Dimension(void) :
|
||||
// notinh to do ...
|
||||
}
|
||||
|
||||
ewol::Dimension::Dimension(const vec2& _size, ewol::Dimension::distance_te _type)
|
||||
ewol::Dimension::Dimension(const vec2& _size, ewol::Dimension::distance_te _type) :
|
||||
m_data(0,0),
|
||||
m_type(ewol::Dimension::Pixel)
|
||||
{
|
||||
Set(_size, _type);
|
||||
}
|
||||
|
||||
void ewol::Dimension::Set(etk::UString _config)
|
||||
{
|
||||
m_data.setValue(0,0);
|
||||
m_type = ewol::Dimension::Pixel;
|
||||
distance_te type = ewol::Dimension::Pixel;
|
||||
if (_config.EndWith("%",false)==true) {
|
||||
type = ewol::Dimension::Pourcent;
|
||||
@ -111,9 +115,13 @@ void ewol::Dimension::Set(etk::UString _config)
|
||||
} else if (_config.EndWith("m",false)==true) {
|
||||
type = ewol::Dimension::Meter;
|
||||
_config.Remove(_config.Size()-1, 1);
|
||||
} else {
|
||||
EWOL_CRITICAL("Can not parse dimention : \"" << _config << "\"");
|
||||
return;
|
||||
}
|
||||
vec2 tmp = _config;
|
||||
Set(tmp, type);
|
||||
EWOL_ERROR(" config dimention : \"" << _config << "\" ==> " << *this );
|
||||
}
|
||||
|
||||
ewol::Dimension::~Dimension(void)
|
||||
|
@ -50,12 +50,12 @@ namespace ewol
|
||||
* @brief Constructor
|
||||
* @param[in] _config dimension configuration.
|
||||
*/
|
||||
Dimension(const etk::UString& _config) { Set(_config); };
|
||||
Dimension(const etk::UString& _config) : m_data(0,0),m_type(ewol::Dimension::Pixel) { Set(_config); };
|
||||
/**
|
||||
* @brief Constructor
|
||||
* @param[in] _config dimension configuration.
|
||||
*/
|
||||
Dimension(const char* _config) { Set(_config); };
|
||||
Dimension(const char* _config) : m_data(0,0),m_type(ewol::Dimension::Pixel) { Set(_config); };
|
||||
/**
|
||||
* @brief Destructor
|
||||
*/
|
||||
|
Loading…
x
Reference in New Issue
Block a user