
This is what I spent most of yesterday doing…a simple widget which performs a search on my favourite engine.
Much like the firefox plugin it was the graphics which took the time, rather than working out how to get it to work. In the outset it was supposed to just be a simple search box with logo and no frills, but i guess i got carried away and simply had to add something to allow the user to flip it over like a proper widget.
For anyone interested in creating them, they are really simple (although the following paragraph might not be).
The base code is done using xhtml and css to design a layout, this uses javascript for functionality coupled with some dashboard specific functions and librarys. The graphics are simply 24-bit png's and you need one for the front and one for the back…it really is very simple, especially once you find that apple give you most of the code for flipping etc. Then you chuck in a couple of property lists (equivelent of ini's for PC) and an icon image, rename the directory so it has an extension of .wdgt and bobs-your-uncle. You can also referance unix commands, shell scripts and applescript with a widget too…but I didnt really need to head into that jungle for this.
The only really complex bit was making the graphics look ok when surrounded by slick apple-made widgets…oh yeah, and debugging the javascript to make it flip. I later found the problem was in the css…doh!
Download the Widget (.zip, 37kb)
—
Featured on YaGoohoo!gle Blog
Featured on Dashboard Lineup
Featured on dashboardwidgets.com
Featured on Apple Dashboard Downloads (w00t!)
Featured on Dashboard Exposed
Featured on VersionTracker
Featured on AppleWoods (in cantonese)
0 Responses to “YaGoohoo!gle Widget”
Leave a Reply