![]() I have been playing with the language and Django lately so, if improvements could be made, please let me know. Please note: I am not extremely well-versed in Python. While searching around for the original source, I found out that the project I grabbed from was originally based on a different script, which I think is worth mentioning. I also wanted to start with a number of images so I would actually have some to scroll through. From there, I got a hold of lxml and went to town.īut, generating the XML file wasn't enough. I found the XML file that comes with Ubuntu in /usr/share/backgrounds/contest/precise.xml that is used to create the background scrolling. Yes, the filesize is increased quite a bit but we remove the artifacts and get a much cleaner image.Īfter I modified the original script, I still wanted to allow for the image scrolling to return. Checked to see if the file already existed before performing the download.Added debugging information to see what's going on.Instead of appropriately scaling the image based on the size and placing it on a black background, I wanted the image to be scaled to the size I specified no matter what so I didn't have distracting vertical lines.I just wanted an image, no text as I live in a semi-transparent terminal most of the time. There were a few changes that I thought were necessary: I eventually found a mirror and took a look at the code. Searching around in Google, I came across the apodbackground project. I wanted to recreate the experience for Ubuntu as I don't use Windows 7 at home, much. I really enjoyed the NASA background images that were easily available in Windows 7. It's not very exciting to scroll through a single image, so it will attempt to download additional images (default: 10) to seed your list of images. Adds image to XML file used to scroll through desktop background images.Resizes the image to the given resolution.Determines your desktop resolution, or uses the set default.Downloads the latest image of the day from NASA ( ).Tested on, and created for, Ubuntu 12.04. This script will download the NASA APOD and set it as your background in Ubuntu. The popular NASA Astronomy Picture of the Day produces wonderful images that make for a great desktop background. Nasa-apod-desktop Python Script to Download the NASA APOD and Set it as Your Background for Ubuntu About:
0 Comments
Leave a Reply.AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |