Mer/Documentation/Vala control panel: Difference between revisions
From Maemo Wiki
Jump to navigationJump to search
imported>qwerty12 m Mer/Documentation/Vala Control Panel moved to Mer/Documentation/Vala control panel: Camel case is frowned upon. Thanks Stskeeps for telling me to name it "Vala Control Panel". :p |
imported>qwerty12 No edit summary |
||
| Line 2: | Line 2: | ||
But, documentation on Vala is rather lacking. | But, documentation on Vala is rather lacking. | ||
An example can be found here: http://slexy.org/view/ | An example can be found here: http://slexy.org/view/s2LF62vIvs | ||
(maemo.org wiki sucks and does not understand "<source lang="c-sharp">") | (maemo.org wiki sucks and does not understand "<source lang="c-sharp">") | ||
Revision as of 20:11, 28 July 2009
Mer needs new control panels. But not everyone knows C, but they may be proficient in C#. Vala is a language with C#-like syntax, that compiles to C, which makes it perfect for writing CPAs which are (to my knowledge) C only. But, documentation on Vala is rather lacking.
An example can be found here: http://slexy.org/view/s2LF62vIvs
(maemo.org wiki sucks and does not understand "<source lang="c-sharp">")
Save the above as "cpa.vala". Because valac seems to be more accustomed for making programs, you have to use valac's -C option which'll output the generated C code and gcc can then be used to make it into a library.
Improvements very much welcomed.