mirror of
https://github.com/SerenityOS/serenity.git
synced 2025-01-23 18:02:05 -05:00
LibGfx: Handle TextAlignment::BottomRight in do_draw_text()
This commit is contained in:
parent
9103471863
commit
b1eeb15129
1 changed files with 3 additions and 0 deletions
|
@ -1021,6 +1021,9 @@ void do_draw_text(const IntRect& rect, const TextType& text, const Font& font, T
|
|||
case TextAlignment::Center:
|
||||
bounding_rect.center_within(rect);
|
||||
break;
|
||||
case TextAlignment::BottomRight:
|
||||
bounding_rect.set_location({ (rect.right() + 1) - bounding_rect.width(), (rect.bottom() + 1) - bounding_rect.height() });
|
||||
break;
|
||||
default:
|
||||
ASSERT_NOT_REACHED();
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue