aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2021-01-28 20:40:10 +0100
committerDavid Robillard <d@drobilla.net>2021-01-28 20:41:03 +0100
commit2d3100e47eee6a8bf2209ee19157de6d23dd1c55 (patch)
treea00a2e953ae7ca9cb2e644c896f686297132246e /src
parente8ba62386cf95be7146564bed98646d6c5ae3cd2 (diff)
downloadpugl-2d3100e47eee6a8bf2209ee19157de6d23dd1c55.tar.gz
pugl-2d3100e47eee6a8bf2209ee19157de6d23dd1c55.tar.bz2
pugl-2d3100e47eee6a8bf2209ee19157de6d23dd1c55.zip
Fix size hints on X11
Diffstat (limited to 'src')
-rw-r--r--src/x11.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/x11.c b/src/x11.c
index 40a79f8..9b688bb 100644
--- a/src/x11.c
+++ b/src/x11.c
@@ -216,20 +216,23 @@ updateSizeHints(const PuglView* view)
sizeHints.max_height = (int)view->frame.height;
} else {
if (view->defaultWidth || view->defaultHeight) {
- sizeHints.flags = PBaseSize;
+ sizeHints.flags |= PBaseSize;
sizeHints.base_width = view->defaultWidth;
sizeHints.base_height = view->defaultHeight;
}
+
if (view->minWidth || view->minHeight) {
- sizeHints.flags = PMinSize;
+ sizeHints.flags |= PMinSize;
sizeHints.min_width = view->minWidth;
sizeHints.min_height = view->minHeight;
}
+
if (view->maxWidth || view->maxHeight) {
- sizeHints.flags = PMaxSize;
+ sizeHints.flags |= PMaxSize;
sizeHints.max_width = view->maxWidth;
sizeHints.max_height = view->maxHeight;
}
+
if (view->minAspectX) {
sizeHints.flags |= PAspect;
sizeHints.min_aspect.x = view->minAspectX;