- Status Closed
- Percent Complete
- Task Type Patches
- Category User Interface → Themes
- Assigned To No-one
- Operating System All players
- Severity Low
- Priority Very Low
- Reported Version Version 3.1
- Due in Version Undecided
-
Due Date
Undecided
- Votes
- Private
FS#9710 - Draw numbers from a bmp strip in the WPS
This patch adds a new tag to the WPS which will draw the next tag as a combination of numbers from a bmp strip.
http://imagebin.ca/view/8i4Iy7.html is a pretty bad example of what it can do. The first line is just converting the number 12345 to images (12345 is text in the wps), the 2nd line is the track complete percent (%px)
ok, how to use it:
First you HAVE to have a bmp strip loaded with %x or %xl. This strip is a verticle strip split into 10 cells.. 0 at the top, 9 at the bottom. They must al be the same height and width. (I’ve attached my really bad test bmp, test.wps and the patch)
after that, add up to 5 %xn lines in the format “%xn|id|x|y|<next tag>” where id is the bmp’s id, x,y is the x and y pixel coordinate (relative to the current viewport) to start drawing in.
<next tag> MUST be immediately after the last |, NO SPACES!
There is some limitation on which tags will work and which wont, but anything which will ordinarily display a number should work, and some conditionals will work also.
Like in the display, you can use this to draw a static number (although i’m not ure why you would want to?)
Lastly… Llorean has suggested I add the ‘:’ character to the strip… I’m happy to do that if its going to be useful, and a few other chars if needed. I dont want to add too many though (and I’m not going to add any letters… this is not a multifont replacement)
let me know what you think
2010-06-03 04:16
Reason for closing: Out of Date
Additional comments about closing: Warning: Undefined array key "typography" in /home/rockbox/flyspray/plugins/dokuwiki/inc/parserutils.php on line 371 Warning: Undefined array key "camelcase" in /home/rockbox/flyspray/plugins/dokuwiki/inc/parserutils.php on line 407
multifont is better!
Loading...
Available keyboard shortcuts
- Alt + ⇧ Shift + l Login Dialog / Logout
- Alt + ⇧ Shift + a Add new task
- Alt + ⇧ Shift + m My searches
- Alt + ⇧ Shift + t focus taskid search
Tasklist
- o open selected task
- j move cursor down
- k move cursor up
Task Details
- n Next task
- p Previous task
- Alt + ⇧ Shift + e ↵ Enter Edit this task
- Alt + ⇧ Shift + w watch task
- Alt + ⇧ Shift + y Close Task
Task Editing
- Alt + ⇧ Shift + s save task
hmm… it looks like this is going to need some thought as to how to handle tokens that return numbers proberly… just had a look at the volume tag and I’m pretty sure this wont work at all for it, ideas welcome
updated patch and text.wps.
format: %dn|n|m|x|y|abc
new version… sacrifice 8 bytes per number grouping so the bmp is redrawn only if the number to draw changes.
edit2: reupped the diff.. this one actually works
hopefully final version.. this one draws the bmp using the transparent bmp drawing function on 16bit lcds so the 2 magic colours work (255,255,0 and 255,0,255)
I’ve tried this patch for both the iPod video and the iPod mini, and in both cases I get a data abort crash when the .wps containing the %xn tag is loading. Also, in both cases the patch works fine when used for the simulator build.