7#ifndef MYGUI_RESIZING_POLICY_H_
8#define MYGUI_RESIZING_POLICY_H_
36 const char* name = type.getValueName(value);
37 if (strcmp(name,
"") == 0 || name == _value)
41 type.mValue =
Enum(value);
47 return a.mValue == b.mValue;
52 return a.mValue != b.mValue;
55 friend std::ostream& operator << (std::ostream& _stream,
const ResizingPolicy& _value)
57 _stream << _value.getValueName(_value.mValue);
61 friend std::istream& operator >> (std::istream& _stream,
ResizingPolicy& _value)
65 _value = parse(value);
71 return getValueName(mValue);
80 const char* getValueName(
int _index)
const
82 static const char* values[MAX + 1] = {
"Auto",
"Fixed",
"Fill",
"" };
83 return values[(_index < MAX && _index >= 0) ? _index : MAX];
bool operator==(const UString::_const_fwd_iterator &left, const UString::_const_fwd_iterator &right)
bool operator!=(const UString::_const_fwd_iterator &left, const UString::_const_fwd_iterator &right)
static ResizingPolicy parse(const std::string &_value)
std::string print() const
ResizingPolicy(Enum _value=MAX)