mirror of
https://github.com/Maschell/libgui-sdl.git
synced 2025-02-21 10:32:03 +01:00
Add getText to GuiText
This commit is contained in:
parent
b686ad53f8
commit
c726432a07
@ -61,6 +61,8 @@ public:
|
||||
|
||||
void setColor(SDL_Color c);
|
||||
|
||||
[[nodiscard]] const std::string getText() const;
|
||||
|
||||
protected:
|
||||
GuiImage texture;
|
||||
GuiTextureData *textureData = nullptr;
|
||||
|
@ -54,6 +54,10 @@ void GuiText::setColor(SDL_Color c) {
|
||||
this->color = c;
|
||||
}
|
||||
|
||||
const std::string GuiText::getText() const {
|
||||
return this->text;
|
||||
}
|
||||
|
||||
void GuiText::setFontSize(int32_t size) {
|
||||
this->fc_font = this->gFont->getFont(size);
|
||||
updateSize();
|
||||
|
Loading…
x
Reference in New Issue
Block a user