protocol: prefer wl_surface.damage_buffer

This commit makes wl_surface.damage_buffer preferred over wl_surface.damage.
wl_surface.damage can be implemented in a non-optimal way by the compositor
(e.g. by always damaging the whole buffer).

Having two requests makes it complicated for the compositor to handle damage,
making it necessary to transform one into the other's coordinates.

Moreover, integration with wp_viewporter is tricky.

Signed-off-by: Simon Ser <>
Acked-by: Pekka Paalanen <>
Reviewed-by: Derek Foreman <>
1 job for master in 1 minute and 50 seconds (queued for 2 minutes and 48 seconds)
Status Job ID Name Coverage
passed #54156