Go to the documentation of this file.
29 #ifndef FLOAT_PROPERTY_H
30 #define FLOAT_PROPERTY_H
46 template <
typename Func,
typename R>
49 const QString& description,
55 connect(receiver, std::forward<Func>(changed_slot));
59 template <
typename Func,
typename P>
62 const QString& description,
67 connect(parent, std::forward<Func>(changed_slot));
77 bool setValue(
const QVariant& new_value)
override;
121 #endif // FLOAT_PROPERTY_H
bool setValue(const QVariant &new_value) override
Set the new value for this property. Returns true if the new value is different from the old value,...
bool add(float delta)
Add the given delta to the property value.
virtual QVariant getValue() const
Return the value of this Property as a QVariant. If the value has never been set, an invalid QVariant...
QMetaObject::Connection connect(const QObject *receiver, const char *slot, Qt::ConnectionType type=Qt::AutoConnection)
Connect changed() signal to given slot of receiver.
Property specialized to enforce floating point max/min.
A single element of a property tree, with a name, value, description, and possibly children.
FloatProperty(const QString &name, float default_value, const QString &description, Property *parent, Func &&changed_slot, const R *receiver)
virtual float getFloat() const
FloatProperty(const QString &name=QString(), float default_value=0, const QString &description=QString(), Property *parent=nullptr)
bool setFloat(float new_value)
Float-typed "SLOT" version of setValue().
FloatProperty(const QString &name, float default_value, const QString &description, P *parent, Func &&changed_slot)
bool multiply(float factor)
Multiply the property value by the given factor.
rviz
Author(s): Dave Hershberger, David Gossow, Josh Faust, William Woodall
autogenerated on Fri Dec 13 2024 03:31:02