#include <ExpressionBinding.h>
Public Member Functions | |
virtual bool apply () | |
virtual bool apply (const std::string &propName) | |
bool autoApply () const | |
virtual void bind (const App::ObjectIdentifier &_path) | |
virtual void bind (const App::Property &prop) | |
ExpressionBinding () | |
QPixmap getIcon (const char *name, const QSize &size) const | |
bool hasExpression () const | |
bool isBound () const | |
void setAutoApply (bool value) | |
~ExpressionBinding () | |
Protected Member Functions | |
void expressionChange (const App::ObjectIdentifier &id) | |
std::string getEscapedExpressionString () const | |
boost::shared_ptr< App::Expression > getExpression () const | |
std::string getExpressionString (bool no_throw=true) const | |
const App::ObjectIdentifier & getPath () const | |
virtual void onChange () | |
virtual void setExpression (boost::shared_ptr< App::Expression > expr) | |
Protected Attributes | |
boost::signals2::scoped_connection connection | |
QPalette defaultPalette | |
int iconHeight | |
QLabel * iconLabel | |
bool m_autoApply | |
Constructor & Destructor Documentation
◆ ExpressionBinding()
ExpressionBinding::ExpressionBinding | ( | ) |
◆ ~ExpressionBinding()
ExpressionBinding::~ExpressionBinding | ( | ) |
Member Function Documentation
◆ apply() [1/2]
|
virtual |
Reimplemented in Gui::InputField, and Gui::UIntSpinBox.
References Gui::Command::getObjectCmd(), getPath(), App::Property::isReadOnly(), and App::ObjectIdentifier::toEscapedString().
Referenced by Gui::UIntSpinBox::apply(), Gui::IntSpinBox::apply(), Gui::QuantitySpinBox::apply(), Gui::InputField::apply(), Gui::DoubleSpinBox::apply(), Gui::ExpLineEdit::apply(), and Gui::PropertyEditor::VectorLineEdit::apply().
◆ apply() [2/2]
|
virtual |
Reimplemented in Gui::PropertyEditor::VectorLineEdit, Gui::ExpLineEdit, Gui::DoubleSpinBox, Gui::InputField, Gui::QuantitySpinBox, Gui::IntSpinBox, and Gui::UIntSpinBox.
References App::Application::closeActiveTransaction(), Gui::Command::Doc, App::Application::getActiveTransaction(), App::GetApplication(), App::DocumentObject::getDocument(), getEscapedExpressionString(), App::Document::getName(), App::DocumentObject::getNameInDocument(), App::PropertyString::getValue(), hasExpression(), isBound(), App::DocumentObject::Label, and App::Application::setActiveTransaction().
Referenced by Gui::ExpressionBindingPy::apply().
◆ autoApply()
bool Gui::ExpressionBinding::autoApply | ( | ) | const |
Referenced by Gui::ExpressionBindingPy::autoApply().
◆ bind() [1/2]
|
virtual |
Reimplemented in Gui::ExpLineEdit, Gui::DoubleSpinBox, Gui::InputField, Gui::QuantitySpinBox, Gui::IntSpinBox, Gui::PropertyEditor::PropertyItem, and Gui::UIntSpinBox.
References App::Property::canonicalPath(), connection, expressionChange(), App::PropertyExpressionEngine::expressionChanged, App::DocumentObject::ExpressionEngine, and App::ObjectIdentifier::getProperty().
Referenced by bind(), Gui::ExpressionBindingPy::bind(), Gui::UIntSpinBox::bind(), Gui::PropertyEditor::PropertyItem::bind(), Gui::IntSpinBox::bind(), Gui::QuantitySpinBox::bind(), Gui::InputField::bind(), Gui::DoubleSpinBox::bind(), and Gui::ExpLineEdit::bind().
◆ bind() [2/2]
|
virtual |
Reimplemented in Gui::PropertyEditor::PropertyItem.
References bind().
◆ expressionChange()
|
protected |
References onChange().
Referenced by bind().
◆ getEscapedExpressionString()
|
protected |
References Base::Tools::escapedUnicodeFromUtf8(), and getExpressionString().
Referenced by apply().
◆ getExpression()
|
protected |
References App::PropertyExpressionEngine::ExpressionInfo::expression, App::DocumentObject::getExpression(), and isBound().
Referenced by Gui::QuantitySpinBox::event(), Gui::QuantitySpinBox::focusInEvent(), getExpressionString(), hasExpression(), Gui::InputField::newInput(), Gui::UIntSpinBox::onChange(), Gui::QuantitySpinBox::openFormulaDialog(), Gui::UIntSpinBox::resizeEvent(), Gui::IntSpinBox::resizeEvent(), Gui::QuantitySpinBox::resizeEvent(), Gui::DoubleSpinBox::resizeEvent(), and Gui::ExpLineEdit::resizeEvent().
◆ getExpressionString()
|
protected |
References getExpression().
Referenced by getEscapedExpressionString().
◆ getIcon()
QPixmap ExpressionBinding::getIcon | ( | const char * | name, |
const QSize & | size | ||
) | const |
References Gui::BitmapFactory(), DraftVecUtils::find(), and Gui::BitmapFactoryInst::pixmapFromSvg().
Referenced by Gui::DoubleSpinBox::DoubleSpinBox(), Gui::ExpLineEdit::ExpLineEdit(), Gui::IntSpinBox::IntSpinBox(), Gui::UIntSpinBox::onChange(), Gui::QuantitySpinBox::QuantitySpinBox(), Gui::UIntSpinBox::resizeEvent(), Gui::IntSpinBox::resizeEvent(), Gui::QuantitySpinBox::resizeEvent(), Gui::DoubleSpinBox::resizeEvent(), Gui::ExpLineEdit::resizeEvent(), Gui::UIntSpinBox::UIntSpinBox(), ArchAxis.AxisSystemTaskPanel::update(), ArchSectionPlane.SectionPlaneTaskPanel::update(), and ArchComponent.ComponentTaskPanel::update().
◆ getPath()
|
protected |
◆ hasExpression()
bool ExpressionBinding::hasExpression | ( | ) | const |
References getExpression(), and isBound().
Referenced by apply(), Gui::PropertyEditor::PropertyItem::hasAnyExpression(), Gui::ExpressionBindingPy::hasExpression(), Gui::UIntSpinBox::keyPressEvent(), Gui::IntSpinBox::keyPressEvent(), Gui::DoubleSpinBox::keyPressEvent(), Gui::ExpLineEdit::keyPressEvent(), and Gui::PropertyEditor::PropertyPlacementItem::value().
◆ isBound()
bool ExpressionBinding::isBound | ( | ) | const |
Referenced by apply(), Gui::QuantitySpinBox::apply(), Gui::QuantitySpinBox::boundToName(), Gui::QuantitySpinBox::event(), Gui::QuantitySpinBox::focusInEvent(), getExpression(), hasExpression(), Gui::ExpressionBindingPy::isBound(), Gui::UIntSpinBox::keyPressEvent(), Gui::IntSpinBox::keyPressEvent(), Gui::DoubleSpinBox::keyPressEvent(), Gui::InputField::newInput(), Gui::QuantitySpinBox::openFormulaDialog(), Gui::UIntSpinBox::resizeEvent(), Gui::IntSpinBox::resizeEvent(), Gui::QuantitySpinBox::resizeEvent(), Gui::DoubleSpinBox::resizeEvent(), Gui::ExpLineEdit::resizeEvent(), Gui::UIntSpinBox::setExpression(), Gui::IntSpinBox::setExpression(), Gui::DoubleSpinBox::setExpression(), and Gui::ExpLineEdit::setExpression().
◆ onChange()
|
protectedvirtual |
Reimplemented in Gui::PropertyEditor::PropertyItem, and Gui::UIntSpinBox.
Referenced by expressionChange().
◆ setAutoApply()
void Gui::ExpressionBinding::setAutoApply | ( | bool | value | ) |
◆ setExpression()
|
protectedvirtual |
Reimplemented in Gui::ExpLineEdit, Gui::DoubleSpinBox, Gui::QuantitySpinBox, Gui::IntSpinBox, and Gui::UIntSpinBox.
References App::Application::closeActiveTransaction(), App::DocumentObject::ExpressionEngine, App::Application::getActiveTransaction(), App::GetApplication(), App::PropertyString::getValue(), App::DocumentObject::Label, App::Application::setActiveTransaction(), App::PropertyExpressionEngine::setValue(), and App::PropertyExpressionEngine::validateExpression().
Referenced by Gui::InputField::newInput(), Gui::UIntSpinBox::setExpression(), Gui::IntSpinBox::setExpression(), Gui::QuantitySpinBox::setExpression(), Gui::DoubleSpinBox::setExpression(), and Gui::ExpLineEdit::setExpression().
Member Data Documentation
◆ connection
|
protected |
Referenced by bind().
◆ defaultPalette
|
protected |
Referenced by Gui::DoubleSpinBox::DoubleSpinBox(), Gui::ExpLineEdit::ExpLineEdit(), Gui::IntSpinBox::IntSpinBox(), Gui::UIntSpinBox::onChange(), Gui::QuantitySpinBox::QuantitySpinBox(), Gui::UIntSpinBox::resizeEvent(), Gui::IntSpinBox::resizeEvent(), Gui::QuantitySpinBox::resizeEvent(), Gui::DoubleSpinBox::resizeEvent(), Gui::ExpLineEdit::resizeEvent(), and Gui::UIntSpinBox::UIntSpinBox().
◆ iconHeight
|
protected |
Referenced by Gui::DoubleSpinBox::DoubleSpinBox(), Gui::ExpLineEdit::ExpLineEdit(), Gui::IntSpinBox::IntSpinBox(), Gui::QuantitySpinBox::minimumSizeHint(), Gui::UIntSpinBox::onChange(), Gui::QuantitySpinBox::QuantitySpinBox(), Gui::UIntSpinBox::resizeEvent(), Gui::IntSpinBox::resizeEvent(), Gui::QuantitySpinBox::resizeEvent(), Gui::DoubleSpinBox::resizeEvent(), Gui::ExpLineEdit::resizeEvent(), Gui::QuantitySpinBox::sizeHint(), and Gui::UIntSpinBox::UIntSpinBox().
◆ iconLabel
|
protected |
Referenced by Gui::UIntSpinBox::bind(), Gui::IntSpinBox::bind(), Gui::QuantitySpinBox::bind(), Gui::DoubleSpinBox::bind(), Gui::ExpLineEdit::bind(), Gui::DoubleSpinBox::DoubleSpinBox(), Gui::ExpLineEdit::ExpLineEdit(), Gui::InputField::InputField(), Gui::IntSpinBox::IntSpinBox(), Gui::InputField::newInput(), Gui::UIntSpinBox::onChange(), Gui::QuantitySpinBox::QuantitySpinBox(), Gui::UIntSpinBox::resizeEvent(), Gui::IntSpinBox::resizeEvent(), Gui::QuantitySpinBox::resizeEvent(), Gui::DoubleSpinBox::resizeEvent(), Gui::InputField::resizeEvent(), Gui::ExpLineEdit::resizeEvent(), Gui::UIntSpinBox::setExpression(), Gui::IntSpinBox::setExpression(), Gui::DoubleSpinBox::setExpression(), Gui::ExpLineEdit::setExpression(), Gui::UIntSpinBox::UIntSpinBox(), and Gui::InputField::updateIconLabel().
◆ m_autoApply
|
protected |
The documentation for this class was generated from the following files:
- src/Gui/ExpressionBinding.h
- src/Gui/ExpressionBinding.cpp