![]() Registered Member ![]()
|
Hi,
I was considering switching from Gnome to Kde, but I did some research and I saw that there was no way to change kde's wallpaper through scripting (like Perl) right when KDE 4.0 was released. I made a Perl script to periodically change my wallpaper and I would like to still use it. I was wondering if there is now a way to easily change it programatically. tnx. |
![]() Registered Member ![]()
|
If you set your wallpaper to be "Slideshow" type, then your image will change periodically. You can set any number of directories for KDE to search for images.
But without knowing what your script is doing, I can't tell if this setting will address all your needs.
Best regards
Mirosław Zalewski |
![]() Registered Member ![]()
|
Hi Minio, Tnx for your reply. My question is pretty straight. Can you make a perl script that invokes a dbus command and sets a wallpaper? For instance, in Gnome 3 you have a one liner where u call Gsettings and pass the path to your image. Also in KDE 3 u could do that with DCOP. There is also this bug report that is 3 years old that reports this but it seems no one took care of it. https://bugs.kde.org/show_bug.cgi?id=217950 it doesnt make any sense to me... how can you change a desktop only through GUI? Not even Windows is that weird... tnx |
![]() Registered Member ![]()
|
Yes, question is pretty straight. But the point is, sometimes precise questions implies wrong approach to solving real problem. That's why you should tell where you want to be and ask how to get there. If your real problem is (and judging from your post, I believe it is) "I have this bunch of photos and I want them to be on background, changed periodically", then KDE provides everything you need. You may forget about this perl script you have. Under KDE, you won't need it anymore. But if your problem is "I have this script that downloads some random image from wallpapers website; how do I put it on background without invoking GUI?", then I there is no simple way that I am aware of. You can use this command
(group number may be different on your machine; check ~/.kde/config/plasma-desktop-appletsrc) to set up new wallpaper. But it seems that KDE will cache current one. If you want it to change background, you must… restart plasma. Rather extreme solution, if you ask me. Yes, this issue has been raised since first release of KDE SC 4.0. Yes, it seems that it hasn't been solved yet. This thread: http://git.reviewboard.kde.org/r/1798/ may give you some insight on what developers (used to?) think about this. Hopefully someone knows something about this issue that I do not and will help you solving your problem.
Best regards
Mirosław Zalewski |
![]() Administrator ![]()
|
I would suggest following the script which is given here instead as this uses native Plasma methods to perform the change - and as a result is safer and more reliable.
viewtopic.php?f=64&t=109437&p=256319#p256319
KDE Sysadmin
[img]content/bcooksley_sig.png[/img] |
Registered users: Bing [Bot], Google [Bot], kde-naveen, Sogou [Bot]