When running image capture using Flameshot on Wayland, I encountered a problem where image capture from Flameshot did not work and did not display the Flameshot GUI. Previously, it worked fine using X11, but when I switched to Wayland, it didn't work. There are a few things you need to know: Flameshot (Qt app) on Wayland tries to use XCB to capture the screen. Under Wayland, direct screen capture is blocked for security reasons. It must instead use the xdg-desktop-portal API (via xdg-desktop-portal-gnome and xdg-desktop-portal) to request screenshots.
- Install the correct portals and Wayland support
sudo apt update
sudo apt install -y \
qtwayland5 \
xdg-desktop-portal \