mirror of
https://github.com/aseprite/aseprite.git
synced 2025-01-05 21:57:20 +00:00
Fix ButtonSet::Item preferred size when UI Scaling > 100% (fix #713)
This commit is contained in:
parent
8572bb8ffc
commit
b547960984
@ -168,13 +168,13 @@ void ButtonSet::Item::onPreferredSize(ui::PreferredSizeEvent& ev)
|
||||
sz.h = 16*guiscale();
|
||||
}
|
||||
else if (!getText().empty())
|
||||
sz += getTextSize() + 8*guiscale();;
|
||||
sz += getTextSize() + 8*guiscale();
|
||||
|
||||
Grid::Info info = buttonSet()->getChildInfo(this);
|
||||
if (info.row == info.grid_rows-1)
|
||||
sz.h += 3*guiscale();
|
||||
|
||||
ev.setPreferredSize(sz*guiscale());
|
||||
ev.setPreferredSize(sz);
|
||||
}
|
||||
|
||||
ButtonSet::ButtonSet(int columns)
|
||||
|
Loading…
Reference in New Issue
Block a user