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:

Thank You for your continued support and contributions!

+  Rockbox Technical Forums
|-+  Support and General Use
| |-+  Theming and Appearance Customization
| | |-+  Battery: Numeric or Graphic
« previous next »
  • Print
Pages: [1]

Author Topic: Battery: Numeric or Graphic  (Read 1656 times)

Offline DrewVosburg

  • Member
  • *
  • Posts: 42
  • Designer
Battery: Numeric or Graphic
« on: January 17, 2011, 01:59:52 PM »
Is there a tag to get access to this setting?  I am not finding it in the Wiki, and I would like to use it.

If it doesn't yet exist, I think that would be something that is really nice to have.
Logged

Offline pixelma

  • Rockbox Expert
  • Member
  • *
  • Posts: 645
Re: Battery: Numeric or Graphic
« Reply #1 on: January 17, 2011, 02:20:42 PM »
There is a tag to find out about all possible settings which can also be used conditionally and which should work here. Look out for %St on the CustomWPS wiki or the manual.
Logged

Offline gbl08ma

  • Member
  • *
  • Posts: 249
    • My blog
Re: Battery: Numeric or Graphic
« Reply #2 on: January 17, 2011, 02:23:41 PM »
I think it only depends of the theme used. There're themes with a graphic indicator, others with a numeric one, others with both and it's possible to code one without any :)

You can edit a theme to show a numeric indicator instead of a graphic one, or vice-versa (although the vice-versa is harder, but obviously everything takes its time and work). Just look at the theme tags in the wiki and you should get an idea.

(It seems pixelma came first... I leave here my two cents for anyone who wants them)
Logged
http://gbl08ma.com | http://i.tny.im

Offline Progweed

  • Member
  • *
  • Posts: 67
Re: Battery: Numeric or Graphic
« Reply #3 on: January 17, 2011, 03:19:00 PM »
I guess %St(battery display) could work.

Querying this setting is a great idea. Didn't think of that until now!
Logged

Offline [Saint]

  • Rockbox Expert
  • Member
  • *
  • Posts: 1662
  • Hayden Pearce
    • Google+
Re: Battery: Numeric or Graphic
« Reply #4 on: January 17, 2011, 05:19:33 PM »
Quote from: DrewVosburg on January 17, 2011, 01:59:52 PM
Is there a tag to get access to this setting?  I am not finding it in the Wiki, and I would like to use it.

Are you wanting to use this to display the battery icon/text/whatever conditionally based on the users settings, as opposed to simple forcing either a graphical or numerical display on the user?

I have done this in a couple of themes myself:


%?St(battery display)<*graphical|*numerical>


This code sample will do what you want it to (assuming I made an accurate guess as to what you're wanting to do).

*Replacing graphical/numerical with appropriate code you're wanting to display of course.



[St.]
« Last Edit: January 17, 2011, 05:36:48 PM by [St.] »
Logged
Using PMs to annoy devs about bugs/patches is not a good way to have the issue looked at.

Offline DrewVosburg

  • Member
  • *
  • Posts: 42
  • Designer
Re: Battery: Numeric or Graphic
« Reply #5 on: January 17, 2011, 05:59:31 PM »
Quote from: [St.] on January 17, 2011, 05:19:33 PM
%?St(battery display)<*graphical|*numerical>
Thanks guys, this is what I was looking for!  Trying to make my theme respect user settings as much as possible.
Logged

  • Print
Pages: [1]
« previous next »
+  Rockbox Technical Forums
|-+  Support and General Use
| |-+  Theming and Appearance Customization
| | |-+  Battery: Numeric or Graphic
 

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

Page created in 0.092 seconds with 15 queries.