spedinfargo wrote: 
> Curious if there is any simple programability or custom formatting, etc.
> that can be done to specific values before displaying them.
> 
> For instance, in the Weather applet there is an observation time
> "%observation_epoch" that shows how old the observation is. 
> Unfortunately this is reported as an epoch (seconds since x date?) which
> isn't really useful to display.  What would be cool would be able to do
> something with that - either as simple as calculating it to "42 minutes
> ago" or maybe something even move clever like changing the font color of
> the temperature to yellow or red depending on how "stale" the reading
> is.
> 
No there is no such functionality at the moment.

spedinfargo wrote: 
> 
> For that matter, being able to do custom formatting or calculations of
> any of the values would be pretty powerful (I'm thinking something along
> the lines of Excel formulas for instance).  Or else being able do a
> sprintf or String.Format around it (or maybe run it through a regex??).
> 
If you are a developer, you can take a look at
/usr/share/jive/applets/CustomClockApplet.lua  file and search for
"applettext" where you will find the call to setWidgetValue which sets
the value shown on the screen. If you want to do any formatting it
should probably happen in this code section.

Note, I only recommend you to try to edit the code if you are a
developer, if you don't know any development the risk of messing
something up is too big.

If you make a generic change that works, I can consider including it in
future versions of the distribution.

Another, much easier alternative, might be to change the code in the
Weather applet so it expose the value you want to show.


------------------------------------------------------------------------
erland's Profile: http://forums.slimdevices.com/member.php?userid=3124
View this thread: http://forums.slimdevices.com/showthread.php?t=68269

_______________________________________________
plugins mailing list
[email protected]
http://lists.slimdevices.com/mailman/listinfo/plugins

Reply via email to