Rockbox.org home
Downloads
Release release
Dev builds dev builds
Extras extras
themes themes
Documentation
Manual manual
Wiki wiki
Device Status device status
Support
Forums forums
Mailing lists mailing lists
IRC IRC
Development
Bugs bugs
Patches patches
Dev Guide dev guide
Search



Donate

Rockbox Technical Forums


Login with username, password and session length
Home Help Search Staff List Login Register
News:

Welcome to the Rockbox Technical Forums!

+  Rockbox Technical Forums
|-+  Support and General Use
| |-+  Theming and Appearance Customization
| | |-+  BROKEN THEMES: CHECK %P, %pb %m AND CustomWPS wiki page
« previous next »
  • Print
Pages: [1]

Author Topic: BROKEN THEMES: CHECK %P, %pb %m AND CustomWPS wiki page  (Read 16411 times)

Offline JdGordon

  • Member
  • *
  • Posts: 1817
  • Constantly breaking stuff
BROKEN THEMES: CHECK %P, %pb %m AND CustomWPS wiki page
« on: July 02, 2008, 11:28:08 AM »
it appears I closed the previous stick too early...

%P %pb and %m have all been changed recently so if your WPS isnt loading its most likely because of that...

http://www.rockbox.org/twiki/bin/view/Main/CustomWPS
http://www.rockbox.org/twiki/bin/view/Main/CustomWPS
http://www.rockbox.org/twiki/bin/view/Main/CustomWPS

(for the lazy)

%P and %m have been removed

%pb is now %pb|bmp|x|y|width|height| or just %pb

use viewports and conditional viewports to replace %m

For crying out loud... yes its the same link above 3 times... I could have made it 4 and I could have made it 1... I purposly chose 3... why? we'll never know, im an enigma.. but its 3, and will remain 3... which also happens to be the same amount of times its been discussed in IRC... what is so special about the number 3?
« Last Edit: October 26, 2008, 02:18:18 AM by JdGordon »
Logged


Using PMs to annoy devs about bugs/patches is not a good way to have the issue looked at.

Offline pondlife

  • Developer
  • Member
  • *
  • Posts: 248
Re: BROKEN THEMES: CHECK %P, %pb %m AND CustomWPS wiki page
« Reply #1 on: July 24, 2008, 07:45:08 AM »
As jswetzen said elsewhere:

Quote
The old format was:
%P|filename.bmp|
%pb|height|left-position|right-position|y-position(optional)|

and the new one is:
%pb|filename.bmp|x|y|width|height|

which means that:
x = left-position
y = y-position
width = right-position - left-position
height = height
and the filename is copied from the %P tag.

Please upload your corrected WPSes to the wiki.

pondlife
« Last Edit: July 24, 2008, 07:46:57 AM by pondlife »
Logged

Offline JdGordon

  • Member
  • *
  • Posts: 1817
  • Constantly breaking stuff
Re: BROKEN THEMES: CHECK %P, %pb %m AND CustomWPS wiki page
« Reply #2 on: September 09, 2008, 04:40:33 AM »
removed the sticky but bumping to keep this on the front page for a little while longer.
Hopefully everyone has got the point by now :p
Logged


Using PMs to annoy devs about bugs/patches is not a good way to have the issue looked at.

Offline mmadia

  • Member
  • *
  • Posts: 14
Re: BROKEN THEMES: CHECK %P, %pb %m AND CustomWPS wiki page
« Reply #3 on: September 19, 2008, 10:00:06 PM »
any chance of getting an example for rewriting a %m line in the new syntax?
Logged

Offline Boofus

  • Member
  • *
  • Posts: 2
Re: BROKEN THEMES: CHECK %P, %pb %m AND CustomWPS wiki page
« Reply #4 on: September 19, 2008, 10:19:00 PM »
or maybe at least an explanation of what the old %m syntax was??  I can't find it anywhere in the docs.

Boo
Logged

Offline Llorean

  • Member
  • *
  • Posts: 12931
Re: BROKEN THEMES: CHECK %P, %pb %m AND CustomWPS wiki page
« Reply #5 on: September 19, 2008, 10:39:36 PM »
The CustomWPS wiki page has the new syntax, and you can view older versions of it from the controls at the bottom of the page to get back to the previous syntax.
Logged

Offline BdN3504

  • Artist
  • Member
  • *
  • Posts: 323
Re: BROKEN THEMES: CHECK %P, %pb %m AND CustomWPS wiki page
« Reply #6 on: September 20, 2008, 10:04:12 AM »
The %m teg was used to define scrolling margins.
Example:

%s%m|25|151| Disaster is coming.

This would display "Disaster is coming." beginning at 25 pixels on the left and cut it off at 151 pixels on the right and then start scrolling. This tag is obsolote because you can do scrolling with viewports now.
To get the same results, you simply have to create a viewport with similar dimensions.
E.g.:

%V|25|10|126|12|-|-|-|
%sDisaster is coming.

126=151-25

The y position of the viewport is arbitrary. You have to try out some values, to see, if the line with the %m tag is on the same level as the viewport.
Logged

Offline Boofus

  • Member
  • *
  • Posts: 2
