SMTK
@SMTK_VERSION@
Simulation Modeling Tool Kit
|
A badge that illustrates the type and set the color of a persistent object. More...
#include <TypeAndColorBadge.h>
Public Types | |
using | DescriptivePhrase = smtk::view::DescriptivePhrase |
using | BadgeAction = smtk::view::BadgeAction |
Public Member Functions | |
smtkTypeMacro (smtk::extension::qt::TypeAndColorBadge) | |
smtkSuperclassMacro (smtk::view::ObjectIconBadge) | |
TypeAndColorBadge (smtk::view::BadgeSet &, const smtk::view::Configuration::Component &) | |
bool | action (const DescriptivePhrase *phrase, const BadgeAction &act) override |
Take an action when the badge is clicked. More... | |
![]() | |
smtkTypeMacro (smtk::view::ObjectIconBadge) | |
ObjectIconBadge (BadgeSet &, const Configuration::Component &) | |
bool | appliesToPhrase (const DescriptivePhrase *phrase) const override |
This badge only applies to phrases with a persistent object that has an icon. | |
std::string | tooltip (const DescriptivePhrase *phrase) const override |
The tool-tip string is the object's type. | |
std::string | icon (const DescriptivePhrase *phrase, const std::array< float, 4 > &background) const override |
Returns an SVG string for rendering the badge icon. More... | |
![]() | |
smtkTypeMacroBase (Badge) | |
Badge (const Badge &)=delete | |
Badge & | operator= (const Badge &)=delete |
bool | isDefault () const |
Return whether this badge be invoked by non-specific user gestures. More... | |
void | setIsDefault (bool isDefault) |
Set this badge as a default. | |
Additional Inherited Members | |
![]() | |
const BadgeSet * | m_parent { nullptr } |
![]() | |
bool | m_isDefault { false } |
Should this badge be invoked by non-specific user gestures when it is applicable? | |
A badge that illustrates the type and set the color of a persistent object.
|
overridevirtual |
Take an action when the badge is clicked.
Return true if the action is supported (and was taken) by the badge for the given phrase; otherwise return false.
Reimplemented from smtk::view::Badge.