gpui: Add support for floating windows (#39702)

Closes #ISSUE

This allows new windows like the Rules library or the Settings UI window
to appear floating on window managers like hyprland:


https://github.com/user-attachments/assets/628db7f9-4459-4601-85f1-789923831182

Left is with `WindowKind::Floating` and right is with
`WindowKind::Normal`

Release Notes:

- Added support for floating windows on x11 and wayland
This commit is contained in:
Alvaro Parker
2025-10-08 20:48:17 +02:00
committed by GitHub
parent e0eeda11ed
commit 1e149b755f
8 changed files with 67 additions and 5 deletions
@@ -136,6 +136,7 @@ pub fn open_rules_library(
window_background: cx.theme().window_background_appearance(),
window_decorations: Some(window_decorations),
window_min_size: Some(size(px(800.), px(600.))), // 4:3 Aspect Ratio
kind: gpui::WindowKind::Floating,
..Default::default()
},
|window, cx| {