Closed luisbocanegra closed 11 months ago
So there is this KWin plugin https://github.com/KDE/kwin/tree/master/src/plugins/screenshot which is used to take screenshots by Spectacle. After reading https://github.com/KDE/kwin/blob/master/src/plugins/screenshot/org.kde.KWin.ScreenShot2.xml and a bit of trial and error 😆 managed to get a POC script working 🎉
Testing is needed to ensure this works as expected for the new release:
First clone and run the main branch
git clone https://github.com/luisbocanegra/kde-material-you-colors
export PYTHONPATH=/home/luis/projects/kde-material-you-colors/src:$PYTHONPATH
python -m kde_material_you_colors.main
Try setting different wallpaper plugins that are not supported in previous releases like "Hunyango" and it should pick the colors from it.
To control how often screenshots are taken please refer to the end of the sample configuration file https://github.com/luisbocanegra/kde-material-you-colors/blob/main/src/kde_material_you_colors/data/sample_config.conf
Is your feature request related to a problem? Please describe. Currently, the current wallpaper information is obtained using Plasma Scripting API, but only works if the wallpaper plugin itself stores the value of the current wallpaper (like an image path or color)
Describe the solution you'd like Find a way to grab a screenshot of the desktop view
Todo
Additional context BUG:449986 - Spectacle: New capture mode: Window by properties