diff --git a/src/apprt/gtk/Window.zig b/src/apprt/gtk/Window.zig index 68b1197f7..28906565f 100644 --- a/src/apprt/gtk/Window.zig +++ b/src/apprt/gtk/Window.zig @@ -183,6 +183,14 @@ pub fn init(self: *Window, app: *App) !void { } c.adw_toolbar_view_set_content(toolbar_view, box); + const toolbar_style: c.AdwToolbarStyle = switch (self.app.config.@"adw-toolbar-style") { + .flat => c.ADW_TOOLBAR_FLAT, + .raised => c.ADW_TOOLBAR_RAISED, + .@"raised-border" => c.ADW_TOOLBAR_RAISED_BORDER, + }; + c.adw_toolbar_view_set_top_bar_style(toolbar_view, toolbar_style); + c.adw_toolbar_view_set_bottom_bar_style(toolbar_view, toolbar_style); + c.adw_application_window_set_content(@ptrCast(gtk_window), @ptrCast(@alignCast(toolbar_view))); } else { // The box is our main child diff --git a/src/config/Config.zig b/src/config/Config.zig index 2ae3aad0b..eb3b98598 100644 --- a/src/config/Config.zig +++ b/src/config/Config.zig @@ -1426,6 +1426,12 @@ keybind: Keybinds = .{}, /// back to `top`. @"gtk-tabs-location": GtkTabsLocation = .top, +/// Determines the appearance of the top and bottom bars when using the adwaita tab bar. +/// If set to `flat`, top and bottom bars are flat with the terminal window. +/// If set to `raised`, top and bottom bars cast a shadow on the terminal area. +/// `raised-border` is similar to `raised` but the shadow is replaced with a more subtle border. +@"adw-toolbar-style": AdwToolBarStyle = .raised, + /// If `true` (default), then the Ghostty GTK tabs will be "wide." Wide tabs /// are the new typical Gnome style where tabs fill their available space. /// If you set this to `false` then tabs will only take up space they need, @@ -4064,6 +4070,13 @@ pub const GtkTabsLocation = enum { right, }; +/// See adw-toolbar-style +pub const AdwToolBarStyle = enum { + flat, + raised, + @"raised-border", +}; + /// See mouse-shift-capture pub const MouseShiftCapture = enum { false,