The making of the widget
By Magnus Kristiansen. Monday, 31. July 2006, 16:48:01
Here's how we make the widgets at widgetize.
pet designer reliable designer comrade, that is. But few people have that luxury.
1. Make a widget
This step may seem obvious, but the first and most important step is actually creating a working widget. As a matter of fact, it's even more work than creating a regular widget, since you need to make sure it works on any site, any feed, any crazy username, etc etc.2. Make several independent skins
This usually means making an easily skinned widget. A popular approach is to make a 'base' CSS file with all the positioning and layout, and a second 'skin' CSS file with colors and other skin-specific styling. You're doing it right if you can just delete the old skin folder and copy in a new one, and the widget still works. Of course, the real work is creating the images to be used. Unless you have a3. Create a config.js
Now that we have a working widget, we need to make it flexible. A feed reader needs to be able to take any feed URL as input, and we don't want to go messing around in the JS files for every instance of something that should be changed. Instead, we have a file called config.js. This contains a single JS object, called SkeletonConfig. The object has properties for all the variable variables, so to say. Below is a copy of the config.js from this blog's feed reader widget.var skeletonConfig = {
feedURL : "http://my.opera.com/widgetize/xml/atom/blog/",
feedTitle : "Widgetize! blog",
feedVersion : "generic",
maxItems : 9
};
We have the feed URL, the widget title, the feed type and the maximum number of feed entries to present. 'generic' in this case means the feed parser should detect whether it's getting Atom or RSS.















peteremcc # 2. August 2006, 22:25
then you could group all your feeds by topic into a few widgets, or even have all of them on the sae one.
peter
chesss # 4. August 2006, 04:30
Then the widget would become more like a desktop rss reader.
kdd # 8. August 2006, 02:28
kdd
hzr # 8. August 2006, 08:51
Multiple feeds are currently not planned. However, take a look at http://www.planetplanet.org/ which is a software that combines several feeds into one. Hope that helps.
seifip # 8. August 2006, 15:25
Is it possible to make some analog of Web Clip in Opera so that i could click for example an rss reader, flash movie, or anything else on any website and use it as a widget?? It would be definitely cool...
dalibor42 # 20. July 2007, 13:50
laurentr # 18. August 2009, 14:23