opt: tab_bar_decorate and jump_label_decorate config separate

This commit is contained in:
DreamMaoMao 2026-06-18 10:18:16 +08:00
parent 892d1279b6
commit a5d44d7347
9 changed files with 292 additions and 166 deletions

View file

@ -179,7 +179,7 @@ enum {
NUM_LAYERS
}; /* scene layers */
enum mango_node_type { MANGO_TITLE_NODE, MANGO_TEXT_NODE };
enum mango_node_type { MANGO_TITLE_NODE, MANGO_jump_label_node };
#ifdef XWAYLAND
enum {
@ -337,8 +337,8 @@ struct Client {
struct wlr_scene_shadow *shadow;
struct wlr_scene_tree *scene_surface;
struct wlr_scene_tree *overview_scene_surface;
struct mango_text_node *text_node;
struct mango_titlebar_node *titlebar_node;
struct mango_jump_label_node *jump_label_node;
struct mango_tab_bar_node *tab_bar_node;
struct wl_list link;
struct wl_list flink;
struct wl_list fadeout_link;
@ -1274,8 +1274,8 @@ void swallow(Client *c, Client *w) {
overview_backup_surface(c);
}
if (w->titlebar_node) {
wlr_scene_node_set_enabled(&w->titlebar_node->scene_buffer->node,
if (w->tab_bar_node) {
wlr_scene_node_set_enabled(&w->tab_bar_node->scene_buffer->node,
false);
}
@ -6570,8 +6570,8 @@ void unmapnotify(struct wl_listener *listener, void *data) {
c->stack_proportion = 0.0f;
mango_text_node_destroy(c->text_node);
mango_titlebar_node_destroy(c->titlebar_node);
mango_jump_label_node_destroy(c->jump_label_node);
mango_tab_bar_node_destroy(c->tab_bar_node);
wlr_scene_node_destroy(&c->scene->node);
printstatus(IPC_WATCH_ARRANGGE);
motionnotify(0, NULL, 0, 0, 0, 0);
@ -6724,7 +6724,7 @@ void updatetitle(struct wl_listener *listener, void *data) {
const char *title;
title = client_get_title(c);
mango_titlebar_node_update(c->titlebar_node, title, 1.0);
mango_tab_bar_node_update(c->tab_bar_node, title, 1.0);
if (title && c->foreign_toplevel)
wlr_foreign_toplevel_handle_v1_set_title(c->foreign_toplevel, title);
if (c == focustop(c->mon))