// SPDX-License-Identifier: GPL-2.0-only
#define _POSIX_C_SOURCE 200809L
+#include "action.h"
#include <assert.h>
#include <signal.h>
#include <string.h>
#include <strings.h>
#include <unistd.h>
#include <wlr/util/log.h>
-#include "action.h"
#include "common/macros.h"
#include "common/list.h"
#include "common/mem.h"
* SOFTWARE.
*/
+#include "buffer.h"
#include <assert.h>
#include <stdlib.h>
#include <drm_fourcc.h>
#include <wlr/interfaces/wlr_buffer.h>
#include <wlr/util/log.h>
-#include "buffer.h"
#include "common/box.h"
#include "common/mem.h"
// SPDX-License-Identifier: GPL-2.0-only
-#include <assert.h>
#include "common/box.h"
+#include <assert.h>
#include "common/macros.h"
bool
// SPDX-License-Identifier: GPL-2.0-only
+#include "common/buf.h"
#include <assert.h>
#include <ctype.h>
#include <stdarg.h>
#include <stdbool.h>
#include <stdio.h>
#include <string.h>
-#include "common/buf.h"
#include "common/macros.h"
#include "common/mem.h"
#include "common/string-helpers.h"
*
* Copyright Johan Malm 2020
*/
+#include "common/dir.h"
#include <assert.h>
#include <glib.h>
#include <stdbool.h>
#include <stdio.h>
#include <stdlib.h>
#include <sys/stat.h>
-#include "common/dir.h"
#include "common/buf.h"
#include "common/list.h"
#include "common/mem.h"
// SPDX-License-Identifier: GPL-2.0-only
+#include "common/direction.h"
#include <assert.h>
#include <wlr/types/wlr_output_layout.h>
-#include "common/direction.h"
#include "view.h"
enum wlr_direction
// SPDX-License-Identifier: GPL-2.0-only
#define _POSIX_C_SOURCE 200809L
+#include "common/fd-util.h"
#include <sys/resource.h>
#include <wlr/util/log.h>
-#include "common/fd-util.h"
-
static struct rlimit original_nofile_rlimit = {0};
void
// SPDX-License-Identifier: GPL-2.0-only
-#include <sys/stat.h>
#include "common/file-helpers.h"
+#include <sys/stat.h>
bool
file_exists(const char *filename)
// SPDX-License-Identifier: GPL-2.0-only
+#include "common/font.h"
#include <cairo.h>
#include <drm_fourcc.h>
#include <pango/pangocairo.h>
#include <wlr/render/wlr_renderer.h>
#include <wlr/util/box.h>
#include <wlr/util/log.h>
-#include "common/font.h"
#include "common/graphic-helpers.h"
#include "common/string-helpers.h"
#include "labwc.h"
// SPDX-License-Identifier: GPL-2.0-only
+#include "common/graphic-helpers.h"
#include <cairo.h>
#include <glib.h> /* g_ascii_strcasecmp */
#include <wlr/types/wlr_scene.h>
-#include "common/graphic-helpers.h"
#include "common/macros.h"
#include "xcolor-table.h"
// SPDX-License-Identifier: GPL-2.0-only
+#include "common/lab-scene-rect.h"
#include <assert.h>
#include <wlr/types/wlr_scene.h>
-#include "common/lab-scene-rect.h"
#include "common/mem.h"
struct border_scene {
// SPDX-License-Identifier: GPL-2.0-only
-#include <fnmatch.h>
#include "common/match.h"
+#include <fnmatch.h>
bool
match_glob(const char *pattern, const char *string)
// SPDX-License-Identifier: GPL-2.0-only
#define _POSIX_C_SOURCE 200809L
+#include "common/mem.h"
#include <assert.h>
#include <stdio.h>
#include <string.h>
-#include "common/mem.h"
static void
die_if_null(void *ptr)
// SPDX-License-Identifier: GPL-2.0-only
+#include "common/nodename.h"
#include <ctype.h>
#include <string.h>
-#include "common/nodename.h"
char *
nodename(xmlNode *node, char *buf, int len)
// SPDX-License-Identifier: GPL-2.0-only
+#include "common/parse-bool.h"
#include <strings.h>
#include <wlr/util/log.h>
-#include "common/parse-bool.h"
enum three_state
parse_three_state(const char *str)
// SPDX-License-Identifier: GPL-2.0-only
+#include "common/parse-double.h"
#include <locale.h>
#include <stdlib.h>
#include <string.h>
#include <wlr/util/log.h>
#include "common/mem.h"
-#include "common/parse-double.h"
struct dec_separator {
int index;
// SPDX-License-Identifier: GPL-2.0-only
#define _POSIX_C_SOURCE 200809L
+#include "common/scaled-font-buffer.h"
#include <assert.h>
#include <stdlib.h>
#include <string.h>
#include "common/graphic-helpers.h"
#include "common/mem.h"
#include "common/scaled-scene-buffer.h"
-#include "common/scaled-font-buffer.h"
#include "common/string-helpers.h"
static struct lab_data_buffer *
// SPDX-License-Identifier: GPL-2.0-only
#define _POSIX_C_SOURCE 200809L
+#include "common/scaled-icon-buffer.h"
#include <assert.h>
#include <string.h>
#include <wlr/util/log.h>
#include "buffer.h"
#include "common/macros.h"
#include "common/mem.h"
-#include "common/scaled-icon-buffer.h"
#include "common/scaled-scene-buffer.h"
#include "common/string-helpers.h"
#include "config.h"
// SPDX-License-Identifier: GPL-2.0-only
#define _POSIX_C_SOURCE 200809L
+#include "common/scaled-img-buffer.h"
#include <assert.h>
#include <wayland-server-core.h>
#include <wlr/types/wlr_scene.h>
#include "buffer.h"
#include "common/mem.h"
-#include "common/scaled-img-buffer.h"
#include "common/scaled-scene-buffer.h"
#include "img/img.h"
#include "node.h"
// SPDX-License-Identifier: GPL-2.0-only
#define _POSIX_C_SOURCE 200809L
+#include "common/scaled-scene-buffer.h"
#include <assert.h>
#include <stdlib.h>
#include <wayland-server-core.h>
#include "common/list.h"
#include "common/macros.h"
#include "common/mem.h"
-#include "common/scaled-scene-buffer.h"
#include "node.h"
/*
// SPDX-License-Identifier: GPL-2.0-only
+#include "common/scene-helpers.h"
#include <assert.h>
#include <wlr/types/wlr_output.h>
#include <wlr/types/wlr_scene.h>
#include <wlr/util/log.h>
#include <wlr/util/region.h>
#include <wlr/util/transform.h>
-#include "common/scene-helpers.h"
#include "labwc.h"
#include "magnifier.h"
#include "output-state.h"
// SPDX-License-Identifier: GPL-2.0-only
-#include <wlr/util/log.h>
#include "common/set.h"
+#include <wlr/util/log.h>
bool
lab_set_contains(struct lab_set *set, uint32_t value)
// SPDX-License-Identifier: GPL-2.0-only
#define _POSIX_C_SOURCE 200809L
+#include "common/spawn.h"
#include <assert.h>
#include <fcntl.h>
#include <glib.h>
#include <sys/wait.h>
#include <unistd.h>
#include <wlr/util/log.h>
-#include "common/spawn.h"
#include "common/fd-util.h"
static void
// SPDX-License-Identifier: GPL-2.0-only
+#include "common/string-helpers.h"
#include <assert.h>
#include <ctype.h>
#include <stdarg.h>
#include <string.h>
#include <strings.h>
#include "common/mem.h"
-#include "common/string-helpers.h"
enum str_flags {
STR_FLAG_NONE = 0,
// SPDX-License-Identifier: GPL-2.0-only
+#include "common/surface-helpers.h"
#include <wlr/types/wlr_layer_shell_v1.h>
#include <wlr/types/wlr_subcompositor.h>
#include <wlr/util/log.h>
-#include "common/surface-helpers.h"
struct wlr_layer_surface_v1 *
subsurface_parent_layer(struct wlr_surface *wlr_surface)
// SPDX-License-Identifier: GPL-2.0-only
#define _POSIX_C_SOURCE 200809L
+#include "config/keybind.h"
#include <assert.h>
#include <glib.h>
#include <stdio.h>
#include <wlr/util/log.h>
#include "common/list.h"
#include "common/mem.h"
-#include "config/keybind.h"
#include "config/rcxml.h"
#include "labwc.h"
// SPDX-License-Identifier: GPL-2.0-only
+#include "config/libinput.h"
#include <string.h>
#include <strings.h>
#include "common/mem.h"
#include "common/list.h"
#include "common/string-helpers.h"
-#include "config/libinput.h"
#include "config/rcxml.h"
static void
// SPDX-License-Identifier: GPL-2.0-only
#define _POSIX_C_SOURCE 200809L
+#include "config/mousebind.h"
#include <assert.h>
#include <linux/input-event-codes.h>
#include <strings.h>
#include <wlr/util/log.h>
#include "common/list.h"
#include "common/mem.h"
-#include "config/mousebind.h"
#include "config/rcxml.h"
uint32_t
// SPDX-License-Identifier: GPL-2.0-only
#define _POSIX_C_SOURCE 200809L
+#include "config/rcxml.h"
#include <assert.h>
#include <fcntl.h>
#include <glib.h>
#include "config/libinput.h"
#include "config/mousebind.h"
#include "config/tablet.h"
-#include "config/rcxml.h"
#include "labwc.h"
#include "osd.h"
#include "regions.h"
// SPDX-License-Identifier: GPL-2.0-only
#define _POSIX_C_SOURCE 200809L
+#include "config/session.h"
#include <assert.h>
#include <dirent.h>
#include <stdbool.h>
#include "common/parse-bool.h"
#include "common/spawn.h"
#include "common/string-helpers.h"
-#include "config/session.h"
#include "labwc.h"
static const char *const env_vars[] = {
// SPDX-License-Identifier: GPL-2.0-only
#define _POSIX_C_SOURCE 200809L
+#include "config/tablet-tool.h"
#include <strings.h>
#include <wlr/util/log.h>
-#include "config/tablet-tool.h"
enum motion
tablet_parse_motion(const char *name)
// SPDX-License-Identifier: GPL-2.0-only
#define _POSIX_C_SOURCE 200809L
+#include "config/tablet.h"
#include <linux/input-event-codes.h>
#include <stdint.h>
#include <strings.h>
#include <wlr/util/log.h>
#include "common/parse-double.h"
-#include "config/tablet.h"
#include "config/rcxml.h"
#include "input/tablet-pad.h"
// SPDX-License-Identifier: GPL-2.0-only
#define _POSIX_C_SOURCE 200809L
+#include "config/touch.h"
#include <strings.h>
#include <wlr/util/log.h>
#include "common/list.h"
// SPDX-License-Identifier: GPL-2.0-only
+#include "debug.h"
#include <wlr/types/wlr_layer_shell_v1.h>
#include <wlr/types/wlr_scene.h>
#include "common/lab-scene-rect.h"
#include "common/scene-helpers.h"
#include "common/string-helpers.h"
-#include "debug.h"
#include "input/ime.h"
#include "labwc.h"
#include "node.h"
// SPDX-License-Identifier: GPL-2.0-only
+#include "desktop-entry.h"
#include <sfdo-desktop.h>
#include <sfdo-icon.h>
#include <sfdo-basedir.h>
#include "common/macros.h"
#include "common/mem.h"
#include "common/string-helpers.h"
-#include "desktop-entry.h"
#include "img/img.h"
#include "labwc.h"
// SPDX-License-Identifier: GPL-2.0-only
+#include "dnd.h"
#include <assert.h>
#include <wlr/types/wlr_data_device.h>
#include <wlr/types/wlr_scene.h>
#include <wlr/util/log.h>
-#include "dnd.h"
#include "input/cursor.h"
#include "labwc.h" /* for struct seat */
#include "view.h"
// SPDX-License-Identifier: GPL-2.0-only
+#include "edges.h"
#include <assert.h>
#include <limits.h>
#include <pixman.h>
#include "common/box.h"
#include "common/macros.h"
#include "config/rcxml.h"
-#include "edges.h"
#include "labwc.h"
#include "view.h"
#include "node.h"
// SPDX-License-Identifier: GPL-2.0-only
+#include "idle.h"
#include <assert.h>
#include <stdlib.h>
#include <wlr/types/wlr_idle_notify_v1.h>
#include <wlr/types/wlr_idle_inhibit_v1.h>
#include "common/mem.h"
-#include "idle.h"
struct lab_idle_inhibitor {
struct wlr_idle_inhibitor_v1 *wlr_inhibitor;
* Copyright (C) Johan Malm 2023
*/
#define _POSIX_C_SOURCE 200809L
+#include "img/img-png.h"
#include <assert.h>
#include <cairo.h>
#include <png.h>
#include <wlr/util/log.h>
#include "buffer.h"
#include "common/string-helpers.h"
-#include "img/img-png.h"
/*
* cairo_image_surface_create_from_png() does not gracefully handle non-png
* Copyright (C) Johan Malm 2023
*/
#define _POSIX_C_SOURCE 200809L
+#include "img/img-svg.h"
#include <cairo.h>
#include <librsvg/rsvg.h>
#include <stdbool.h>
#include <wlr/util/log.h>
#include "buffer.h"
#include "common/string-helpers.h"
-#include "img/img-svg.h"
#include "labwc.h"
RsvgHandle *
*/
#define _POSIX_C_SOURCE 200809L
+#include "img/img-xbm.h"
#include <assert.h>
#include <stdbool.h>
#include <stdint.h>
#include <string.h>
#include <drm_fourcc.h>
#include "img/img.h"
-#include "img/img-xbm.h"
#include "common/grab-file.h"
#include "common/mem.h"
#include "common/string-helpers.h"
* Adapted for labwc by John Lindgren, 2024
*/
+#include "img/img-xpm.h"
#include <glib.h>
#include <stdio.h>
#include <stdlib.h>
#include "common/buf.h"
#include "common/graphic-helpers.h"
#include "common/mem.h"
-#include "img/img-xpm.h"
enum buf_op { op_header, op_cmap, op_body };
// SPDX-License-Identifier: GPL-2.0-only
+#include "img/img.h"
#include <assert.h>
#include <wlr/util/log.h>
#include "buffer.h"
#include "common/macros.h"
#include "common/mem.h"
#include "common/string-helpers.h"
-#include "img/img.h"
#include "img/img-png.h"
#if HAVE_RSVG
#include "img/img-svg.h"
// SPDX-License-Identifier: GPL-2.0-only
#define _POSIX_C_SOURCE 200809L
+#include "input/cursor.h"
#include <assert.h>
#include <linux/input-event-codes.h>
#include <sys/time.h>
// SPDX-License-Identifier: GPL-2.0-only
+#include "input/gestures.h"
#include <wlr/types/wlr_pointer_gestures_v1.h>
#include "common/macros.h"
-#include "input/gestures.h"
#include "labwc.h"
#include "idle.h"
// SPDX-License-Identifier: GPL-2.0-only
/* Based on Sway (https://github.com/swaywm/sway) */
+#include "input/ime.h"
#include <assert.h>
#include "common/mem.h"
-#include "input/ime.h"
#include "node.h"
#include "view.h"
// SPDX-License-Identifier: GPL-2.0-only
-#include "input/cursor.h"
#include "input/input.h"
+#include "input/cursor.h"
#include "input/keyboard.h"
void
// SPDX-License-Identifier: GPL-2.0-only
+#include "input/key-state.h"
#include <stdbool.h>
#include <stdint.h>
#include <stdio.h>
#include <string.h>
#include <wlr/util/log.h>
#include "common/set.h"
-#include "input/key-state.h"
static struct lab_set pressed, bound, pressed_sent;
// SPDX-License-Identifier: GPL-2.0-only
#define _POSIX_C_SOURCE 200809L
+#include "input/keyboard.h"
#include <assert.h>
#include <stdlib.h>
#include <wlr/backend/multi.h>
#include "common/three-state.h"
#include "idle.h"
#include "input/ime.h"
-#include "input/keyboard.h"
#include "input/key-state.h"
#include "labwc.h"
#include "menu/menu.h"
// SPDX-License-Identifier: GPL-2.0-only
+#include "input/tablet-pad.h"
#include <assert.h>
#include <stdlib.h>
#include <wlr/backend/libinput.h>
#include "common/mem.h"
#include "config/rcxml.h"
#include "input/cursor.h"
-#include "input/tablet-pad.h"
#include "input/tablet.h"
#include "labwc.h"
// SPDX-License-Identifier: GPL-2.0-only
+#include "input/tablet.h"
#include <assert.h>
#include <stdlib.h>
#include <linux/input-event-codes.h>
#include "config/rcxml.h"
#include "config/mousebind.h"
#include "input/cursor.h"
-#include "input/tablet.h"
#include "input/tablet-pad.h"
#include "labwc.h"
#include "idle.h"
// SPDX-License-Identifier: GPL-2.0-only
+#include "input/touch.h"
#include <wayland-util.h>
#include <wlr/types/wlr_touch.h>
#include <linux/input-event-codes.h>
#include "common/mem.h"
#include "common/scene-helpers.h"
#include "idle.h"
-#include "input/touch.h"
#include "labwc.h"
#include "config/mousebind.h"
#include "action.h"
* Copyright (C) 2019 Drew DeVault and Sway developers
*/
+#include "layers.h"
#include <assert.h>
#include <stdbool.h>
#include <stdlib.h>
#include "common/macros.h"
#include "common/mem.h"
#include "config/rcxml.h"
-#include "layers.h"
#include "labwc.h"
#include "node.h"
// SPDX-License-Identifier: GPL-2.0-only
+#include "magnifier.h"
#include <assert.h>
#include <wlr/render/swapchain.h>
#include <wlr/types/wlr_output.h>
#include <wlr/util/transform.h>
#include "common/box.h"
#include "labwc.h"
-#include "magnifier.h"
#include "theme.h"
static bool magnify_on;
// SPDX-License-Identifier: GPL-2.0-only
#define _POSIX_C_SOURCE 200809L
+#include "menu/menu.h"
#include <assert.h>
#include <libxml/parser.h>
#include <libxml/tree.h>
#include "common/spawn.h"
#include "common/string-helpers.h"
#include "labwc.h"
-#include "menu/menu.h"
#include "workspaces.h"
#include "view.h"
#include "node.h"
// SPDX-License-Identifier: GPL-2.0-only
+#include "node.h"
#include <assert.h>
#include <stdlib.h>
#include "common/mem.h"
-#include "node.h"
static void
descriptor_destroy(struct node_descriptor *node_descriptor)
// SPDX-License-Identifier: GPL-2.0-only
+#include "osd.h"
#include <assert.h>
#include <cairo.h>
#include <wlr/util/log.h>
#include "config/rcxml.h"
#include "labwc.h"
#include "node.h"
-#include "osd.h"
#include "theme.h"
#include "view.h"
#include "window-rules.h"
// SPDX-License-Identifier: GPL-2.0-only
+#include "output-state.h"
#include <wlr/types/wlr_output.h>
#include <wlr/types/wlr_output_management_v1.h>
#include "labwc.h"
-#include "output-state.h"
void
output_state_init(struct output *output)
// SPDX-License-Identifier: GPL-2.0-only
+#include "output-virtual.h"
#include <stdlib.h>
#include <wlr/backend/headless.h>
#include <wlr/types/wlr_output.h>
#include "common/string-helpers.h"
#include "labwc.h"
-#include "output-virtual.h"
static struct wlr_output *fallback_output = NULL;
// SPDX-License-Identifier: GPL-2.0-only
+#include "overlay.h"
#include <assert.h>
#include "common/lab-scene-rect.h"
#include "labwc.h"
-#include "overlay.h"
#include "view.h"
#include "theme.h"
// SPDX-License-Identifier: GPL-2.0-only
+#include "placement.h"
#include <assert.h>
#include <limits.h>
#include <stdbool.h>
#include "common/macros.h"
#include "common/mem.h"
#include "labwc.h"
-#include "placement.h"
#include "ssd.h"
#include "view.h"
// SPDX-License-Identifier: GPL-2.0-only
+#include "protocols/transaction-addon.h"
#include <assert.h>
#include <wayland-server-core.h>
#include "common/list.h"
#include "common/mem.h"
-#include "protocols/transaction-addon.h"
void
lab_transaction_op_destroy(struct lab_transaction_op *trans_op)
// SPDX-License-Identifier: GPL-2.0-only
#define _POSIX_C_SOURCE 200809L
+#include "regions.h"
#include <assert.h>
#include <float.h>
#include <math.h>
#include "common/mem.h"
#include "input/keyboard.h"
#include "labwc.h"
-#include "regions.h"
#include "view.h"
bool
// SPDX-License-Identifier: GPL-2.0-only
+#include "resistance.h"
#include <assert.h>
#include <limits.h>
#include "common/border.h"
#include "config/rcxml.h"
#include "edges.h"
#include "labwc.h"
-#include "resistance.h"
#include "snap-constraints.h"
#include "view.h"
// SPDX-License-Identifier: GPL-2.0-only
+#include "resize-outlines.h"
#include <wlr/types/wlr_scene.h>
#include "common/lab-scene-rect.h"
#include "ssd.h"
-#include "resize-outlines.h"
#include "labwc.h"
bool
// SPDX-License-Identifier: GPL-2.0-only
#define _POSIX_C_SOURCE 200809L
+#include "session-lock.h"
#include <assert.h>
#include "common/mem.h"
#include "labwc.h"
// SPDX-License-Identifier: GPL-2.0-only
+#include "snap-constraints.h"
#include <assert.h>
#include <wlr/util/box.h>
#include "common/macros.h"
#include "labwc.h"
-#include "snap-constraints.h"
#include "view.h"
/*
// SPDX-License-Identifier: GPL-2.0-only
+#include "snap.h"
#include <assert.h>
#include <limits.h>
#include <wlr/util/box.h>
#include "edges.h"
#include "labwc.h"
#include "snap-constraints.h"
-#include "snap.h"
#include "view.h"
static void
*/
#define _POSIX_C_SOURCE 200809L
+#include "theme.h"
#include "config.h"
#include <assert.h>
#include <cairo.h>
#include "config/rcxml.h"
#include "img/img.h"
#include "labwc.h"
-#include "theme.h"
#include "buffer.h"
#include "ssd.h"
// SPDX-License-Identifier: GPL-2.0-only
/* view-impl-common.c: common code for shell view->impl functions */
+#include "view-impl-common.h"
#include <stdio.h>
#include <strings.h>
#include "foreign-toplevel.h"
#include "labwc.h"
#include "view.h"
-#include "view-impl-common.h"
#include "window-rules.h"
void
// SPDX-License-Identifier: GPL-2.0-only
+#include "view.h"
#include <assert.h>
#include <stdio.h>
#include <strings.h>
#include "snap-constraints.h"
#include "snap.h"
#include "ssd.h"
-#include "view.h"
#include "window-rules.h"
#include "wlr/util/log.h"
#include "workspaces.h"
// SPDX-License-Identifier: GPL-2.0-only
#define _POSIX_C_SOURCE 200809L
+#include "window-rules.h"
#include <assert.h>
#include <stdbool.h>
#include <cairo.h>
#include "config/rcxml.h"
#include "labwc.h"
#include "view.h"
-#include "window-rules.h"
static bool
other_instances_exist(struct view *self, struct view_query *query)
// SPDX-License-Identifier: GPL-2.0-only
#define _POSIX_C_SOURCE 200809L
+#include "workspaces.h"
#include <assert.h>
#include <cairo.h>
#include <pango/pangocairo.h>
#include "protocols/cosmic-workspaces.h"
#include "protocols/ext-workspace.h"
#include "view.h"
-#include "workspaces.h"
#include "xwayland.h"
#define COSMIC_WORKSPACES_VERSION 1
// SPDX-License-Identifier: GPL-2.0-only
#define _POSIX_C_SOURCE 200809L
+#include "xwayland.h"
#include <assert.h>
#include <stdlib.h>
#include <wlr/xwayland.h>
#include "view-impl-common.h"
#include "window-rules.h"
#include "workspaces.h"
-#include "xwayland.h"
enum atoms {
ATOM_NET_WM_ICON = 0,