Welcome to the Rockbox Technical Forums!
http://www.rockbox.org/wiki/CustomWPS%bl Show numeric battery level in percent. Can also be used in a conditional: %?bl(-1|0|1|2|...|N) where the -1 value is used when the battery level isn't known (it usually is). Means:%bl(load,empty,step1,step 2, ...,full)You used:%?bl<|%xd(Db)|%xd(Dc)|%xd(Dd)|%xd(De)|%xd(Df)|%xd(Dg)|%xd(Dh)|%xd(Di)|%xd(Dj)>So you droped exactly the responsible part of your stripped image for the loading.So I assume (but I don't know your battery.bmp) that you need to use:%?bl<%xd(Da)|%xd(Db)|%xd(Dc)|%xd(Dd)|%xd(De)|%xd(Df)|%xd(Dg)|%xd(Dh)|%xd(Di)|%xd(Dj)>
The "right" way to represent charging can be simplified to:%?bp<%?bc<%xd(we're_charging)|%xd(we've_charged)>|%?bl(0,0,-,-,battery_state.bmp)>[Saint]
Quote from: [Saint] on November 07, 2011, 09:38:27 AMThe "right" way to represent charging can be simplified to:%?bp<%?bc<%xd(we're_charging)|%xd(we've_charged)>|%?bl(0,0,-,-,battery_state.bmp)>[Saint]Ok but, what if I want to get (charging/charged) on the same part of bitmap?#Battery%?bp<%?bc<%xd(Da)>|%?bl<|%xd(Db)|%xd(Dc)|%xd(Dd)|%xd(De)|%xd(Df)|%xd(Dg)|%xd(Dh)|%xd(Di)|%xd(Dj)>>Which means:Battery power if charging [don't matter if the battery is charging or charged (%?bc)] show first part,if not, show other parts equal to the battery power.So at all what should be look like the right code (with my solution)? Because with your way need to declare 2 times the battery bitmap:%xl(D,battery.bmp,7,3,10)%?bp<%?bc<%xd(Da)|%xd(Db)>|%?bl(0,0,-,-,Battery.bmp)>
Want to:Show first upper part (battery with lightning), when device is plug in (doesn't matter if it's charged or charging).
%?bp<%xd(Da)|%?bl<%xd(Db)|%xd(Db)|%xd(Dc)|%xd(Dd)|%xd(De)|%xd(Df)|%xd(Dg)|%xd(Dh)|%xd(Di)|%xd(Dj)|%xd(Dj)>>
%?bp<%xd(Da)|%?if(%bl,<,6)<%t(.5)%xd(Db);%t(.3)%xd(Da)|%?bl<|%xd(Db)|%xd(Dc)|%xd(Dd)|%xd(De)|%xd(Df)|%xd(Dg)|%xd(Dh)|%xd(Di)|%xd(Dj)|%xd(Dj)>>>
Page created in 0.156 seconds with 21 queries.