Title. Plasma 6 just dropped on my arch-based distro, and it came with an option for a colorblindness correction filter:

Neat little tool that my Protanope ass was very excited about, and it works.

The thing is.

Some time ago Windows also introduced one of those, and in Windows, you can turn it on and off with a key-combination shortcut. I use that a lot on Windows, to keep the filter off and turn it on just when it is necessary (look, every person experiences colorblindness differently, and on my end, these filters while useful for certain kinds of work, are very ugly most other times)

Now, I already know I can set a key-combination shortcut to a terminal command on plasma. Easy peasy.

But for me to do that on plasma I’d need to have a way to switch the effect on and off from the terminal.

I know that I can do systemsettings kcm_kwin_effects to launch the configs app straight into the relevant tab. But now I’m wondering if I could make that even more automatic, maybe using the --args thing, which apparently is literally meant for sending commands directly to the configuration module. But then I wouldn’t know what the command is.

  • Count Regal Inkwell@pawb.socialOP
    link
    fedilink
    English
    arrow-up
    1
    ·
    8 months ago

    I figured it out. After another comment mentioned qdbus, I realised I had qdbusviewer, so I ran that and fucked around in it looking at the services and methods from them and trial-and-erroring for a bit

    And I found the command I needed to make it happen. It’s a single command too, no need for scripts:

    It’s: qdbus6 org.kde.KWin /Effects toggleEffect colorblindnesscorrection

    It was under Effects rather than Plugins