Main Page | Namespace List | Class Hierarchy | Class List | File List | Namespace Members | Class Members

esve::components::dimn::Valuator< T_Value > Class Template Reference

A user-interface widget representing a given value type. More...

#include <esve/components/dimn/Valuator.hxx>

List of all members.

Public Member Functions

virtual T_Value value () const =0
 Query the current value.

virtual Valuatorvalue (const T_Value &)=0
 Assign a new value.

virtual Valuatorstep (const T_Value &)=0
 Set the increment in which the value changes.

virtual Valuatorrange (const T_Value &min_corner, const T_Value &max_corner)=0
 Set the allowable range of values.


Detailed Description

template<typename T_Value>
class esve::components::dimn::Valuator< T_Value >

A user-interface widget representing a given value type.

Keep in mind that modifying the value in code (even implicitly with step() or range()) has a side-effect: it will send a handle_*() message as if the user changed it.

Setting the value within handle() itself is OK; the recursion is detected and consequently ignored.

This side-effect of emitting handle() in response to changing the value may seem surprising at first, but in the end it is the right thing. One should not depend upon the kindness of programmers to manually call update() every time they change something in code.

The facilities of kernel::Caching_Node and kernel::Caching_Server solve the issue of handle() being emitted before an object is fully constructed. As of this writing, all front-ends use Simple_Kernel which caches handle() messages during the startup/construction phase.


Member Function Documentation

template<typename T_Value>
virtual Valuator& esve::components::dimn::Valuator< T_Value >::value const T_Value &   )  [pure virtual]
 

Assign a new value.

Returns:
*this

template<typename T_Value>
virtual Valuator& esve::components::dimn::Valuator< T_Value >::step const T_Value &   )  [pure virtual]
 

Set the increment in which the value changes.

Returns:
*this

template<typename T_Value>
virtual Valuator& esve::components::dimn::Valuator< T_Value >::range const T_Value &  min_corner,
const T_Value &  max_corner
[pure virtual]
 

Set the allowable range of values.

Returns:
*this


Generated on Tue May 30 11:40:55 2006 for esve by doxygen 1.3.4