• Status Closed
  • Percent Complete
  • Task Type Patches
  • Category User Interface → Themes
  • Assigned To No-one
  • Operating System All players
  • Severity Medium
  • Priority Very Low
  • Reported Version
  • Due in Version Undecided
  • Due Date Undecided
  • Votes
  • Private
Attached to Project: Rockbox
Opened by gl.tter - 2006-03-08

FS#4802 - WPS Extensions & Fixes.

NOTE: Patch against today’s CVS. All changes can be demoed easily by applying the patch and

    using the attached WPS (use _gl.tter_ext' theme) - or just download my all-inclusive
    precompiled H120/140 firmware:

WPS extensions:

- Designers can now use arbitrary battery & volume segment bitmaps. The code counts the maximum number of enums a WPS uses in those conditionals, and works off that (fully backwards compatible with existing WPS’). Counting mechanism is generic and can easily be applied to future tags (no other current tags are suitable).

- optional Progress Bar y coordinate for bitmap displays - decouples progress bars from lines and allows arbitrary height positioning (fully backwards compatible).

usage: %pb|height|leftpos|rightpos|[y coord|]

- new tags:

  %fk - file frequency in kHz (saves space & is easier to scan).
  %gi - inverted text ('g' = 'graphics effects')

- Experimental: implemented WPS backdrops on iRiver H1x0’s. Seems to work fine, except text and images currently block out the background. Already useful, will most likely extend.
(note, backdrop is not cleared when a new WPS is loaded, this is an existing bug that this patch aims to address - not yet included in my patch).


- adjusted volume level conditional so that the first and last enum are only hit on exactly the first and last volume value - this is desirable and required to display ‘mute/max’ type bitmaps correctly.

- battery conditional now works correctly, eg. when using 5 bitmaps (off + 4 segments), each segment now correctly identifies 25% of battery usage / charging.

(previously this was completely wrong, eg. the 1st segment disappeared at 80%, and all segments were already extinguished at 19%, which is not only nuts but will vary wildly across battery capacities!)

Also the first (’all empty’) enum/bitmap is now triggered when the ‘danger level’ is reached, which is calculated from the estimated remaining battery time (currently set at 15mins). This is far more accurate and should work consistently across all devices / OEM or replacement batteries.

To demo the battery changes more easily, uncomment ‘#define DEBUG_BATTERY_ENUMS’ in ‘gwps_common.c’ - this will simulate fast battery charging / draining, based on whether the charger is connected or not - note the danger level is simulated by <10%. (my precompiled H120/140 firmware already has this enabled).


- bitmap-only sublines fixed (sublines were disabled when only bitmaps ocurred in them, so only the first bitmap was ever shown).

Everything seems to work well.

Closed by  nicolas_p
2007-01-13 02:31
Reason for closing:  Rejected
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

The author refused to give his real name and the patches are now out of date.

Project Manager

Please don’t bundle all these changes into one patch. That makes it very hard for me to apply the enum fix alone.

Some of the changes are interelated, and it makes sense to demo them together (try the WPS).

I’ll seperate the enums & level adjustments out from the rest. However except for the H1x0 backdrops, everything seems solid.

I’ll give it a test run on the H300 Experimental build tomorrow.
You should have reports from all the users in a couple of days.

Great. Note there seems to be a bug in the %X tag, where if the target doesn’t support the backdrop (because it’s the wrong dimensions etc), it writes part of the tag into the line and ruins the demo WPS’ layout. I’ll look into a fix, but if that happens just remove it.

Project Manager

I can imagine that demoing it together might be nice, but some changes might not be wanted in CVS at all. Besides, we’d rather commit one feature at a time, to make it easier for us to keep track of the CVS changes.


Enum (ie. Battery and Volume level) related changes only:

The theme didn’t use the font correctly, fixed one attached (or just select ‘rockbox_default’ font).

Gives a few errors when patching against latest cvs.

The errors are only when patching together with Paprica’s Scrolling Margins patch. Any chance of this collision being solved?

No, just as Linus was about to commit my patch, he then refused it as the project leads won’t accept contributions from pseudonyms. There was a lot of debate on the dev list if you want the details, although the leads didn’t even participate beyond ‘take it or leave it’ comments. So I’m withdrawing my patches (and future improvements) indefinitely - if somebody wants to use them, they’ll have to rewrite them.

Check out why I originally added all this (and now much more) here:


Available keyboard shortcuts


Task Details

Task Editing