You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -5790,6 +5791,29 @@ On Linux, the module detects the current desktop environment and loads the appro
5790
5791
5791
5792
Detection uses `XDG_CURRENT_DESKTOP` and `DESKTOP_SESSION` environment variables.
5792
5793
5794
+
### System Button Layout
5795
+
5796
+
On GNOME, the module reads the `org.gnome.desktop.wm.preferences` → `button-layout` GSettings key to determine which titlebar buttons to display and on which side. This is done via `libgio` (`dlopen`, no hard compile-time dependency).
5797
+
5798
+
The layout updates **reactively** — if the user changes the button configuration in GNOME Tweaks (or via `gsettings set`), the title bar updates in real time without restarting the application.
5799
+
5800
+
Supported configurations include:
5801
+
5802
+
- `:minimize,maximize,close` — right side, all buttons (GNOME with tweaks)
5803
+
- `close,minimize,maximize:` — left side, Ubuntu style
5804
+
- `appmenu:close` — right side, close only (GNOME default)
5805
+
5806
+
On **KDE** and other desktop environments, the module falls back to the default layout (close, maximize, minimize on the right).
5807
+
5808
+
If you need the layout value directly (e.g. for custom rendering), use the `rememberLinuxButtonLayout()` composable:
5809
+
5810
+
```kotlin
5811
+
val layout = rememberLinuxButtonLayout()
5812
+
// layout.buttons — ordered list of visible buttons
5813
+
// layout.controlsOnRight — true if buttons are on the right side
0 commit comments