mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-09 21:11:50 +00:00
add FontStylesScheme
This commit is contained in:
parent
b15725913e
commit
ce1e9f76cf
7 changed files with 83 additions and 17 deletions
|
|
@ -3,6 +3,7 @@
|
|||
#include "UINode.hpp"
|
||||
|
||||
class Font;
|
||||
struct FontStylesScheme;
|
||||
|
||||
namespace gui {
|
||||
struct LineScheme {
|
||||
|
|
@ -51,10 +52,14 @@ namespace gui {
|
|||
|
||||
/// @brief Auto resize label to fit text
|
||||
bool autoresize = false;
|
||||
|
||||
std::unique_ptr<FontStylesScheme> styles;
|
||||
public:
|
||||
Label(const std::string& text, std::string fontName="normal");
|
||||
Label(const std::wstring& text, std::string fontName="normal");
|
||||
|
||||
virtual ~Label();
|
||||
|
||||
virtual void setText(const std::wstring& text);
|
||||
const std::wstring& getText() const;
|
||||
|
||||
|
|
@ -107,5 +112,7 @@ namespace gui {
|
|||
|
||||
virtual void setTextWrapping(bool flag);
|
||||
virtual bool isTextWrapping() const;
|
||||
|
||||
virtual void setStyles(std::unique_ptr<FontStylesScheme> styles);
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue