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
| | |-+  Theme breaking changes recently?
« previous next »
  • Print
Pages: [1]

Author Topic: Theme breaking changes recently?  (Read 1745 times)

Offline wintermute23

  • Member
  • *
  • Posts: 116
  • What Would Batman Do?
Theme breaking changes recently?
« on: August 07, 2010, 09:18:49 AM »
I just upgraded from r27477 (18th July) to r27743 (7th August), and the theme I was using stopped working. I can't figure out from the WPS manual what might have changed. Can anyone help? Thanks in advance.

CFG:
Code: [Select]
#Theme:     Fold
#Author:    Ross Thompson
#           wintermute115@gmail.com
#Version:   2.0
#Licence:   CC-SA-BY 3.0
#Created:   2010-06-07
#Target:    iPod Photo
#           320x240x24
#Album Art: 120x120

backdrop: /.rockbox/backdrops/Fold.bmp
sbs: /.rockbox/wps/Fold.sbs
wps: /.rockbox/wps/Fold.wps
font: /.rockbox/fonts/helvR12.fnt
foreground color: FFFFFF
background color: 000066
line selector start color: FFFFFF
line selector end color: FFFF00
line selector text color: 000066
scrollbar: left
selector type: bar (gradient)
statusbar: custom
iconset: default-white_icons.6x8x16.bmp
viewers iconset: default-white_icons.6x8x16.bmp

WPS:
Code: [Select]
#Theme:     Fold
#Author:    Ross Thompson
#           wintermute115@gmail.com
#Version:   2.0
#Licence:   CC-SA-BY 3.0
#Created:   2010-06-07
#Target:    iPod Photo
#           320x240x24
#Album Art: 120x120

#Load images
%Cl(20,45,120,120)
%X(background.bmp)
%xl(r,repeat_strip.bmp,0,7,4)
%xl(s,status_strip.bmp,0,0,4)
%xl(v,vol_strip.bmp,0,3,21)
%xl(S,shuffle.bmp,0,0)
%xl(R,rating_strip.bmp,0,0,10)

#Statusbar icons
%xl(a,batt_strip.bmp,296,0,18)
%xl(c,batt_charge_strip.bmp,296,0,18)
%xl(d,hd_light.bmp,254,-1,2)
%xl(h,Hold.bmp,276,2,2)

#Load font
%Fl(2,helvB14.fnt)

#Turn off standard statusbar
%wd

#Progressbar
%pb(0,182,320,5,progressbar.bmp)

#Load in viewports, based on album art
%?C<%Cd%Vd(a)|%Vd(b)>

#Statusbar
%V(2,1,316,15,1)%Vf(FFFFFF)%Vb(000000)
#Text
%?cf<%cH:%cM:%cS|%cl:%cM%cP>%ac%?mh<Battery: %bl%% (%?bc<Charging|%?bp<On Mains|%bt>>)|%?cu<Monday|Tuesday|Wednesday|Thursday|Friday|Saturday|Sunday> %cd %?cm<January|February|March|April|May|June|July|August|September|October|November|December> %cY>
#Hard drive indicator
%?lh<%xd(db)|%xd(da)>
#Hold switch
%?mh<%xd(ha)|%xd(hb)>
#Battery
%?bp<%?bl<%xd(ca)|%xd(ca)|%xd(cb)|%xd(cc)|%xd(cd)|%xd(ce)|%xd(cf)|%xd(cg)|%xd(ch)|%xd(ci)|%xd(cj)|%xd(ck)|%xd(cl)|%xd(cm)|%xd(cn)|%xd(co)|%xd(cp)|%xd(cq)|%xd(cr)>|%?bl<%xd(aa)|%xd(aa)|%xd(ab)|%xd(ac)|%xd(ad)|%xd(ae)|%xd(af)|%xd(ag)|%xd(ah)|%xd(ai)|%xd(aj)|%xd(ak)|%xd(al)|%xd(am)|%xd(an)|%xd(ao)|%xd(ap)|%xd(aq)|%xd(ar)>>

#Track name - 14pt bold
%V(10,22,300,17,2)%Vf(FFFFFF)%Vb(00007E)
%s%ac%?it<%it|%fm>

