Rockbox Development > Feature Ideas

Future Built In Wps Code

<< < (2/2)

pixelma:
The WPS syntax was changed because the old one using | in places with different "meanings" was ambiguous and Rockbox had to take further measures to interpret the WPS correctly. E.g. it was possible to use the progressbar in a conditional, it was also possible to use the progressbar with or without further parameters, so - is a | after the %pb tag in a conditional a "parameter separator" or the "conditional separator"? Things got worse when other things got "bar tag" versions, like the current volume (%pv) and I actually had a WPS that failed after %pv became a bar tag.

It would be pretty silly allowing both code styles as it would reintroduce this ambiguity and would even make it worse! And as already been said - Rockbox runs on limited devices and you can't compare the players to a PC.

Converting a theme to the new syntax is easy, there's even a helper tool available which you just need to run on your files and which converts them automatically. Of course that would happen on your PC but you would only need to do it once and if you start coding your new themes with the new syntax you won't see the problem again.

There are other ways how to deal with your* situation and I have a few suggestions: (1) maybe you could write such a theme converter as a plugin that runs on the device, (2) you could write a theme editor plugin that makes it easier for you to access all the tags and already gives you additional characters that go along with it or more. Finally suggestion (3) would be quite simple to do and is the most realistic: create a loadable keyboard layout that is optimised for the new theme syntax - characters you need most in an easy to reach spot etc. I don't think it would be much more hassle than the old syntax then.

*) offtopic: as I think you are in a small minority of people coding themes on the player

redblade8:
Thankyou for this. You have explained everything very logically. Yes, I am one of the very small minority of people who codes on their mp3 =P If I could have time on the computer to code a wps, then I probably wouldn't of complained about this in the 1st place. It's really only a problem when you code on rockbox.

Your suggestions are very good too, I cannot think of any other solution.

1) I was going to suggest on here a theme converter plugin that can run on rockbox, but I don't see why I can't just learn how to code myself and create one. I would have to print out a 'how to' kind of guide to get started, and code it on my mp3 at home.
 ...Although, if someone were to get to this before me ,(which is alot likely),  it would be very helpful. 

2) This is an interesting idea,it sounds kind of like spell check, which is cool.

3) This would work, but suggestion 1 is the best to take care of things =P
...Although suggestion #3 is the most practical.

[Saint]:

--- Quote from: redblade8 on October 21, 2010, 02:46:03 PM ---I would have to print out a 'how to' kind of guide to get started, and code it on my mp3 at home.

--- End quote ---

Sorry, but this simply isn't possible.

You would drive yourself insane before you managed to type out all the code needed to make a working plugin to achieve this task on the virtual keyboard, and even if you did manage to do so you would still need to move it off the device and compile it into a build using a working development environment on your PC.

It's not possible to compile Rockbox, on a Rockboxed device...and even if it were possible to do so even the fastest available Rockbox target would probably take days (a week even?) to complete this task.

There's simply no other way.

Hmmmmm....perhaps (big perhaps) you could code it in LUA and run it from the device, but using the virtual keyboard to do this on device would simply be insane, and I say that in the nicest possible way.



--- Quote from: redblade8 on October 21, 2010, 02:46:03 PM ---...Although, if someone were to get to this before me ,(which is alot likely),  it would be very helpful.

--- End quote ---

Actually, I don't see that as being very likely at all...

In a short ammount of time Rockbox 3.7 will be released and there will not be a supported version of Rockbox using the old (3.6 and lower) theme syntax. So such a plugin would be completely useless.

The effort required to make such a plugin, combined with the fact that a command line tool already exists to convert old syntax to new, and the fact that the old syntax will very shortly be completely out of date leads me to believe that it is incredibly unlikely that this plugin would ever be created.



[St.]

AlexP:
Just go and use a library computer for half an hour so, convert your theme, and stop worrying about it.

redblade8:
Thanks For All The Help.

To solve this:
- I will create a virtual keyboard layout to support future coding of WPS's.
- I will have to learn the new syntax anyways because everyone will be using it , and I will not have any clue what someone was talking about anyways if they were to post something about the new wps syntax because I am still using the old syntax.
- I will do what Alex said to do and convert the couple wps's I made to the new format.

'You would drive yourself insane before you managed to type out all the code needed to make a working plugin to achieve this task on the virtual keyboard'

Haha, I was already doing this just coding a wps on my mp3, just adding the different characters for the new wps syntax would of made it even crazier, so this is the reason for my post =P

Hmmmmm....perhaps (big perhaps) you could code it in LUA and run it from the device, but using the virtual keyboard to do this on device would simply be insane, and I say that in the nicest possible way.

No offence taken, it is insane  ;)

Navigation

[0] Message Index

[*] Previous page

Go to full version