From 2b7d030551a357272f9cc39e347855bd2e3faba2 Mon Sep 17 00:00:00 2001 From: dec05eba Date: Mon, 7 May 2018 23:00:21 +0200 Subject: Improve text editing, use Text object for chatbar Improve text rendering by not using floating point position --- include/Text.hpp | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'include/Text.hpp') diff --git a/include/Text.hpp b/include/Text.hpp index 0bc3ced..d2809de 100644 --- a/include/Text.hpp +++ b/include/Text.hpp @@ -36,11 +36,17 @@ namespace dchat Text(const sf::String &str, const sf::Font *font, unsigned int characterSize, float maxWidth, bool plainText = true); void setString(const sf::String &str); + const sf::String& getString() const; void setPosition(float x, float y); void setPosition(const sf::Vector2f &position); void setMaxWidth(float maxWidth); + void setCharacterSize(unsigned int characterSize); + unsigned int getCharacterSize() const; + + const sf::Font* getFont() const; + void setFillColor(sf::Color color); void setLineSpacing(float lineSpacing); void setEditable(bool editable); -- cgit v1.2.3