Skip to content

Complete handling of creation of narrow windows.

ManoloFLTK requested to merge ManoloFLTK/libdecor:narrow-cairo into master

This MR makes the cairo libdecor plugin properly handle situations where a small max window width is set by the window creator. The plugin has to enforce a max window width at least as big as the minimum window width supported by the plugin.

Test situation: a libdecor user asks for creation of a narrow cairo-decorated window with also a narrow maximum width.

Expected result: the decorated window is created wider than asked to obey the plugin-enforced minimum decorated window width.

Result with unpatched cairo plugin: the window is not created and the program stops with Caught error (1): minimum size (128,56) must be smaller than maximum size (15,0)

Here is, attached, a modified version of libdecor's demo program that creates the test situation and shows the fix solves the problem : demo-mod-narrow.c

Edited by ManoloFLTK

Merge request reports