This is a two-parter. The first feature, and I don't think I need to make much of an argument in favor of this one, is the ability to have templates. Pre-commented files customized with your name, copyright information, etc. Considering I use the same basic combination of rules a lot (the core element of my files is usually called "BASE", I often name my startshape "SCENE"), it would certainly make my life easier.
I have a hunch that there'll be more opposition to the second, because it bends the Context-Free part- constants. Very often, I'll use the same value in multiple places, as a scaling factor, a weighting, translation value, or what-have-you. Then, I decide I don't like it, and now, I have to change twenty locations in order to make that simple change. Constants would be a valuable shorthand, and really, they could be done not as an addition to the CFDG, but as a pre-processor directive. A literal substitution a la C pre-processor commands.
Templates and Constants
Moderators: MtnViewJohn, chris, mtnviewmark
- MtnViewJohn
- Site Admin
- Posts: 882
- Joined: Fri May 06, 2005 2:26 pm
- Location: Mountain View, California
- Contact:
How about if we had a menu called 'Library' which worked like the Examples menu but it just was built from the contents of some directory? You could put all your templates in a directory, tell Context Free where it is, and Context Free would enumerate the cfdg files under it and make a menu. We could even make it heirarchical.
Global constants are not a problem. Yevgen Korshykov has them in his online version of CFDG: http://www.korsh.com/cfdg/. I can see Context Free copying that. Also, it would be nice to have expressions. How many people look at 0.866 and see SQRT(3)/2?
Global constants are not a problem. Yevgen Korshykov has them in his online version of CFDG: http://www.korsh.com/cfdg/. I can see Context Free copying that. Also, it would be nice to have expressions. How many people look at 0.866 and see SQRT(3)/2?
-
- Posts: 21
- Joined: Wed Jul 06, 2005 4:53 pm