diff options
author | Jaakko Keränen <jaakko.keranen@iki.fi> | 2021-05-18 08:53:44 +0300 |
---|---|---|
committer | Jaakko Keränen <jaakko.keranen@iki.fi> | 2021-05-18 15:01:13 +0300 |
commit | 4530faec76c12f5fcf337f3786c1819f94bcd7b9 (patch) | |
tree | e6ecf36c1c2e63dc73932dc8d3807eedde5f1898 | |
parent | 8026b29755cde294ed1db34dd254bba4d0d0b381 (diff) |
LabelWidget: Respect `noAutoMinHeight`
-rw-r--r-- | src/ui/labelwidget.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/ui/labelwidget.c b/src/ui/labelwidget.c index 44ed795b..7ee7bfc8 100644 --- a/src/ui/labelwidget.c +++ b/src/ui/labelwidget.c | |||
@@ -404,7 +404,9 @@ void updateSize_LabelWidget(iLabelWidget *d) { | |||
404 | iWidget *w = as_Widget(d); | 404 | iWidget *w = as_Widget(d); |
405 | const int64_t flags = flags_Widget(w); | 405 | const int64_t flags = flags_Widget(w); |
406 | const iInt2 size = defaultSize_LabelWidget(d); | 406 | const iInt2 size = defaultSize_LabelWidget(d); |
407 | w->minSize.y = size.y; /* vertically text must remain visible */ | 407 | if (!d->flags.noAutoMinHeight) { |
408 | w->minSize.y = size.y; /* vertically text must remain visible */ | ||
409 | } | ||
408 | /* Wrapped text implies that width must be defined by arrangement. */ | 410 | /* Wrapped text implies that width must be defined by arrangement. */ |
409 | if (!(flags & (fixedWidth_WidgetFlag | wrapText_WidgetFlag))) { | 411 | if (!(flags & (fixedWidth_WidgetFlag | wrapText_WidgetFlag))) { |
410 | w->rect.size.x = size.x; | 412 | w->rect.size.x = size.x; |