mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 14:07:46 +00:00
LibGfx: Make Font::width() return a float
This commit is contained in:
parent
b9d2b8f7b2
commit
3407ab0fd1
25 changed files with 40 additions and 40 deletions
|
@ -79,7 +79,7 @@ void LinkLabel::paint_event(PaintEvent& event)
|
|||
GUI::Painter painter(*this);
|
||||
|
||||
if (m_hovered)
|
||||
painter.draw_line({ 0, rect().bottom() }, { font().width(text()), rect().bottom() }, palette().link());
|
||||
painter.draw_line({ 0, rect().bottom() }, { static_cast<int>(ceilf(font().width(text()))), rect().bottom() }, palette().link());
|
||||
|
||||
if (is_focused())
|
||||
painter.draw_focus_rect(text_rect(), palette().focus_outline());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue