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
| | |-+  Display month name in WPS?
« previous next »
  • Print
Pages: [1]

Author Topic: Display month name in WPS?  (Read 4437 times)

Offline RowaN

  • Member
  • *
  • Posts: 90
Display month name in WPS?
« on: May 07, 2007, 04:51:41 PM »
With the recent changes to RTC stuff in Rockbox, I'm trying to sync my WPS, but having problems with month (and day). It returns a number now instead of the name (e.g. 1 instead of January). From what I could gain from reading the WPS wiki page on conditionals, I tried:

Quote
%?cm(January|February|March|April|May|June|July|August|September|October|November|December)
[I have replaced the V-shaped brackets with normal brackets in the above line because this forum was not displaying them properly.]

..but that doesnt seem to work. I also looked through many pages of existing WPS but couldnt find any that show the month name. Can someone shed some light on this for me please?
« Last Edit: May 08, 2007, 12:28:53 PM by RowaN »
Logged

Offline ColdSphinx

  • Member
  • *
  • Posts: 147
Re: Display month name in WPS?
« Reply #1 on: May 08, 2007, 11:41:13 AM »
Is it necessari for you that the monthname is comlete shown like "January"?
If not you could use:
Code: [Select]
%cb - abbreviated month name (Jan..Dec)



Quote from: RowaN on May 07, 2007, 04:51:41 PM
It returns a number now instead of the name (e.g. 1 instead of January)
It returns "01" for January.
« Last Edit: May 08, 2007, 11:42:56 AM by ColdSphinx »
Logged
Rockbox.src

Offline RowaN

  • Member
  • *
  • Posts: 90
Re: Display month name in WPS?
« Reply #2 on: May 08, 2007, 12:26:43 PM »
Yes, I am trying to display the month name, not an abbriviation. Is it possible? Why is my conditional tag not working?
Logged

Offline ColdSphinx

  • Member
  • *
  • Posts: 147
Re: Display month name in WPS?
« Reply #3 on: May 08, 2007, 12:51:04 PM »
It's an bug caused by the formating. 01,02,03,04,..,10,11,12
Logged
Rockbox.src

Offline RowaN

  • Member
  • *
  • Posts: 90
Re: Display month name in WPS?
« Reply #4 on: May 08, 2007, 04:38:23 PM »
Thanks for info. I've added it as a bug here:
www.rockbox.org/tracker/task/7133
Logged

Offline NicolasP

  • Developer
  • Member
  • *
  • Posts: 195
Re: Display month name in WPS?
« Reply #5 on: May 08, 2007, 04:56:36 PM »
The fact that your conditional doesn't work isn't caused by the leading zero. It's because the RTC tags aren't currently meant to be used as conditionals. It's not hard to fix but I'm not sure it's worth the added code size.
Logged

Offline Lear

  • Developer
  • Member
  • *
  • Posts: 533
Re: Display month name in WPS?
« Reply #6 on: May 09, 2007, 03:59:19 AM »
Setting intval in a couple of places shouldn't add much code...
Logged

Offline NicolasP

  • Developer
  • Member
  • *
  • Posts: 195
Re: Display month name in WPS?
« Reply #7 on: May 21, 2007, 08:55:12 AM »
Done.
Logged

Offline RowaN

  • Member
  • *
  • Posts: 90
Re: Display month name in WPS?
« Reply #8 on: May 21, 2007, 05:18:43 PM »
My example code still doesnt work, even after your commit. Can you give some example code that works please?
« Last Edit: May 21, 2007, 05:24:43 PM by RowaN »
Logged

Offline elborak

  • Member
  • *
  • Posts: 177
Re: Display month name in WPS?
« Reply #9 on: May 21, 2007, 07:21:11 PM »
Nicolas already updated the wiki to include examples. Do those not work?
Logged

Offline RowaN

  • Member
  • *
  • Posts: 90
Re: Display month name in WPS?
« Reply #10 on: May 22, 2007, 08:37:44 AM »
The example in the wiki (http://www.rockbox.org/twiki/bin/view/Main/CustomWPS) is the same as my example above, which does not work.
« Last Edit: May 22, 2007, 08:39:42 AM by RowaN »
Logged

Offline Llorean

  • Member
  • *
  • Posts: 12931
Re: Display month name in WPS?
« Reply #11 on: May 22, 2007, 12:54:49 PM »
What SVN revision are you using? The actual number please.
Logged

Offline RowaN

  • Member
  • *
  • Posts: 90
Re: Display month name in WPS?
« Reply #12 on: May 22, 2007, 02:51:43 PM »
Sorry, it does work on real hardware, just tested with todays build.  :)

I was testing on a recent sim build with rockbox r13390-070515.
Logged

  • Print
Pages: [1]
« previous next »
+  Rockbox Technical Forums
|-+  Support and General Use
| |-+  Theming and Appearance Customization
| | |-+  Display month name in WPS?
 

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

Page created in 0.105 seconds with 15 queries.