####Artist and album
# With Album Art
%Vl(a,160,60,150,30,1) %Vf(FFFFFF) %Vb(00007E)
%s%ac%?ia<%ia|%?d(2)<%d(2)|Artist Unknown>>
%s%ac%?id<%id|%?d(1)<%d(1)|Album Unknown>>
# Without Album Art
%Vl(b,10,60,300,30,1) %Vf(FFFFFF) %Vb(00007E)
%s%ac%?ia<%ia|%?d(2)<%d(2)|Artist Unknown>>
%s%ac%?id<%id|%?d(1)<%d(1)|Album Unknown>>

####Technical
# With Album Art
%Vl(a,160,100,150,40,0)%Vf(C8BFB5)%Vb(00007E)
%s%ac%?ig<%ig|No genre>%?iy< (%iy)|>
%s%ac%fc - %fb kbps%?fv< VBR|>
%s%ac%fs Kb
# Without Album Art
%Vl(b,10,100,300,30,0)%Vf(C8BFB5)%Vb(00007E)
%s%ac%?ig<%ig|No genre>%?iy< (%iy)|>
%s%ac%fc - %fb kbps%?fv< VBR|>
%s%ac%fs Kb

####Rating
# With Album Art
%Vl(a,160,140,150,20,0)%Vf(FFFFFF)%Vb(00007E)
%?rr<|%xd(Ra)|%xd(Rb)|%xd(Rc)|%xd(Rd)|%xd(Re)|%xd(Rf)|%xd(Rg)|%xd(Rh)|%xd(Ri)|%xd(Rj)>
# Without Album Art
%Vl(b,85,140,150,20,0)%Vf(FFFFFF)%Vb(00007E)
%?rr<|%xd(Ra)|%xd(Rb)|%xd(Rc)|%xd(Rd)|%xd(Re)|%xd(Rf)|%xd(Rg)|%xd(Rh)|%xd(Ri)|%xd(Rj)>

#Track times
%V(10,172,300,8,0)%Vf(FFFFFF)%Vb(00007E)
%ac%px%%
%V(10,190,300,8,0)%Vf(FFFFFF)%Vb(00007E)
%al%pc%ac-%pr%ar%pt

#Volume - First line left intentionally blank
%V(247,199,63,16,0)%Vf(FFFFFF)%Vb(00007E)

%?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)|%xd(vn)|%xd(vo)|%xd(vp)|%xd(vq)|%xd(vr)|%xd(vs)|%xd(vt)|%xd(vu)>%ar%pv dB

#Shuffle / repeat
%V(128,202,25,14,0)%Vf(FFFFFF)%Vb(00007E)
%?ps<%xd(S)|>
%?mm<|%xd(ra)|%xd(rb)|%xd(rc)|%xd(rd)>

#Status icon
%V(154,200,15,15,0)%Vf(FFFFFF)%Vb(00007E)
%?mp<|%xd(sa)|%xd(sb)|%xd(sc)|%xd(sd)>

#Song data on main screen; Next data on WPS
%V(2,216,316,15,1)%Vf(FFFFFF)%Vb(00007E)
%s%?It<%Ia - %It|%?Fn<%Fn|Finding next track...>>

#Playlist data
%V(2,232,316,-,0)%Vf(FFFFFF)%Vb(00007E)
%s%ar%?pn<%pn|%d(1)> %?pp<(%pp of %pe)|>

SBS:
Code: [Select]
#Theme:     Fold
#Author:    Ross Thompson
#           wintermute115@gmail.com
#Version:   2.0
#Licence:   CC-SA-BY 3.0
#Created:   2010-06-07
#Target:    iPod Photo
#           320x240x24

#Statusbar icons
%xl(a,batt_strip.bmp,296,0,18)
%xl(c,batt_charge_strip.bmp,296,0,18)
%xl(d,hd_light.bmp,254,-1,2)
%xl(h,Hold.bmp,276,2,2)

#Turn off standard statusbar
%wd