Re: BROKEN THEMES: CHECK %P, %pb %m AND CustomWPS wiki page
« Reply #7 on: September 20, 2008, 06:04:41 PM »
Thanks to both you, VERY much

Boo
Logged

Offline mmadia

  • Member
  • *
  • Posts: 14
Re: BROKEN THEMES: CHECK %P, %pb %m AND CustomWPS wiki page
« Reply #8 on: September 20, 2008, 07:36:14 PM »
Thank you.   

If anyone is curious, %m Margin Tag is last documented in CutomWPS's revision #107 
http://www.rockbox.org/twiki/bin/view/Main/CustomWPS?rev=107#Margin

Now just to beat a dead horse, are the following still in use?
 Hold Switches ( %mh, %mr), 
 Repeat Mode ( %mm ), and
 Playback Mode (%mp )
Logged

Offline Llorean

  • Member
  • *
  • Posts: 12931
Re: BROKEN THEMES: CHECK %P, %pb %m AND CustomWPS wiki page
« Reply #9 on: September 20, 2008, 08:47:41 PM »
None of those were mentioned as changed.
Logged

Offline mmadia

  • Member
  • *
  • Posts: 14
Re: BROKEN THEMES: CHECK %P, %pb %m AND CustomWPS wiki page
« Reply #10 on: September 20, 2008, 09:14:19 PM »
Gotcha.  I wanted to make sure as those tags do have a %m in them. 

( and yes, i understand now that those tags are wholly unrelated to margin tags  )
Logged

Offline pixelma

  • Rockbox Expert
  • Member
  • *
  • Posts: 645
Re: BROKEN THEMES: CHECK %P, %pb %m AND CustomWPS wiki page
« Reply #11 on: October 01, 2008, 07:45:46 PM »
Quote from: BdN3504 on September 20, 2008, 10:04:12 AM
The %m teg was used to define scrolling margins.
Example:

%s%m|25|151| Disaster is coming.

[colours changed to stress something.]

Note that this second red number (including the additional "|") was never a valid variable in official Rockbox, the "official" margin tag only let you set a left margin. There was a patch though for specifying a right margin too and it was used in some unsupported builds and themes. So you would have to caclulate with the screen width minus the left margin to get the viewports width if you have a margin tag with only the left margin specified and want to mimic this old behaviour or as maximum width.
Logged

Offline karashata

  • Rockbox Expert
  • Member
  • *
  • Posts: 603
  • Just a fluffy dragon with too much time on my paws
    • Alex Vanderpol (karashata) on Twitter
Re: BROKEN THEMES: CHECK %P, %pb %m AND CustomWPS wiki page
« Reply #12 on: October 01, 2008, 08:09:59 PM »
I believe the viewports were designed to automatically assume the width and height as "LCD width - x-pos" and "LCD height - y-pos" in absence of width and height definitions...
Logged
Welp, my iriver H10 20GB is out of commission again.

Offline kugel.

  • Developer
  • Member
  • *
  • Posts: 271
Re: BROKEN THEMES: CHECK %P, %pb %m AND CustomWPS wiki page
« Reply #13 on: October 04, 2008, 07:21:46 AM »
True, with absence being a "-" instead of a value. This also applies for the font and color parameters.
Font will be normal font (as if you've chosen 1 as value), colors will default to global settings fore- and background color.
E.g. %V|23|10|-|-|-|-|-|
Logged
 

Offline pixelma

  • Rockbox Expert
  • Member
  • *
  • Posts: 645
Re: BROKEN THEMES: CHECK %P, %pb %m AND CustomWPS wiki page
« Reply #14 on: October 11, 2008, 07:10:53 AM »
Quote from: karashata on October 01, 2008, 08:09:59 PM
I believe the viewports were designed to automatically assume the width and height as "LCD width - x-pos" and "LCD height - y-pos" in absence of width and height definitions...
Right, I'm sorry, somehow forgot about it. But calculating this for yourself can still be helpful if you want to know the maximum width or as a basis to calculate a slightly smaller viewport width... ;)

Quote from: pondlife on July 24, 2008, 07:45:08 AM
As jswetzen said elsewhere:

Quote
The old format was:
%P|filename.bmp|
%pb|height|left-position|right-position|y-position(optional)|

and the new one is:
%pb|filename.bmp|x|y|width|height|
To add: in the old format all arguments were optional, e.g. you could only specify a different height for your progress bar and the rest was taken from the default. But you had to keep the order, I mean that if you wanted only the y-position to be different, you had to specify everything else before it (height, left-position, right-position) - couldn't have worked otherwise. This is still possible with the new syntax, only that you use a "-" now, where you don't want anything else than the default. See also http://forums.rockbox.org/index.php?topic=18967.msg136930#msg136930 .
Logged

  • Print
Pages: [1]
« previous next »
+  Rockbox Technical Forums
|-+  Support and General Use
| |-+  Theming and Appearance Customization
| | |-+  BROKEN THEMES: CHECK %P, %pb %m AND CustomWPS wiki page
 

  • SMF 2.0.17 | SMF © 2019, Simple Machines
  • Rockbox Privacy Policy
  • XHTML
  • RSS
  • WAP2

Page created in 0.171 seconds with 21 queries.