Untitled Game engine no.5
1.0
|
#include <UI.hpp>
Public Member Functions | |
UIText (const Ref< Engine::Font > &font, const std::string &text, Allignment origin=CENTER) | |
void | setText (const std::string &newString) |
Public Member Functions inherited from Engine::UIElement | |
UIElement (const Ref< Texture > &tex) | |
void | setImage (const Ref< Texture > &tex) |
void | setImage (const Ref< TextureLookup > &lookup) |
void | setSize (float width, float height) |
virtual void | update () |
void | queueVisualUpdate () |
virtual void | updateVisual () |
Public Member Functions inherited from Engine::MeshRenderer | |
void | SetMesh (const Ref< Mesh > &renderMesh) |
void | SetMap (const Ref< Texture > &tex) |
Public Attributes | |
Ref< Font > | font |
std::string | text |
Public Attributes inherited from Engine::UIElement | |
Ref< VertexCollider2D > | collider = nullptr |
Allignment | origin = CENTER |
collider reference (generated when setting a picture) | |
Public Attributes inherited from Engine::MeshRenderer | |
Ref< ColorMap > | colorMap = nullptr |
Ref< TextureMap > | map = nullptr |
Ref< Texture > | texture = nullptr |
std::vector< Ref< Texture > > | vertexTextures = std::vector<Ref<Texture>>() |
Ref< Mesh > | mesh = nullptr |
Additional Inherited Members | |
Static Public Member Functions inherited from Engine::UIElement | |
static void | Update (const Scene &scene) |
Wrapper for a UIElement with text. Stores font/ string data.
|
inline |
Construct a text box from a font reference and a text string.
The alignment passed in will affect the text being rendered. Setting the Image of this UIElement will clear the text data.
font | |
text | |
origin |