diff --git a/examples/cairo-buffer.c b/examples/cairo-buffer.c index 7de4a053b..63bfad579 100644 --- a/examples/cairo-buffer.c +++ b/examples/cairo-buffer.c @@ -1,3 +1,7 @@ +/* Simple scene-graph example with a custom buffer drawn by Cairo. + * + * Input is unimplemented. Surfaces are unimplemented. + */ #include #include @@ -13,10 +17,6 @@ #include #include -/* Simple scene-graph example with a custom buffer drawn by Cairo. - * - * Input is unimplemented. Surfaces are unimplemented. */ - struct cairo_buffer { struct wlr_buffer base; cairo_surface_t *surface; diff --git a/examples/embedded.c b/examples/embedded.c index f0f661198..8e412fa5b 100644 --- a/examples/embedded.c +++ b/examples/embedded.c @@ -1,3 +1,9 @@ +/* Embed a minimal xdg-shell compositor backed by a scene-graph into a + * wl_subsurface displayed inside a parent Wayland compositor. + * + * Input is unimplemented. + */ + #include #include #include diff --git a/examples/fullscreen-shell.c b/examples/fullscreen-shell.c index 956d851af..10699f221 100644 --- a/examples/fullscreen-shell.c +++ b/examples/fullscreen-shell.c @@ -1,3 +1,7 @@ +/* + * A minimal fullscreen-shell server. It only supports rendering. + */ + #include #include #include @@ -16,10 +20,6 @@ #include #include -/** - * A minimal fullscreen-shell server. It only supports rendering. - */ - struct fullscreen_server { struct wl_display *wl_display; struct wlr_backend *backend; diff --git a/examples/output-layers.c b/examples/output-layers.c index 0535ff0b1..369c7060a 100644 --- a/examples/output-layers.c +++ b/examples/output-layers.c @@ -1,3 +1,11 @@ +/* Simple compositor making use of the output layers API. The compositor will + * attempt to display client surfaces with output layers. Input is + * unimplemented. + * + * New surfaces are stacked on top of the existing ones as they appear. + * Surfaces that don't make it into an output layer are rendered as usual. + */ + #include #include #include @@ -16,13 +24,6 @@ #include #include -/* Simple compositor making use of the output layers API. The compositor will - * attempt to display client surfaces with output layers. Input is - * unimplemented. - * - * New surfaces are stacked on top of the existing ones as they appear. - * Surfaces that don't make it into an output layer are rendered as usual. */ - struct server { struct wl_display *wl_display; struct wlr_backend *backend; diff --git a/examples/output-layout.c b/examples/output-layout.c index c481ddf80..14593a18c 100644 --- a/examples/output-layout.c +++ b/examples/output-layout.c @@ -1,3 +1,8 @@ +/* Bounces a cat picture inside an output layout. + * + * Arrow keys nudge the cat in a direction. + */ + #include #include #include diff --git a/examples/pointer.c b/examples/pointer.c index f3ef5435e..d157a0369 100644 --- a/examples/pointer.c +++ b/examples/pointer.c @@ -1,3 +1,10 @@ +/* Paints a cursor and moves it based on pointer, touch and tablet events. + * + * Left, middle and right pointer buttons change the background color to blue, + * green and red respectively. Axis pointer events change the brightness of the + * background color. + */ + #include #include #include diff --git a/examples/rotation.c b/examples/rotation.c index 18bfbd38d..c562c75fa 100644 --- a/examples/rotation.c +++ b/examples/rotation.c @@ -1,3 +1,10 @@ +/* Scrolls across a mosaic of cats. + * + * Arrow keys change the scroll direction. + * + * The -r CLI option sets the output transform. + */ + #include #include #include diff --git a/examples/scene-graph.c b/examples/scene-graph.c index 421986534..91a945013 100644 --- a/examples/scene-graph.c +++ b/examples/scene-graph.c @@ -1,3 +1,8 @@ +/* Simple compositor making use of the scene-graph API. Input is unimplemented. + * + * New surfaces are stacked on top of the existing ones as they appear. + */ + #include #include #include @@ -15,10 +20,6 @@ #include #include -/* Simple compositor making use of the scene-graph API. Input is unimplemented. - * - * New surfaces are stacked on top of the existing ones as they appear. */ - static const int border_width = 3; struct server { diff --git a/examples/simple.c b/examples/simple.c index d16708654..896265dff 100644 --- a/examples/simple.c +++ b/examples/simple.c @@ -1,3 +1,5 @@ +/* Animates the background color. */ + #include #include #include