#Statusbar
%V(2,1,316,15,1)%Vf(FFFFFF)%Vb(000000)
%?cf<%cH:%cM:%cS|%cl:%cM%cP>%ac%?mh<Battery: %bl%% (%?bc<Charging|%?bp<On Mains|%bt>>)|%?cu<Monday|Tuesday|Wednesday|Thursday|Friday|Saturday|Sunday> %cd %?cm<January|February|March|April|May|June|July|August|September|October|November|December> %cY>
#Hard drive indicator
%?lh<%xd(db)|%xd(da)>
#Hold switch
%?mh<%xd(ha)|%xd(hb)>
#Battery
%?bp<%?bl<%xd(ca)|%xd(ca)|%xd(cb)|%xd(cc)|%xd(cd)|%xd(ce)|%xd(cf)|%xd(cg)|%xd(ch)|%xd(ci)|%xd(cj)|%xd(ck)|%xd(cl)|%xd(cm)|%xd(cn)|%xd(co)|%xd(cp)|%xd(cq)|%xd(cr)>|%?bl<%xd(aa)|%xd(aa)|%xd(ab)|%xd(ac)|%xd(ad)|%xd(ae)|%xd(af)|%xd(ag)|%xd(ah)|%xd(ai)|%xd(aj)|%xd(ak)|%xd(al)|%xd(am)|%xd(an)|%xd(ao)|%xd(ap)|%xd(aq)|%xd(ar)>>

#Main Viewport
%Vi(z,0,17,320,189,1)%Vf(FFFFFF)%Vb(00007E)
%VI(z)

#Song data on main screen; Next data on WPS
%V(2,216,316,15,1)%Vf(FFFFFF)%Vb(00007E)
%s%?it<%ia - %it|%?fn<%fn|No current track>>

#Playlist data
%V(2,232,316,-,0)%Vf(FFFFFF)%Vb(00007E)
%s%?fm<%al%pc/%pt %ar%?pn<%pn|%d(1)> %?pp<(%pp of %pe)|>|>
Logged
Past: iRiver H320 w/ 32GB CF card mod; iPod 4th Gen 30GB; iPod 5th Gen 30GB

Present: iPod Classic 80GB

Offline [Saint]

  • Rockbox Expert
  • Member
  • *
  • Posts: 1662
  • Hayden Pearce
    • Google+
Re: Theme breaking changes recently?
« Reply #1 on: August 07, 2010, 10:33:19 AM »
The problem appears to be with lines like:

Code: [Select]
%s%ar%?pn<%pn|%d(1)> %?pp<(%pp of %pe)|>

When something is intended to be displayed inside brackets, ie. "(1 of 2)" then:

Code: [Select]
%s%ar%?pn<%pn|%d(1)> %?pp<%(%pp of %pe%)|>

Needs to be used instead.

There are a few other lines like this in the theme, this is simply an example.
In the .wps, lines 41, 66, 71 and 109 (the above example) are affected.

I hope this helps.



[St.]
« Last Edit: August 07, 2010, 10:36:20 AM by [St.] »
Logged
Using PMs to annoy devs about bugs/patches is not a good way to have the issue looked at.

Offline wintermute23

  • Member
  • *
  • Posts: 116
  • What Would Batman Do?
Re: Theme breaking changes recently?
« Reply #2 on: August 07, 2010, 11:52:59 AM »
Ah, that is a sensible change, and now it works properly.

Thanks for the help.

Edit: I've just noticed that, while everything else seems to be fine, the progressbar isn't showing up. Any ideas on that one?

Edit 2: After a little reverse engineering, I've worked out that it needs to be in a viewport. So now everything seems to be working.

Thanks.
« Last Edit: August 07, 2010, 12:13:04 PM by wintermute23 »
Logged
Past: iRiver H320 w/ 32GB CF card mod; iPod 4th Gen 30GB; iPod 5th Gen 30GB

Present: iPod Classic 80GB

  • Print
Pages: [1]
« previous next »
+  Rockbox Technical Forums
|-+  Support and General Use
| |-+  Theming and Appearance Customization
| | |-+  Theme breaking changes recently?
 

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

Page created in 0.065 seconds with 15 queries.