Update LineEdit to include read_only StyleBox in get_minimum_size()
Fixes #90522
This commit is contained in:
parent
89850d553e
commit
3337c160a4
|
@ -1805,7 +1805,6 @@ void LineEdit::clear_internal() {
|
|||
}
|
||||
|
||||
Size2 LineEdit::get_minimum_size() const {
|
||||
Ref<StyleBox> style = theme_cache.normal;
|
||||
Ref<Font> font = theme_cache.font;
|
||||
int font_size = theme_cache.font_size;
|
||||
|
||||
|
@ -1834,7 +1833,8 @@ Size2 LineEdit::get_minimum_size() const {
|
|||
}
|
||||
min_size.width += icon_max_width;
|
||||
|
||||
return style->get_minimum_size() + min_size;
|
||||
Size2 style_min_size = theme_cache.normal->get_minimum_size().max(theme_cache.read_only->get_minimum_size());
|
||||
return style_min_size + min_size;
|
||||
}
|
||||
|
||||
void LineEdit::deselect() {
|
||||
|
|
Loading…
Reference in New Issue