Progress Bars
• Progress bar from 100 (sunrise) to 0 (sunset::
$if(ai(isday)=1, 100 / tf(ai(sunset) - ai(sunrise), S) * tf(ai(sunset), S), 0)$
This will print 100 at surise and 0 at sunset, 50 at mid of the day
• In circle shape - Create a circle
- Set gradient to "sweep"
- Set width to 1
- Set gradient color to transparent
- Offset will go from 0 (empty circle) to 100 full circle filling it, you can then use a formula in the offset to associate this with the battery (simply using $bi(level)$ will work)
• flat battery progress:
1 Add a rect
2 Set FX Texture to vertical or horizontal gradient
3 Set "width" to 1
4 Turn offset into a formula and type "$bi(level)$ inside
• a bar and a moving circle to act as a progress?
1 Create an Overlap Group to contain both
2 Create a "bar" of width 400
*3" Create a circle, set its anchor to "left"
4 Turn left padding into a formula and use (for battery for example) $400/100*bi(level)$ for music: $100/mi(len)*mi(pos)$
• Make negative numbers positive: *-1