copying to clipboard works only few minutes after pushing it via tray icon
Flameshot Version
flameshot --version
Flameshot v12.1.0 (Debian 12.1.0+ds-2) Compiled with Qt 5.15.1
Installation Type
Linux, MacOS, or Windows Package manager (apt, pacman, eopkg, choco, brew, ...)
Operating System type and version
kubuntu 25.04
Description
i use shortcut meta+shift+s to make screenshot and enter to copy area to clipboard. It doesn't work until i click on tray icon and select "take screenshot". than my shortcut works for some time.. after that it stopped..
here's my config if it's matter
cat /home/emoxam/.config/flameshot/flameshot.ini [General] buttons=@Variant(\0\0\0\x7f\0\0\0\vQList
\0\0\0\0\x18\0\0\0\0\0\0\0\x1\0\0\0\x2\0\0\0\x3\0\0\0\x4\0\0\0\x5\0\0\0\x6\0\0\0\x12\0\0\0\xf\0\0\0\x16\0\0\0\x13\0\0\0\a\0\0\0\b\0\0\0\t\0\0\0\x10\0\0\0\n\0\0\0\v\0\0\0\r\0\0\0\x17\0\0\0\xe\0\0\0\f\0\0\0\x11\0\0\0\x14\0\0\0\x15) contrastOpacity=188 [Shortcuts] TYPE_ACCEPT=Return
Steps to reproduce
No response
Screenshots or screen recordings
No response
System Information
KDE Wayland
Can you please test using our master branch?
what does it mean?
It means to build flameshot from source and test it
I don't know how to do it. Is there any builded release?
I don't know how to do it. Is there any builded release?
you are on kubuntu right? So you must have installed flameshot using apt install flameshot. To test the master branch, you must build flameshot from source.
Please follow these instructions in the readme itself. Note that you just need to build and run, do not install after building
i've got qt6
cmake -S . -B "$BUILD_DIR"
&& cmake --build "$BUILD_DIR"
-- The CXX compiler identification is GNU 14.2.0 -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- Check for working CXX compiler: /usr/bin/c++ - skipped -- Detecting CXX compile features -- Detecting CXX compile features - done CMake Error at build/_deps/qtcolorwidgets-src/CMakeLists.txt:35 (find_package): By not providing "FindQt6.cmake" in CMAKE_MODULE_PATH this project has asked CMake to find a package configuration file provided by "Qt6", but CMake did not find one.
Could not find a package configuration file provided by "Qt6" with any of the following names:
Qt6Config.cmake qt6-config.cmakeAdd the installation prefix of "Qt6" to CMAKE_PREFIX_PATH or set "Qt6_DIR" to a directory containing one of the above files. If "Qt6" provides a separate development package or SDK, be sure it has been installed.
apt install g++ cmake build-essential qtbase5-dev qttools5-dev-tools libqt5svg5-dev qttools5-dev
apt install libqt5dbus5 libqt5network5 libqt5core5a libqt5widgets5 libqt5gui5 libqt5svg5
apt install qt6-base-dev qt6-svg-dev qt6-tools-dev-tools qt6-linugist-dev qt6-tools-dev
export BUILD_DIR=build
cmake -S . -B "$BUILD_DIR" && cmake --build "$BUILD_DIR"
./flameshot --version
Flameshot v12.1.0 (1f59ef5c)
Compiled with Qt 6.8.3
./flameshot gui
QLayout: Attempting to add QLayout "" to SidePanelWidget "", which already has a layout
QPainter::begin: Paint device returned engine == 0, type: 2
QPainter::setRenderHint: Painter must be active to set rendering hints
QPainter::setCompositionMode: Painter not active
QPainter::translate: Painter not active
QPainter::setPen: Painter not active
QPainter::setBrush: Painter not active
QPainter::drawEllipse: Painter not active
QPainter::setBrush: Painter not active
QPainter::drawEllipse: Painter not active
languages changes from QList("en_US", "en_US") to QList("en_US", "en_US")
languages changes from QList("en_US", "en_US") to QList("en_US", "en_US")
QThreadStorage: entry 10 destroyed before end of thread 0x573fed10ba00
QThreadStorage: entry 9 destroyed before end of thread 0x573fed10ba00
QThreadStorage: entry 8 destroyed before end of thread 0x573fed10ba00
QThreadStorage: entry 2 destroyed before end of thread 0x573fed10ba00
QThreadStorage: entry 1 destroyed before end of thread 0x573fed10ba00
it doesn't save clipboard content. it pastes the previous.
I believe the issue is the old .deb does not include the "wayland clipboard" feature, and likely when you built from source you did not enable this (because we didn't tell you :-) )
Try this
apt install libkf6guiaddons-dev
cd flameshot
mkdir build
cd flameshot/build
cmake -DUSE_WAYLAND_CLIPBOARD=True ../
make
./src/flameshot
Now the clipboard should work
@mmahmoudian With wayland really taking over, I propose we enable the wayland clipboard flag by default on linux builds.
root@emoxam-b450mds3h /h/e/D/f/build (master)# cmake -DUSE_WAYLAND_CLIPBOARD=True ../
CMake Warning (dev) at build/_deps/qtcolorwidgets-src/cmake/modules/ProjectVersioning.cmake:42 (exec_program):
Policy CMP0153 is not set: The exec_program command should not be called.
Run "cmake --help-policy CMP0153" for policy details. Use the cmake_policy
command to set the policy and suppress this warning.
Use execute_process() instead.
Call Stack (most recent call first):
build/_deps/qtcolorwidgets-src/cmake/versioning.cmake:15 (target_version_information)
build/_deps/qtcolorwidgets-src/CMakeLists.txt:124 (generate_versioning_information)
This warning is for project developers. Use -Wno-dev to suppress it.
CMake Warning (dev) at build/_deps/qtcolorwidgets-src/cmake/modules/ProjectVersioning.cmake:48 (exec_program):
Policy CMP0153 is not set: The exec_program command should not be called.
Run "cmake --help-policy CMP0153" for policy details. Use the cmake_policy
command to set the policy and suppress this warning.
Use execute_process() instead.
Call Stack (most recent call first):
build/_deps/qtcolorwidgets-src/cmake/versioning.cmake:15 (target_version_information)
build/_deps/qtcolorwidgets-src/CMakeLists.txt:124 (generate_versioning_information)
This warning is for project developers. Use -Wno-dev to suppress it.
CMake Warning at cmake/Cache.cmake:28 (message):
ccache is enabled but was not found. Not using it
Call Stack (most recent call first):
CMakeLists.txt:114 (include)
-- KDSingleApplication is used!
Flameshot predefined color palette large: false
git found: /usr/bin/git in version 2.48.1
FLAMESHOT_GIT_HASH: 1f59ef5c
-- Configuring done (0.8s)
-- Generating done (0.1s)
-- Build files have been written to: /home/emoxam/Downloads/flameshot/build
root@emoxam-b450mds3h /h/e/D/f/build (master)# make
[ 0%] Built target QtColorWidgets_autogen_timestamp_deps
[ 1%] Built target QtColorWidgets_autogen
[ 14%] Built target QtColorWidgets
[ 14%] Built target QtColorWidgetsPlugin_autogen_timestamp_deps
[ 14%] Built target QtColorWidgetsPlugin_autogen
[ 21%] Built target QtColorWidgetsPlugin
[ 21%] Built target kdsingleapplication_autogen_timestamp_deps
[ 21%] Built target kdsingleapplication_autogen
[ 24%] Built target kdsingleapplication
[ 24%] Built target flameshot_autogen_timestamp_deps
[ 24%] Built target flameshot_autogen
[100%] Built target flameshot
cd src/ ./flameshot gui
QLayout: Attempting to add QLayout "" to SidePanelWidget "", which already has a layout
QPainter::begin: Paint device returned engine == 0, type: 2
QPainter::setRenderHint: Painter must be active to set rendering hints
QPainter::setCompositionMode: Painter not active
QPainter::translate: Painter not active
QPainter::setPen: Painter not active
QPainter::setBrush: Painter not active
QPainter::drawEllipse: Painter not active
QPainter::setBrush: Painter not active
QPainter::drawEllipse: Painter not active
languages changes from QList("en_US", "en_US") to QList("en_US", "en_US")
languages changes from QList("en_US", "en_US") to QList("en_US", "en_US")
QThreadStorage: entry 10 destroyed before end of thread 0x5a045f9bfa00
QThreadStorage: entry 9 destroyed before end of thread 0x5a045f9bfa00
QThreadStorage: entry 8 destroyed before end of thread 0x5a045f9bfa00
QThreadStorage: entry 2 destroyed before end of thread 0x5a045f9bfa00
QThreadStorage: entry 1 destroyed before end of thread 0x5a045f9bfa00
Clipboard still doesn't work.
that is when i start it not from the root user
./flameshot gui
QLayout: Attempting to add QLayout "" to SidePanelWidget "", which already has a layout
QPainter::begin: Paint device returned engine == 0, type: 2
QPainter::setRenderHint: Painter must be active to set rendering hints
QPainter::setCompositionMode: Painter not active
QPainter::translate: Painter not active
QPainter::setPen: Painter not active
QPainter::setBrush: Painter not active
QPainter::drawEllipse: Painter not active
QPainter::setBrush: Painter not active
QPainter::drawEllipse: Painter not active
languages changes from QList("en_US", "en_US") to QList("en_US", "en_US")
languages changes from QList("en_US", "en_US") to QList("en_US", "en_US")
QThreadStorage: entry 10 destroyed before end of thread 0x59401adb5a00
QThreadStorage: entry 9 destroyed before end of thread 0x59401adb5a00
QThreadStorage: entry 8 destroyed before end of thread 0x59401adb5a00
QThreadStorage: entry 2 destroyed before end of thread 0x59401adb5a00
QThreadStorage: entry 1 destroyed before end of thread 0x59401adb5a00
syslog 2025-07-01T09:43:41.175788+03:00 emoxam-b450mds3h org.flameshot.Flameshot[98311]: flameshot: info: Capture saved to clipboard.
paste from the clipboard doesn't work
Are you closing flameshot before pasting? Not sure what could be going on, I tested from source in a brand new Ubuntu25.04 VM and I cannot replicate the problem
@emoxam Can you try and check if the image is actually in the clipboard or not? You can in plasma's clipboard via Meta+V (Windows Key + V). On Hyprland I have a similar problem where sometimes I have to reselect the latest image by opening my clipboard list, then only I can paste.
@borgmanJeremy
@mmahmoudian With wayland really taking over, I propose we enable the wayland clipboard flag by default on linux builds.
I agree with your point. I tried to create a PR #4051