![]() Registered Member ![]()
|
I want to have my desktop background as a solid color. This can be done using the plasma configuration tool however I want to do this from a script.
I have seen code such as below that changes the wallpaper #!/bin/sh js=$(mktemp) cat > $js <<_EOF var wallpaper = "$1"; var activity = activities()[0]; activity.currentConfigGroup = new Array("Wallpaper", "image"); activity.writeConfig("wallpaper", "/usr/share/wallpapers/myimage.jpg"); activity.reloadConfig(); _EOF qdbus org.kde.plasma-desktop /App local.PlasmaApp.loadScriptInInteractiveConsole "$js" > /dev/null xdotool search --name "Desktop Shell Scripting Console - Plasma Desktop Shell" windowactivate key ctrl+e key ctrl+w rm -f "$js" What do I need to alter to have a solid color background instead of a wallpaper image. |
![]() Administrator ![]()
|
The change you need to make is to swap the following lines:
For these instead:
You should change the values 0,0,0 to the values you need (I suspect these are R,G,B values ranging from 0-255 but cannot confirm this). You should be able to use "kdialog --getcolor" to help you determine the values you need.
KDE Sysadmin
[img]content/bcooksley_sig.png[/img] |
Registered users: Bing [Bot], Evergrowing, Google [Bot], rockscient