JugiMap Framework
GraphicItem Class Reference

The GraphicItem class defines the equivalent object from JugiMap Editor. More...

#include <jmSourceGraphics.h>

Inherited by GraphicItemAGK.

Public Member Functions

virtual void Init ()
 Initialize this graphic item. More...
 
GraphicFileGetFile ()
 Returns the graphic file of this graphic item. More...
 
std::string GetName ()
 Returns the name of this graphic item. More...
 
Vec2i GetPos ()
 Returns the position of sub-image if this graphic item belong to an image file. More...
 
int GetWidth ()
 Returns the width of sub-image if this graphic item belongs to an image file. More...
 
int GetHeight ()
 Returns the height of sub-image if this graphic item belongs to an image file. More...
 
Vec2i GetSize ()
 Returns the size of sub-image if this graphic item belongs to an image file. More...
 
Vec2f GetHandle ()
 Returns the handle of sub-image if this graphic item belongs to an image file. More...
 
float GetSpineScale ()
 Returns the spine scale if this graphic item belongs to a Spine file. More...
 
std::vector< VectorShape * > & GetSpriteShapes ()
 Returns a reference to sprite shapes if this graphic item belong to an image file. More...
 
std::vector< VectorShape * > & GetExtraShapes ()
 Returns a reference to probe shapes if this graphic item belong to an image file. More...
 
std::string GetLabel ()
 Returns the text if this graphic item belong to text sprite. More...
 
int GetFontStyleId ()
 Returns the font style id if this graphic item belong to text sprite. More...
 
int GetColorStyleId ()
 Returns the color style id if this graphic item belong to text sprite. More...
 
TextHandleVariant GetTextHandleVariant ()
 Returns the text handle variant if this graphic item belong to text sprite. More...
 

Protected Member Functions

 GraphicItem ()
 Constructor. More...
 
virtual ~GraphicItem ()
 Destructor. More...
 

Detailed Description

The GraphicItem class defines the equivalent object from JugiMap Editor.

A graphics item stores parameters related to graphic items (images, texts, skeleton sprites).

Constructor & Destructor Documentation

◆ GraphicItem()

GraphicItem ( )
inlineprotected

Constructor.

◆ ~GraphicItem()

~GraphicItem ( )
protectedvirtual

Destructor.

Member Function Documentation

◆ Init()

void Init ( )
virtual

Initialize this graphic item.

This function is called by SourceSprite::Init and should not be called manually.

Reimplemented in GraphicItemAGK.

◆ GetFile()

GraphicFile* GetFile ( )
inline

Returns the graphic file of this graphic item.

◆ GetName()

std::string GetName ( )
inline

Returns the name of this graphic item.

◆ GetPos()

Vec2i GetPos ( )
inline

Returns the position of sub-image if this graphic item belong to an image file.

◆ GetWidth()

int GetWidth ( )
inline

Returns the width of sub-image if this graphic item belongs to an image file.

◆ GetHeight()

int GetHeight ( )
inline

Returns the height of sub-image if this graphic item belongs to an image file.

◆ GetSize()

Vec2i GetSize ( )
inline

Returns the size of sub-image if this graphic item belongs to an image file.

◆ GetHandle()

Vec2f GetHandle ( )
inline

Returns the handle of sub-image if this graphic item belongs to an image file.

◆ GetSpineScale()

float GetSpineScale ( )
inline

Returns the spine scale if this graphic item belongs to a Spine file.

◆ GetSpriteShapes()

std::vector<VectorShape*>& GetSpriteShapes ( )
inline

Returns a reference to sprite shapes if this graphic item belong to an image file.

◆ GetExtraShapes()

std::vector<VectorShape*>& GetExtraShapes ( )
inline

Returns a reference to probe shapes if this graphic item belong to an image file.

◆ GetLabel()

std::string GetLabel ( )
inline

Returns the text if this graphic item belong to text sprite.

◆ GetFontStyleId()

int GetFontStyleId ( )
inline

Returns the font style id if this graphic item belong to text sprite.

◆ GetColorStyleId()

int GetColorStyleId ( )
inline

Returns the color style id if this graphic item belong to text sprite.

◆ GetTextHandleVariant()

TextHandleVariant GetTextHandleVariant ( )
inline

Returns the text handle variant if this graphic item belong to text sprite.


The documentation for this class was generated from the following files: