Skip to content

Commit

Permalink
Merge pull request #82540 from jackwilsdon/fix-inspector-category-height
Browse files Browse the repository at this point in the history
Use theme icon size when calculating category minimum size
  • Loading branch information
akien-mga committed Sep 30, 2023
2 parents c952751 + 4a33a51 commit eb14308
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion editor/editor_inspector.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1188,7 +1188,8 @@ Size2 EditorInspectorCategory::get_minimum_size() const {
Size2 ms;
ms.height = font->get_height(font_size);
if (icon.is_valid()) {
ms.height = MAX(icon->get_height(), ms.height);
int icon_size = get_theme_constant(SNAME("class_icon_size"), EditorStringName(Editor));
ms.height = MAX(icon_size, ms.height);
}
ms.height += get_theme_constant(SNAME("v_separation"), SNAME("Tree"));

Expand Down

0 comments on commit eb14308

Please sign in to comment.