Page 1 of 1
Syntax coloring : Color for Macro
Posted: Sun Mar 12, 2006 8:16 am
by Comtois
it would be possible to add a color different for the macro ?
example :
Code: Select all
Truc.Point
Macro Toto(P)
Do someThing
EndMacro
Procedure Titi(*P.Point)
Do something
EndProcedure
Toto(Truc) ; It would be nice to have a color for macro here
Titi(@Truc) ; because parameter is not the same
I have a lot of macro and procedure , and it is difficult to remember when i have to write (Truc) or (@Truc) .
Posted: Sun Mar 12, 2006 2:33 pm
by freak
It would be possible, but it could only color macros of the sources that are currently opened.
If you would have declared the macro in some includefile, the IDE cannot know
about it and it would not be colored.
Posted: Sun Mar 12, 2006 3:12 pm
by Comtois
Ok , thank you .
So i will write macro with Upper case

Posted: Sun Mar 12, 2006 8:08 pm
by blueznl
i guess only for open files is good enough for me, it's the same thing as with procedures and autocomplete, so why not?
Posted: Sun Mar 12, 2006 10:45 pm
by freak
The difference is that with autocomplete if some procedure is not recognized,
its an inconvinience because you have to type it by hand, nothing more.
A wrong hilighting could lead to code errors or atleast to some confusion though.
Lets say you look at the code, see the macro color and go "oh, its a macro"
and write your code according to that. Next time you look at the source you
maybe do not have the file open that defines the macro. (in which case, the
macro use would probably get the procedure or normal text color. You see
that and go "oh, its a procedure" and base your code writing on that, and of
course that is wrong.
The coloring should always be the same and not depend on the content of other
files and wether they are open or not. This is exactly the reason why
Arrays and LinkedLists get colord with the function color, because it is
impossible to determine what exactly it is if the definition is not present
in the current file.
Posted: Sun May 14, 2006 11:04 am
by Psychophanta
freak wrote:It would be possible, but it could only color macros of the sources that are currently opened.
Well, i thing that would be more than nothing

Posted: Sun May 14, 2006 11:28 am
by DarkDragon
Psychophanta wrote:freak wrote:It would be possible, but it could only color macros of the sources that are currently opened.
Well, i thing that would be more than nothing

I thinks it would be less, because you may get puzzled. I would want a autocomplete which checks all includefiles, too(but optional). A "Open Project..." would also be good, it opens one .pb file and all files which are included in this file.
Posted: Sun May 14, 2006 11:30 am
by Psychophanta
Yeah, may be :roll: