I’ve just decided to start to work on something called “MicroWidget”. MicroWidget will be the equivalent for mobile of Widget, Gadget, or other inspiration source on the mobile….
Basically, it’s an XML based rendering engine with a tiny scriping language. I’ve used FScriptME as a basis for the scripting language. FScriptME is very limited, but it’s a good start. I’ve added some pseudo object oriented faciclities, like myText.data=”some text”, and some usefull xml parsing function.
As an example, here is the widget code for a Clock like widget:
<img src="/clock2.png" /> <script>< ![CDATA[ func onTimerFired() timeArr=explode(time()," ") hour=explode(timeArr,":") day.data=timeArr secCl.angle =-toint(hour)*360/60+180 minCl.angle =-toint(hour)*360/60+180 hourCl.angle=-toint(hour)*360/12+180 repaint() endfunc ]]> </script>
The code is pretty short and can be easily understood. The only difficulty is the function “explode”, who create an array from a string.
Of course, there are plenty of other usefull function to retrive some xml data, to parse them, etc….
First result are really encouraging, but generate some interesting issue about interface design…