aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorAlexander Orzechowski <alex@ozal.ski>2023-11-21 19:51:57 -0500
committerKirill Primak <vyivel@eclair.cafe>2024-01-18 18:36:54 +0300
commit6d7b1321db54155cf78305dbafdcfc7de9b78415 (patch)
treeacf9f02681b1d5a40416be5f4151641920176a93 /include
parent188811f80861caacd016b857b0d07f6d2d62d15a (diff)
scene_graph: Port container server side decorations
Diffstat (limited to 'include')
-rw-r--r--include/sway/tree/container.h37
1 files changed, 13 insertions, 24 deletions
diff --git a/include/sway/tree/container.h b/include/sway/tree/container.h
index 6f72439c..4920e064 100644
--- a/include/sway/tree/container.h
+++ b/include/sway/tree/container.h
@@ -76,6 +76,9 @@ struct sway_container {
struct wlr_scene_tree *border;
struct wlr_scene_tree *background;
+
+ struct sway_text_node *title_text;
+ struct sway_text_node *marks_text;
} title_bar;
struct {
@@ -94,6 +97,7 @@ struct sway_container {
char *title; // The view's title (unformatted)
char *formatted_title; // The title displayed in the title bar
+ int title_width;
enum sway_container_layout prev_split_layout;
@@ -141,18 +145,7 @@ struct sway_container {
float alpha;
- struct wlr_texture *title_focused;
- struct wlr_texture *title_focused_inactive;
- struct wlr_texture *title_focused_tab_title;
- struct wlr_texture *title_unfocused;
- struct wlr_texture *title_urgent;
-
list_t *marks; // char *
- struct wlr_texture *marks_focused;
- struct wlr_texture *marks_focused_inactive;
- struct wlr_texture *marks_focused_tab_title;
- struct wlr_texture *marks_unfocused;
- struct wlr_texture *marks_urgent;
struct {
struct wl_signal destroy;
@@ -194,7 +187,9 @@ void container_reap_empty(struct sway_container *con);
struct sway_container *container_flatten(struct sway_container *container);
-void container_update_title_textures(struct sway_container *container);
+void container_update_title_bar(struct sway_container *container);
+
+void container_update_marks(struct sway_container *container);
size_t container_build_representation(enum sway_container_layout layout,
list_t *children, char *buffer);
@@ -231,11 +226,6 @@ void container_set_geometry_from_content(struct sway_container *con);
bool container_is_floating(struct sway_container *container);
/**
- * Same as above, but for current container state.
- */
-bool container_is_current_floating(struct sway_container *container);
-
-/**
* Get a container's box in layout coordinates.
*/
void container_get_box(struct sway_container *container, struct wlr_box *box);
@@ -308,15 +298,10 @@ void container_discover_outputs(struct sway_container *con);
enum sway_container_layout container_parent_layout(struct sway_container *con);
-enum sway_container_layout container_current_parent_layout(
- struct sway_container *con);
-
list_t *container_get_siblings(struct sway_container *container);
int container_sibling_index(struct sway_container *child);
-list_t *container_get_current_siblings(struct sway_container *container);
-
void container_handle_fullscreen_reparent(struct sway_container *con);
void container_add_child(struct sway_container *parent,
@@ -364,8 +349,6 @@ bool container_has_mark(struct sway_container *container, char *mark);
void container_add_mark(struct sway_container *container, char *mark);
-void container_update_marks_textures(struct sway_container *container);
-
void container_raise_floating(struct sway_container *con);
bool container_is_scratchpad_hidden(struct sway_container *con);
@@ -389,4 +372,10 @@ bool container_is_sticky_or_child(struct sway_container *con);
*/
int container_squash(struct sway_container *con);
+void container_arrange_title_bar(struct sway_container *con);
+
+void container_update(struct sway_container *con);
+
+void container_update_itself_and_parents(struct sway_container *con);
+
#endif