Add TextStyleInterface.hpp -> Will be inherited by all text-drawing widgets, to apply style cohesively. Other StyleInterface classes are being devised.
This commit is contained in:
20
include/JUI/Mixins/TextStyleInterface.hpp
Normal file
20
include/JUI/Mixins/TextStyleInterface.hpp
Normal file
@@ -0,0 +1,20 @@
|
||||
#pragma once
|
||||
|
||||
namespace JUI {
|
||||
// TODO: Observe and design all the base interfaces for various style categories.
|
||||
|
||||
/// Defines interface for widgets with textual elements which are to be styled as a group.
|
||||
class TextStyleInterface {
|
||||
public:
|
||||
virtual ~TextStyleInterface() = default;
|
||||
|
||||
virtual JGL::Font Font() const = 0;
|
||||
virtual int TextSize() const = 0;
|
||||
virtual Color4 TextColor() const = 0;
|
||||
virtual bool WordWrap() const = 0;
|
||||
|
||||
virtual void Font(const JGL::Font& value) = 0;
|
||||
virtual void TextSize(int value) = 0;
|
||||
virtual void TextColor(const Color4& color) = 0;
|
||||
};
|
||||
}
|
Reference in New Issue
Block a user