My naming convention

Damien Girard dam-pro.girard at
Sat Jul 10 07:20:26 EDT 2010

Personnally I am using this naming convention:
- first letter in lowercase, then Uppercase for the first letter of each

- tMyVariable -> Variable available in the handler
- sMyVariable -> Variable available in the script (local)
- gMyVariable -> Global variable (global)
- kMyVariable -> Constant (constant)
- cMyVariable -> Variable that contain custom properties
- pMyParameter -> Parameter

In C, I use the same naming convention, the difference is:
- Instead of Uppercase, I use "_" to separate words.

- t_my_variable -> Variable available in the handler
- s_my_variable -> Variable available in the file (static)
- g_my_variable -> Variable available in the application (extern)
- k_my_variable -> Constant
- p_my_paramater -> Parameter (you see the *, you are not dumb, no need of a
"pointer" prefix)

And for C++/C#, same as Revolution. This enable me to mix C/C++ and to see
quickly in what file I am located.

After, for objects, I have no convention, but usually in rev I define the
name of objects only in lowercase, in order to not mix with variables.

All my softwares are written like that, and it works ;) (more than 20 000
lignes software...) (I stolen this convention from a Rev user, but I do not
remember who lol, btw thanks to him ^^)

Also, I am using DoxyGen in C/C++, and NativeDoc in Rev, that's helping a
lot :p

-----Message d'origine-----
De : use-revolution-bounces at
[mailto:use-revolution-bounces at] De la part de Richmond
Envoyé : samedi 10 juillet 2010 12:18
À : How to use Revolution
Objet : My naming convention

For what it is worth;

I always start a field's name with a lowercase 'f' - the rest in uppercase:

e.g. "fSTUFF"

so, similarly with other objects:

"gSTUFF" will be a group,

"ggSTUFF" will be a group containing subordinate groups,

"iSTUFF" is an image,

"pSTUFF" is (oddly enough) a graphic object

"bSTUFF" is a button


"vSTUFF" is a variable

"cSTUFF" is a constant

"sSTUFF" is a string

"aSTUFF" is an array


needless-to-say; I almost NEVER adhere to this convention . . .  :)


RunRev, having no intrinsic naming conventions, cheerfully allows one to
wander off rather tangentially if one is not very careful.


What I DO do is have a piece of paper on a clipboard on my lap where I write
down every object's name and what it is with a pencil.
use-revolution mailing list
use-revolution at
Please visit this url to subscribe, unsubscribe and manage your subscription

More information about the Use-livecode mailing list