protocol: clarify when wl_surface.enter events are sent

It was unclear what happens when a output global is bound. I believe the
expectation is that all surfaces on that output will receive enter.

Also make it explicit a surface must be mapped, i.e. have both content and role,
to enter an output.

Signed-off-by: Yuxuan Shui <yshuiv7@gmail.com>
This commit is contained in:
Yuxuan Shui 2023-02-06 22:52:59 +00:00
parent 0dc23e380a
commit 58384280d7
No known key found for this signature in database
GPG key ID: D3A4405BE6CC17F4

View file

@ -1635,7 +1635,7 @@
<description summary="surface enters an output">
This is emitted whenever a surface's creation, movement, or resizing
results in some part of it being within the scanout region of an
output.
output. A surface must be mapped before it can enter any outputs.
Note that a surface may be overlapping with zero or more outputs.
</description>
@ -2562,6 +2562,9 @@
actually visible. This typically corresponds to a monitor that
displays part of the compositor space. This object is published
as global during start up, or when a monitor is hotplugged.
When an output global is first bound, wl_surface.enter events should be
sent for all surfaces already on that output.
</description>
<enum name="subpixel">