[CTL] Add missing font outline drawing routines and theme constants.
This commit is contained in:
parent
b21f854b7f
commit
d78336c65e
33 changed files with 312 additions and 24 deletions
|
|
@ -191,9 +191,17 @@ void LinkButton::_notification(int p_what) {
|
|||
|
||||
int width = text_buf->get_line_width();
|
||||
|
||||
Color font_outline_color = get_theme_color("font_outline_color");
|
||||
int outline_size = get_theme_constant("outline_size");
|
||||
if (is_layout_rtl()) {
|
||||
if (outline_size > 0 && font_outline_color.a > 0) {
|
||||
text_buf->draw_outline(get_canvas_item(), Vector2(size.width - width, 0), outline_size, font_outline_color);
|
||||
}
|
||||
text_buf->draw(get_canvas_item(), Vector2(size.width - width, 0), color);
|
||||
} else {
|
||||
if (outline_size > 0 && font_outline_color.a > 0) {
|
||||
text_buf->draw_outline(get_canvas_item(), Vector2(0, 0), outline_size, font_outline_color);
|
||||
}
|
||||
text_buf->draw(get_canvas_item(), Vector2(0, 0), color);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue