News for hackers. Stuff that matters.
Re:Wayland is not ready as a 1:1 compatible Xorg replacement... by adrusi on Tuesday February 02, 2021 @08:30AM (#26000716)
Pretty grim, heh

Context: https://wayland.emersion.fr/grim/

Re:Wayland is not ready as a 1:1 compatible Xorg replacement... by dbrgn on Tuesday February 02, 2021 @09:59AM (#26001665)
I use grim with sway / wayland and it works great, much better than scrot on X (which always leaves strange visual artifacts on the image when using rectangular selection).

Here's my key binding config from sway:

bindsym print exec filename=$(date +'screenshot-%Y%m%d-%H%M%S.png') && swaymsg -t get_tree | jq -r '.. | (.nodes? // empty)[] | select(.pid and .visible) | .rect | "\(.x),\(.y) \(.width)x\(.height)"' | slurp | grim -g - /tmp/$filename && notify-send "Screenshot captured" "/tmp/$filename"