#include <imguiicon.h>
Public Member Functions | |
Icon (nap::IMGuiService &guiService) | |
Icon (nap::IMGuiService &guiService, const std::string &imagePath) | |
virtual bool | init (utility::ErrorState &error) |
const std::string & | getPath () const |
const std::string & | getName () const |
const nap::Texture2D & | getTexture () const |
IMGuiService & | getGuiService () |
ImTextureID | getTextureHandle () const |
![]() | |
Resource () | |
![]() | |
Object () | |
virtual | ~Object () |
virtual void | onDestroy () |
Object (Object &)=delete | |
Object & | operator= (const Object &)=delete |
Object (Object &&)=delete | |
Object & | operator= (Object &&)=delete |
Public Attributes | |
bool | mInvert = false |
Property: 'Invert' if the icon colors should be inverted. More... | |
std::string | mImagePath |
Property: 'ImagePath' path to the image on disk. More... | |
![]() | |
std::string | mID |
Property: 'mID' unique name of the object. Used as an identifier by the system. More... | |
Additional Inherited Members | |
![]() | |
static bool | isIDProperty (rtti::Instance &object, const rtti::Property &property) |
Generic icon that can be displayed in a GUI.
Icon | ( | nap::IMGuiService & | guiService | ) |
Creates the icon.
guiService | gui reference |
Icon | ( | nap::IMGuiService & | guiService, |
const std::string & | imagePath | ||
) |
Creates the icon.
guiService | gui reference |
imagePath | path, absolute or relative, to icon |
IMGuiService& getGuiService | ( | ) |
const std::string& getName | ( | ) | const |
const std::string& getPath | ( | ) | const |
const nap::Texture2D& getTexture | ( | ) | const |
ImTextureID getTextureHandle | ( | ) | const |
Returns the GUI texture handle of this icon.
|
virtual |
std::string mImagePath |
Property: 'ImagePath' path to the image on disk.
bool mInvert = false |
Property: 'Invert' if the icon colors should be inverted.