Created attachment 109264 [details] Error happens with running the dbus API through d-feet as well. Default @kde-desktop on Fedora 27, version 5.10.5 (not available in your list). kwin-5.10.5-2.fc27.x86_64 plasma-desktop-5.10.5-1.fc27.x86_64 I am implementing color-picking on KDE for GIMP, with your API so that it works also on KDE/Wayland. Unfortunately calling the new "pick" method (https://phabricator.kde.org/D3480), I constantly get the following error: > GDBus.Error:org.kde.kwin.ColorPicker.Error.Cancelled: Color picking got cancelled I would assume there is a bug in code too, but since that's a very simple dbus call with no arguments, I don't see where I could make a mistake. Also the error happens if I run the call with the d-feet application as well (see screenshot).
I just installed d-feet and gave it a try: works fine. Possibilities I see is a setup error in Fedora or a bug in the version (5.10 is no longer maintained, that's also the reason why it's not in the list). Reasons for the canceled message are: * right click * Escape beint pressed
(In reply to Martin Flöser from comment #1) > I just installed d-feet and gave it a try: works fine. > > Possibilities I see is a setup error in Fedora or a bug in the version (5.10 > is no longer maintained, that's also the reason why it's not in the list). > > Reasons for the canceled message are: > * right click > * Escape beint pressed Hmm… well I won't be able to make the time to build an updated version of kwin/plasma. I guess I will just assume my implementation is fine or wait for Fedora to update their package to test again.
Created attachment 110321 [details] Image of error
Comment on attachment 110321 [details] Image of error The bug is reproducible on KDE version 5.11.5.
Thanks Ankush. Updating the version field now that someone reproduced this on a maintained version of KDE. :-)
I just installed d-feet on my other system and tried there. I'm not able to reproduce, d-feet does not print the cancel warning. My steps: 1. open d-feet 2. select session bus 3. filter for KWin 4. select /ColorPicker -> pick 5. click execute 6. Now cursor becomes a cross and a message pops up 7. I click somewhere 8. d-feet prints the result. Are there any steps I do in a different way?
For my own, that's the same steps, except I don't have your steps 6 to 8. After clicking "Execute", I just get the error directly. Also I would like to note that we are using the API under KDE/X11, not Wayland (both Ankush Patel and I; he first reported the issue on GIMP: https://bugzilla.gnome.org/show_bug.cgi?id=793133). I realize I never said so because the ultimate goal was to have support for Wayland. But we still use the API, even on X11, as priority color-picking method when available. Are you testing on KDE/Wayland or X11?
P.S.: and I have not tried under KDE/Wayland because Fedora does not propose me the option from the packaged KDE and I can't make the time to build KDE from scratch. So that's all I can help for now!
Very likely that is the reason: I'm testing on Wayland. On X11 it needs to grab the pointer and keyboard. Maybe that is failing.
(In reply to Martin Flöser from comment #9) > Very likely that is the reason: I'm testing on Wayland. On X11 it needs to > grab the pointer and keyboard. Maybe that is failing. Ok. Well ideally this would be fixed so that it works both on X11 and Wayland. As a workaround, you could just disable the API on X11. If it is unavailable, GIMP will directly go to the X11 screenshot implementation and at least not throw errors. Basically if the API is shown as available, it should work. ;-)
I just digged into the source and it looks like someone forgot to implement this on X11.
And reproduced on X11
Patch at: https://phabricator.kde.org/D10302
Git commit ea5e70116456975b3ca3f379777b8a83291bb4e8 by Martin Flöser. Committed on 05/02/2018 at 20:21. Pushed by graesslin into branch 'Plasma/5.12'. [x11] Fix interactive point selection Summary: The support for interactive point selection was missing. This results in the ColorPicker dbus API always returning an error on X11. We either need to disable the ColorPicker on X11 or add support for this functionality. As the X11 platform basically supports selecting a point in the interactive window selection it makes more sense to add this missing method in the platform than to disable support of color picker effect. FIXED-IN: 5.12.1 Test Plan: Run KWin/X11 on Xephyr and was able to pick a color and kill a window Reviewers: #kwin, #plasma Subscribers: plasma-devel, kwin Tags: #plasma Differential Revision: https://phabricator.kde.org/D10302 M +55 -13 plugins/platforms/x11/standalone/windowselector.cpp M +6 -0 plugins/platforms/x11/standalone/windowselector.h M +8 -0 plugins/platforms/x11/standalone/x11_platform.cpp M +1 -0 plugins/platforms/x11/standalone/x11_platform.h https://commits.kde.org/kwin/ea5e70116456975b3ca3f379777b8a83291bb4e8