summaryrefslogtreecommitdiff
path: root/render
diff options
context:
space:
mode:
Diffstat (limited to 'render')
-rw-r--r--render/layout.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/render/layout.c b/render/layout.c
index e12562b73..5109b8c6a 100644
--- a/render/layout.c
+++ b/render/layout.c
@@ -947,6 +947,8 @@ void layout_float_find_dimensions(int available_width,
if (min_width > 0 && width < min_width) width = min_width;
} else {
+ if (max_width >= 0 && width > max_width) width = max_width;
+ if (min_width > 0 && width < min_width) width = min_width;
width -= scrollbar_width;
}