Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bind is not possible #2

Open
fedorovenskiy opened this issue Sep 6, 2019 · 6 comments
Open

bind is not possible #2

fedorovenskiy opened this issue Sep 6, 2019 · 6 comments

Comments

@fedorovenskiy
Copy link

it is not possible to bind this effect, and this is very important to not open system settings every time I need to disable|enable this function

@RokeJulianLockhart
Copy link

RokeJulianLockhart commented Feb 19, 2022

#2 (comment)

@fedorovenskiy, what does binding refer to in this context?

@gearcoded
Copy link

@BEEDELLROKEJULIANLOCKHART,
I suppose it means that you can login, and the effect will be active right from the start.
But I don't yet know how to do that.

@RomanMunar
Copy link

here's a solution If what you mean by bind is a way to toggle the effect through a keyboard shortcut. i'm on kde 5.27.5.
the terminal command for toggling it.
qdbus org.kde.KWin.Effect.WindowView1 /Effects org.kde.kwin.Effects.toggleEffect kwin4_effect_grayscale

  1. Go here and click Command/url
    Screenshot_20230716_185209
  2. Copy qdbus org.kde.KWin.Effect.WindowView1 /Effects org.kde.kwin.Effects.toggleEffect kwin4_effect_grayscale in the Action tab and on the Trigger tab add your shortcut key.

@kaBeech
Copy link

kaBeech commented Jan 3, 2024

here's a solution

I was looking for this answer in theory, but that command returned Cannot find 'org.kde.kwin.Effects.toggleEffect' in object /Effects at org.kde.KWin.Effect.WindowView1 for me.

Here's what worked for me:

  • Create a filename.sh with the following code:
#!/bin/bash
greyscaleEnabled=$(kreadconfig5 --file ~/.config/kwinrc --group Plugins --key kwin4_effect_grayscaleEnabled)
kwriteconfig5 --file ~/.config/kwinrc --group Plugins --key kwin4_effect_grayscaleEnabled $((!$greyscaleEnabled))
sleep 0.2
qdbus org.kde.KWin /Compositor suspend
qdbus org.kde.KWin /Compositor resume
  • Put sh path/to/filename.sh in the Action tab mentioned above

Thank you to @RomanMunar and to iceman7789 from the comments at the KDE Store for helping me get to a solution that worked with my setup!

@RomanMunar
Copy link

Yeah would add that I had installed mine manually(instruction on README) and not from the KDE store 👍️

@kaBeech
Copy link

kaBeech commented Jan 3, 2024

Yeah would add that I had installed mine manually(instruction on README) and not from the KDE store 👍️

Oh yeah, me too. I only found out that it was on the KDE Store when I was searching for shortcut solutions. I think it should work either way though.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants