Added ability to choose type of text alignment
This commit is contained in:
@@ -40,10 +40,19 @@ protected:
|
||||
// Default - black
|
||||
SDL_Color m_text_color;
|
||||
|
||||
// Whether to H-align via visible pixels or rendering surface
|
||||
// Default - true
|
||||
bool m_halign_via_visible;
|
||||
|
||||
// Whether to V-align via visible pixels or rendering surface
|
||||
// Default - true
|
||||
bool m_valign_via_visible;
|
||||
|
||||
public:
|
||||
WidgetText(int x, int y, int width, int height, std::string text,
|
||||
TextFit fit, bool should_wrap,
|
||||
HorizontalAlign halign, VerticalAlign valign,
|
||||
bool halign_via_visible, bool valign_via_visible,
|
||||
SDL_Color text_color,
|
||||
int size, std::string font = "");
|
||||
|
||||
|
||||
Reference in New Issue
Block a user