52 const std::string &
label,
66 virtual const char *
widgetClass()
const {
return "YIntField"; }
74 virtual int value() = 0;
128 std::string
label()
const;
136 virtual void setLabel(
const std::string & label );
148 virtual bool setProperty(
const std::string & propertyName,
195 #endif // YIntField_h
virtual void setValueInternal(int val)=0
Set the current value (the number entered by the user or set from the outside) of this IntField...
YIntField(YWidget *parent, const std::string &label, int minValue, int maxValue)
Constructor.
Transport class for the value of simple properties.
virtual const YPropertySet & propertySet()
Return this class's property set.
A set of properties to check names and types against.
virtual void setShortcutString(const std::string &str)
Set the string of this widget that holds the keyboard shortcut.
int maxValue() const
Return the maximum value.
void setMaxValue(int val)
Set a new maximum value.
virtual const char * widgetClass() const
Return a descriptive name of this widget class for logging, debugging etc.
virtual void setLabel(const std::string &label)
Set the label (the caption above the input field).
virtual ~YIntField()
Destructor.
virtual bool setProperty(const std::string &propertyName, const YPropertyValue &val)
Set a property.
int minValue() const
Return the minimum value.
const char * userInputProperty()
The name of the widget property that will return user input.
virtual YPropertyValue getProperty(const std::string &propertyName)
Get a property.
virtual int value()=0
Get the current value (the number entered by the user or set from the outside) of this IntField...
IntField: Input field for integer values.
virtual std::string shortcutString() const
Get the string of this widget that holds the keyboard shortcut.
void setMinValue(int val)
Set a new minimum value.
int enforceRange(int val) const
Enforce 'val' to be between minValue and maxValue.
void setValue(int val)
Set the current value (the number entered by the user or set from the outside) of this IntField...
std::string label() const
Get the label (the caption above the input field).