Userland: Use Font::pixel_size_rounded_up() in more places

This commit is contained in:
Andreas Kling 2023-03-03 19:38:05 +01:00
commit 508fb7e1e9
Notes: sideshowbarker 2024-07-17 01:27:18 +09:00
7 changed files with 10 additions and 10 deletions

View file

@ -280,7 +280,7 @@ Optional<UISize> Button::calculated_min_size() const
if (!text().is_empty()) {
auto& font = this->font();
horizontal = static_cast<int>(ceilf(font.width(text()))) + 2;
vertical = static_cast<int>(ceilf(font.pixel_size())) + 4; // FIXME: Use actual maximum total height
vertical = font.pixel_size_rounded_up() + 4; // FIXME: Use actual maximum total height
}
if (m_icon) {