Hi, If we want this in an initial minimalistic xdg_shell version, this needs to be targetted at xdg_shell unstable v6, which currently lives on a branch and as set of proposed patches. We cannot add this to version 5 anyhow.
If we indeed want this in the core protocol now, and not in some extension, then I'd suggest rebasing it on top of "xdg-shell: Turn xdg_surface into a generic base interface" [0] and adding this request to the xdg_toplevel interface. I'm in the process of sending a updated version of that series, but in general, up to that patch, it should be more or less the same. Jonas [0] https://patchwork.freedesktop.org/patch/72427/ On Tue, Apr 05, 2016 at 11:36:16AM +0200, Olivier Fourdan wrote: > Some application may wish to restrict their window in size, but > xdg-shell has no mechanism for the client to advertise such a maximum > or minimum size the compositor can use. > > As a result, the compositor may try to maximize or fullscreen a window > while the client would not allow for the requested size. > > Add new requests "set_preferred_max_size" and "set_preferred_min_size" > to xdg-shell so that the client can tell the compositor which would be > its preferred smallest/largest acceptable size, so that he compositor > can decide if maximize or fullscreen makes sense, draw an accurate > animation, etc. > > Signed-off-by: Olivier Fourdan <ofour...@redhat.com> > Bugzilla: https://bugzilla.gnome.org/show_bug.cgi?id=764413 > --- > v2: Rename the request to "set_preferred_max_size", > add "set_preferred_min_size" as well > > unstable/xdg-shell/xdg-shell-unstable-v5.xml | 46 > ++++++++++++++++++++++++++++ > 1 file changed, 46 insertions(+) > > diff --git a/unstable/xdg-shell/xdg-shell-unstable-v5.xml > b/unstable/xdg-shell/xdg-shell-unstable-v5.xml > index 542491f..9c9b4d2 100644 > --- a/unstable/xdg-shell/xdg-shell-unstable-v5.xml > +++ b/unstable/xdg-shell/xdg-shell-unstable-v5.xml > @@ -462,6 +462,52 @@ > <arg name="height" type="int"/> > </request> > > + <request name="set_preferred_max_size"> > + <description summary="set the preferred maximum size"> > + Set a preferred maximum size for the surface. > + > + The client can specify a maximum width and/or height to tell the > + compositor what would be the preferred largest size for a surface. > + > + The compositor may use this information from the client to allow > + or disallow different states like maximixe or fullscreen and > + draw accurate animations. > + Similarily, a tiling window manager can use this information to > + place and resize client windows in a more effective layout. > + > + If never set, the size of the surface is not limited by the client. > + > + A value of zero for either width, height or both means that the > + client has no preference regarding the maximum size in the given > + dimension. > + </description> > + <arg name="width" type="int"/> > + <arg name="height" type="int"/> > + </request> > + > + <request name="set_preferred_min_size"> > + <description summary="set the preferred minimum size"> > + Set a preferred minimum size for the surface. > + > + The client can specify a minimum width and/or height to tell the > + compositor what would be the preferable smallest size of a surface. > + > + The compositor may use this information from the client to allow > + or disallow different states like maximixe or fullscreen and > + draw accurate animations. > + Similarily, a tiling window manager can use this information to > + place and resize client windows in a more effective layout. > + > + If never set, the size of the surface is not limited by the client. > + > + A value of zero for either width, height or both means that the > + client has no preference regarding the minimum size in the given > + dimension. > + </description> > + <arg name="width" type="int"/> > + <arg name="height" type="int"/> > + </request> > + > <request name="set_maximized"> > <description summary="maximize the window"> > Maximize the surface. > -- > 2.5.5 > > _______________________________________________ > wayland-devel mailing list > wayland-devel@lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/wayland-devel _______________________________________________ wayland-devel mailing list wayland-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/wayland-devel