Repository navigation
Description
On GNOME (Wayland), a window with App::titlebar gets winit's own frame: mutter offers no xdg-decoration, so winit draws its light grey Adwaita bar (no title, since Rune builds winit with wayland-csd-adwaita-notitle) above the app's titlebar. A dark app ends up under a blank grey band, with a lone close button.
Suggested change, one commit on dev: jamesponwith/rune@dev...linux-client-titlebar (41a985c4). Opening a pull request here isn't allowed for outside accounts, so it's linked instead; happy to adjust it to whatever shape you prefer.
It draws the app's own frame there, the way Windows already does for App::titlebar:
- When: a window with
App::titlebar, not borderless, on Wayland, where the compositor lackszxdg_decoration_manager_v1(asked once on winit's own connection,titlebar::linux::server_decorates). The window is made withwith_decorations(false), so winit never draws its bar. KDE, Hyprland and Sway offer server-side decorations and keep theirs; X11 keeps its window manager's frame. Apps withoutApp::titlebarare unchanged. - Caption buttons: the existing
Captionandtitlebar::framepath, with aButtonLayoutfrom GNOME'sorg.gnome.desktop.wm.preferencesbutton-layout, read through the settings portal in the same first read ascolor-scheme(portal_appearance).appmenu:close, GNOME's default, is close alone; a layout on the left draws mirrored. The buttons are libadwaita's shape: a 24 pt circle washed withCx::caption_colorat 10%, 15% under the pointer, with the Windows symbols in it. They are ordinary elements, so the pointer presses them throughon_press(Tx::minimize,Tx::toggle_maximized,Tx::close_window).Cx::chrome_insetsreports their room and the titlebar's height. - Resize edges: a 5 pt band inside each side, 16 pt along a corner for the diagonals (
titlebar::linux::edge_at). Over it the host shows the resize cursor (OsCursor::set_override) and a primary press callsdrag_resize_windowinstead of reaching the view. A maximized, full-screen or fixed-size window has none. - Drag and double click already worked through
.window_drag()andtitlebar_double_click.
Not here: a client-side shadow and rounded corners (the window is square and shadowless on GNOME, as a borderless one is today), the window menu on right click (winit 0.30 has no show_window_menu on Wayland), and following a button-layout change while a window is open (it shows in windows opened after it).
Checked:
cargo test -p rune --lib titlebaron macOS (the two new tests intitlebar/linux_tests.rs: layout parsing and edge hit-testing, plus the existing titlebar tests).cargo checkandcargo clippy -p rune --features dbuson Arch Linux (no new warnings).- In an app that sets
App::titlebar(Phux Rune), on a Fedora 45 Workstation live session (GNOME 49, Wayland): no grey bar;appmenu:closeshows close alone;appmenu:minimize,maximize,closeshows all three at the right, and each works;close,minimize,maximize:puts them at the left; dragging the titlebar moves the window; dragging the right edge resizes it; the buttons follow the app's light and dark inks live. - On Hyprland,
WAYLAND_DEBUG=1shows the toplevel still asking for and getting server-side mode (set_mode(2),configure(2)), so nothing changes there.
Activity
feat(rune): take the app's own titlebar on linux
feat(rune): take the app's own titlebar on linux
feat(rune): take the app's own titlebar on linux
feat(rune): take the app's own titlebar on linux (#2515)
Hona commentedon Nov 24, 2026
Closing as a duplicate of #591, which tracks replacing the system/winit title bar with Rune's own client-side frame for
App::titlebaron Linux. Your native Wayland GNOME 49 report, thezxdg_decoration_manager_v1check to preserve native frames on SSD compositors and X11, GNOME portalbutton-layoutsupport, and pointer to your fork implementation have been carried over to #591 so nothing is lost. Thanks for putting that together!App::titlebarkeeps the system title bar, so GNOME on Wayland gets two bars, or no window controls with decorations off; a fix is on a fork #591feat(titlebar): App::titlebar is the window's only bar where a Waylan…