What we do and don't expose to client toolkits
Alan Griffiths
alan.griffiths at canonical.com
Mon Sep 5 16:21:01 UTC 2016
On 02/09/16 15:44, Alan Griffiths wrote:
> On 02/09/16 15:42, Thomas Voß wrote:
>> This only works in the fullscreen case and I
>> cannot think of a scenario where this impacts overall
>> user experience. The app already is the one "owning" the display in fullscreen.
> Why would you think it only work in the fullscreen case?
there was an IRC conversation to sort this out between myself William
and Thomas.
I think the resulting consensus was:
1. Mir will constrain the placement anchor of the aux_rect to the parent
surface. I don't think we agreed exactly how (e.g. do we "clip" the
rect? What happens if there is *no* intersection?)
2. Mir will constrain the the offset placement anchor to the parent
surface. Again I don't think we agreed how. (Slide it horizontally
and/or vertically the minimum amount?)
3. Mir will provide a new notification of the placement rectangle.
4. Clients can then probe the display boundaries:
E.g.
MirRectangle aux { 0, 0, 0, 0 };
auto const surface_spec = mir_connection_create_spec_for_tip(connection, a_big_width, ...);
mir_surface_spec_set_placement(
surface_spec, &aux,
mir_placement_gravity_northwest, // rect anchor
mir_placement_gravity_northeast, // surface anchor
mir_placement_hints_resize_x,
0,
0);
Will result in a "tip" surface whose width is the distance to the
left hand side of the screen.
5. Clients using the result of such probing may get stupid results. We
don't care.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/mir-devel/attachments/20160905/447d208b/attachment.html>
More information about the Mir-devel
mailing list