- Goto Keyboard settings and click 'Save a screenshot to Pictures' under 'Screenshots' section.
- Press 'Backspace' key delete 'PrtScr' key shortcut and press 'Set' button
- Press '+'(Plust) icon in the 'Custom Shortcuts' in the same window
- Enter 'Flameshot' in 'Name' field , 'flameshot gui' in 'Command' field, and click 'Set Shortcut' button and press 'PrtScr' button in the keyboard and close the dialog box 5.That's it. If you press 'PrtScr' key, the Flameshot selection area screen will appear.
-
-
Save linuxkathirvel/5e8bb416f487b4b47a97daa42288502f to your computer and use it in GitHub Desktop.
I had the same issue as @LK-Hemant, on Fedora 41, Gnome 47.1. This flameshot-org/flameshot#3252 also appear to be the same. The shortcut flameshot gui
errors, while gnome-terminal -- flameshot gui
works but opens a terminal. I also tried using flatpak run org.flameshot.Flameshot gui
as suggested by @George33331, but I get the error
Gtk-Message: 09:48:19.058: Failed to load module "canberra-gtk-module"
Gtk-Message: 09:48:19.058: Failed to load module "pk-gtk-module"
Gtk-Message: 09:48:19.059: Failed to load module "canberra-gtk-module"
Gtk-Message: 09:48:19.059: Failed to load module "pk-gtk-module"
qt.qpa.qgnomeplatform: Could not find color scheme ""
Qt: Session management error: Could not open network socket
flameshot: error: Unable to capture screen
flameshot: error: Unable to capture screen
flameshot: info: Screenshot aborted.
I had same issue and was able to solve by passing all variables via script as when triggered via a shortcut, GNOME doesn't pass all these variables, especially under Wayland (which my laptop is on), which requires stricter permissions.
First you make script flameshot.sh.
#!/bin/bash
export DISPLAY=:0
export WAYLAND_DISPLAY=$WAYLAND_DISPLAY
export DBUS_SESSION_BUS_ADDRESS=$DBUS_SESSION_BUS_ADDRESS
/usr/bin/flameshot gui
Make sure it can be executed chmod +x flameshot.sh
and then just add this script in keyboard shortcuts instead. i.e. /usr/local/bin/flameshot.sh
Hope that helps
(@Kornelljus, I jumped the gun in saying that it was working perfectly in the previous version of this message).
With Kornelljus' trick the shortcut does work but it oddly shows only a cropped version of the screen in the flameshot editor.
Say that what is currently shown on display is
then pressing prt sc
which runs /usr/bin/flameshot gui
after exporting the env variables I only see a cropped version of it:
However, after saving it I correctly get
Any idea on how to fix that?
Yeah, it does not show that GUI window. It shows takimg full screenshot of your screen and does not show that menu or whatever you call it. But if you click mouse after that "flash" and drag, you will get that specific area pop-up as it should an allow you to draw, etc.
@Kornelljus sorry I was probably unclear in my post. I don't see a problem with flameshot's gui, the problem is that after the flash, I can only edit a portion of the original display. Here is an image where I try to show the problem:
Worked perfectly, thank you
Worked perfectly, thanks! Figured out every step aside from typing
flameshot gui
specifically, so I just typedflameshot
and that simply opened the app, haha. Can confirm it requires removing the default PrtScr binding first though! If you skip it, you won't be able to define the custom PrtScr action.