Support and General Use > Theming and Appearance Customization
(SOLVED)Having no luck with %xl and %xd
KiyoshiKatu:
Alrighty, at this point it is becoming very apparent just how much of a newb I really am. I have successfully made several layout changes with my theme, and have several of the major items in place on the wps (the sbs is going much slower, as I'm just trying to get things working on the wps for now).
I am having some serious issues getting images to load and display while using the %xl and %xd tags in my theme. As far as I can tell, I am getting the syntax correct, and placement isn't an issue (I successfully replaced one set of tags with just plain %x, but using the exact same image, and it displayed fine). However, every time I try to make use of these tags, my wps crashes completely, and Rockbox just loads the default wps in its place.
Here's an example of the code that I am using in attempting to make a volume bar:
--- Code: ---%xl(V,abstract_vol.bmp,0,0,13)
#
<SNIP>
#
%V(1,-10,-,-,1)
%?pv<%xd(Va)|%xd(Vb)|%xd(Vc)|%xd(Vd)|%xd(Ve)|%xd(Vf)|%xd(Vg)|%xd(Vh)|%xd(Vi)|%xd(Vj)|%xd(Vk)|%xd(Vl)|%Xd(Vm)> %pv
--- End code ---
I have tested the viewport location to be at the bottom left corner of the screen, by placing text there with no images, then attempted to add the actual volume bar once location was verified.
It should be noted that I am using the simulator for iPod color/photo off of rasher.dk, and all other tested themes display without issue. I have tried closing and re-opening the simulator, just in case that was causing an issue, to no avail. I doubt it is the simulator; it is far more likely to be my code.
Let me know that you think, thanks!
RockBoxFan:
I am a bit rusty (and was no expert when I wasn't), but a crash to the default wps usually means you have a syntax error.
Why do you have the %pv at the END of the line?
[Saint]:
--- Quote from: RockBoxFan on January 09, 2013, 02:03:37 PM ---Why do you have the %pv at the END of the line?
--- End quote ---
To display the volume in decibels, after the volume bar, which should be absolutely fine.
[Saint]
RockBoxFan:
OK. (My rust is showing...) Then I don't see a problem with the code snippet. Of course, abstract_vol.bmp must exist, have 13 images, fit in the viewport, etc....
KiyoshiKatu:
Interesting. What's really throwing me off is that this isn't the only instance where I'm having issues with loading, and subsequently displaying, images using those tags. Perhaps a bug? Or maybe I should just be patient, and wait to get my hands on a Rockboxed iPod for real life testing.
Navigation
[0] Message Index
[#] Next page
Go to full version