mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-08 12:31:51 +00:00
add markdown dialect (WIP) & add strikethrough and underline font styles
This commit is contained in:
parent
605d7e7897
commit
80e809f97f
15 changed files with 296 additions and 58 deletions
|
|
@ -53,6 +53,9 @@ namespace gui {
|
|||
/// @brief Auto resize label to fit text
|
||||
bool autoresize = false;
|
||||
|
||||
/// @brief Enable text markdown
|
||||
bool markdown = false;
|
||||
|
||||
std::unique_ptr<FontStylesScheme> styles;
|
||||
public:
|
||||
Label(const std::string& text, std::string fontName="normal");
|
||||
|
|
@ -60,7 +63,7 @@ namespace gui {
|
|||
|
||||
virtual ~Label();
|
||||
|
||||
virtual void setText(const std::wstring& text);
|
||||
virtual void setText(std::wstring text);
|
||||
const std::wstring& getText() const;
|
||||
|
||||
virtual void setFontName(std::string name);
|
||||
|
|
@ -113,6 +116,9 @@ namespace gui {
|
|||
virtual void setTextWrapping(bool flag);
|
||||
virtual bool isTextWrapping() const;
|
||||
|
||||
virtual void setMarkdown(bool flag);
|
||||
virtual bool isMarkdown() const;
|
||||
|
||||
virtual void setStyles(std::unique_ptr<FontStylesScheme> styles);
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue