mirror of
https://github.com/godotengine/godot.git
synced 2025-01-22 18:43:29 -05:00
Merge pull request #95511 from bruvzg/btn_oversampling_reshape
Reshape and update button on oversampling change.
This commit is contained in:
commit
8f79640dc3
1 changed files with 7 additions and 0 deletions
|
@ -210,6 +210,13 @@ void Button::_notification(int p_what) {
|
|||
} break;
|
||||
|
||||
case NOTIFICATION_DRAW: {
|
||||
// Reshape and update size min. if text is invalidated by an external source (e.g., oversampling).
|
||||
if (text_buf.is_valid() && !TS->shaped_text_is_ready(text_buf->get_rid())) {
|
||||
_shape();
|
||||
|
||||
update_minimum_size();
|
||||
}
|
||||
|
||||
const RID ci = get_canvas_item();
|
||||
const Size2 size = get_size();
|
||||
|
||||
|
|
Loading…
Reference in a new issue