Desktop Portals
Save dialogs, screen sharing, and keyring access through xdg-desktop-portal.
Portals let apps open file dialogs and share your screen. Sweets sets them up
for you when you start it with sweets-session.
What to install
| Package | Provides |
|---|---|
xdg-desktop-portal | The portal service |
xdg-desktop-portal-gtk | Open and save dialogs |
xdg-desktop-portal-wlr | Screenshots and screen sharing |
To pick a window when sharing a single window, xdg-desktop-portal-wlr needs a
chooser such as slurp or rofi. See its documentation for chooser_cmd.
On systems without systemd, make sure your session starts the portal services.
Troubleshooting
| Problem | Fix |
|---|---|
Save dialog fails with Could not activate ... portal.Desktop | Log out and start Sweets again with sweets-session |
| A shared window freezes when you switch workspaces | Add render_unfocused to the shared app's window rule |
Keyring (optional)
Password managers and keyrings like gnome-keyring or KeePassXC work without
any Sweets setup.
Flatpak apps reach the keyring through a portal. To pick gnome-keyring for
them, create ~/.config/xdg-desktop-portal/sweets-portals.conf:
[preferred]
default=gtk
org.freedesktop.impl.portal.Screenshot=wlr
org.freedesktop.impl.portal.ScreenCast=wlr
org.freedesktop.impl.portal.Secret=gnome-keyring