compositor: Remove a plane from the compositor list when releasing it

Weston would crash when hot plugging/unplugging outputs using the DRM
backend due to a corrupted plane list.

https://bugs.freedesktop.org/show_bug.cgi?id=66530
https://bugs.freedesktop.org/show_bug.cgi?id=66529
desktop-shell: Adapt to the new config parser API

This lets the code for adding panel launchers and setting up the
background to be moved into panel_* and background_* functions.

Note that this changes the behavior of the default launcher. Before
this change a default launcher would be added only if there was no
config file. Now a launcher is also added if there is no valid
launcher section.
desktop-shell: Don't crash on output hotplug

The panel and background were never created for hotplugged outputs and
since some parts of the code assume that they always exist that would
lead to desktop-shell client to crash in that case.

This was easier to spot when the display was locked, because Weston
respawns the shell client and the user might not notice since there is
no flicker.

https://bugs.freedesktop.org/show_bug.cgi?id=66531
compositor: rebuild the global list if we've removed a surface from it

The list of surfaces used by weston_compositor_pick_surface() is
maintained in list of surfaces stored on the compositor. This list is
generated from the surfaces across all the layers using
weston_compositor_build_surface_list.

When destroying a surface the surface is "unmapped" with
weston_surface_unmap which removes it from the layer list. However since
the compositor surface list was only being rebuilt when the output was
repainted a call to weston_compositor_pick_surface before the next
output repaint would use an outdated surface list containing surfaces
that have been partially destroyed.

https://bugs.freedesktop.org/show_bug.cgi?id=65986
https://bugs.freedesktop.org/show_bug.cgi?id=66173
https://bugs.freedesktop.org/show_bug.cgi?id=66198
weston-launch: Set all groups for user

Signed-off-by: Quentin Glidic <sardemff7+git@sardemff7.net>

https://bugs.freedesktop.org/show_bug.cgi?id=65933
weston-launch: Fix an error message typo
tests: Add .weston extension to clients tests

We can then add tests which do not use Weston in the test suite.

Signed-off-by: Quentin Glidic <sardemff7+git@sardemff7.net>
Fix compilation with FreeRDP master

context_size has been renamed to ContextSize, this patch fixes it
Document RDP compositor options

Help was missing for the RDP compositor, this patch gives details
about available options.
input: check if the resource is valid in seat_get_pointer

seat->pointer->focus->resource can be NULL, if the surface was
created with weston_surface_create.
compositor: Eliminate marshalling warning for leave events

Don't NULL the resource pointer before calling weston_surface_destroy().
We use to have more of a distinction between compositor created surfaces
and client surfaces, and weston_surface_destroy couldn't be used for
client surfaces.  Now it all goes through weston_surface_destroy() and
we can remove the assert and the NULL-ing of resource, which caused the
marshalling warning.
weston-launch: Fix the typo for real this time

Thanks to MonkeyofDoom for point this out.  I'm still adjusting to the
fact that there's no 'd' in privilege, but I'll get over it.
xwayland: Don't allow resizing to 0x0 or less

X windows have to be at least 1x1 pixels.

https://bugs.freedesktop.org/show_bug.cgi?id=63510
input: Remove wl_seat global when a seat is destroyed

The input code was relying on compositor destruction to clean up the
global, but that doesn't work when the global comes and goes dynamically.

https://bugs.freedesktop.org/show_bug.cgi?id=65913
Use the average width of ASCII glyphs for cell width

As some CJK fonts are dual-width, calculate the average width of ASCII
glyphs and use that instead of the max_x_advance of the font.  This is
what VTE does too.

https://bugs.freedesktop.org/show_bug.cgi?id=63796
tests: Move config-parser.test to tests/

Signed-off-by: Quentin Glidic <sardemff7+git@sardemff7.net>
tests: Fix warnings in config-parser-test
Convert to wl_global_create/destroy()
tablet-shell: Fix copy and paste error in unlock handler

The signal handler was using the wrong member to find the containing
structure of the unlock listener.

https://bugs.freedesktop.org/show_bug.cgi?id=57637
tablet-shell: Avoid infinite loop when unlocking

weston_compositor_wake will fire the signal that the unlock handler is
setup as the listener for. Instead lets change the state to HOME which
unlocks.