|
Krita Source Code Documentation
|
#include <kis_base_node.h>
Public Member Functions | |
| bool | operator== (const Property &rhs) const |
| Property () | |
| Property (const KoID &n, const QIcon &on, const QIcon &off, bool isOn) | |
| Constructor for a mutable property. | |
| Property (const KoID &n, const QIcon &on, const QIcon &off, bool isOn, bool _isInStasis, bool _stateInStasis=false) | |
| Property (const KoID &n, const QString &s) | |
| Constructor for a nonmutable property. | |
Public Attributes | |
| bool | canHaveStasis {false} |
| QString | id |
| bool | isInStasis {false} |
| bool | isMutable {false} |
| QString | name |
| QIcon | offIcon |
| QIcon | onIcon |
| QVariant | state |
| bool | stateInStasis {false} |
Describes a property of a document section.
FIXME: using a QList instead of QMap and not having an untranslated identifier, either enum or string, forces applications to rely on the order of properties or to compare the translated strings. This makes it hard to robustly extend the properties of document section items.
Definition at line 51 of file kis_base_node.h.
|
inline |
Definition at line 84 of file kis_base_node.h.
|
inline |
|
inline |
|
inline |
Constructor for a nonmutable property.
Definition at line 98 of file kis_base_node.h.
|
inline |
Definition at line 80 of file kis_base_node.h.
References isInStasis, name, and state.
| bool KisBaseNode::Property::canHaveStasis {false} |
If the property is mutable, specifies whether it can be put into stasis. When a property is in stasis, a new state is created, and the old one is stored in stateInStasis. When stasis ends, the old value is restored and the new one discarded
Definition at line 71 of file kis_base_node.h.
| QString KisBaseNode::Property::id |
Definition at line 53 of file kis_base_node.h.
| bool KisBaseNode::Property::isInStasis {false} |
If the property isMutable and canHaveStasis, indicate whether it is in stasis or not
Definition at line 74 of file kis_base_node.h.
| bool KisBaseNode::Property::isMutable {false} |
Whether the property is a boolean (e.g. locked, visible) which can be toggled directly from the widget itself.
Definition at line 59 of file kis_base_node.h.
| QString KisBaseNode::Property::name |
i18n-ed name, suitable for displaying
Definition at line 56 of file kis_base_node.h.
| QIcon KisBaseNode::Property::offIcon |
Definition at line 63 of file kis_base_node.h.
| QIcon KisBaseNode::Property::onIcon |
Provide these if the property isMutable.
Definition at line 62 of file kis_base_node.h.
| QVariant KisBaseNode::Property::state |
If the property isMutable, provide a boolean. Otherwise, a string suitable for displaying.
Definition at line 66 of file kis_base_node.h.
| bool KisBaseNode::Property::stateInStasis {false} |
If the property isMutable and canHaveStasis, provide this value to store the property's state while in stasis
Definition at line 78 of file kis_base_node.h.