libelemental 2.0.2
|
A base class for qualified values which have representative colors. More...
#include <value.hh>
Public Member Functions | |
virtual color | get_color () const throw () =0 |
Returns a color representing the value. | |
![]() | |
bool | has_value () const throw () |
Returns whether the value is defined. | |
virtual ustring | get_string (const ustring &format=ustring()) const throw () |
Returns a localized text representation of the value. | |
ustring | get_tip () const throw () |
Returns a localized message to be displayed as a tooltip. | |
void | make_entry (EntriesView &view, const ustring &name, const ustring &format=ustring()) const throw () |
Possibly adds the result of get_string() to an EntriesView. | |
virtual int | compare (const value_base &other) const throw () |
Compares two qualified values. | |
Protected Member Functions | |
color_value_base (Qualifier qualifier) throw () | |
![]() | |
value_base (Qualifier qualifier) throw () | |
virtual ustring | do_get_string (const ustring &format) const throw () =0 |
Returns a localized text representation of a defined value. | |
virtual int | compare_base (const value_base &other) const throw () |
Compares the qualifications of two values. | |
Additional Inherited Members | |
![]() | |
Qualifier | qualifier |
The qualification of the value's meaning. | |
![]() | |
bool | always |
Whether an undefined value should make an entry. | |
![]() | |
static const int | YIELD_COMPARE |
Indicates that comparison should be based on values, not definedness. | |
A base class for qualified values which have representative colors.
|
protected |
qualifier | The qualification of the initial value. |
|
pure virtual |
Returns a color representing the value.
Derived classes must implement this function, returning a color that corresponds to the defined value. A special color should be returned if has_value() is false
.
Implemented in Elemental::Series, Elemental::Block, Elemental::Phase, Elemental::LatticeType, and Elemental::ColorValue.