|
Code Coloriser Tool
This tool is designed to apply standardised colour rules to
SCL or SOURCE code. This improves readability, and can even help find syntax
errors such as un-terminated comments or un-matched quotes.
The effect is very similar to that of the Enhanced Editor in Version 8, but
with these important differences:
- Colours are stored
in the catalog entry, so they appear in Build as well as Enhanced editor
windows.
- A designated colour
can be left unchanged, to allow programmer-highlighted text to remain
marked.
- It works in Version
6 as well as in Version 8 (in case you are still using the older release,
or to help in your migration).
It is fully parameterised, to allow you to control the
colour used for all the most important content in SCL statements. Options are
provided to specify the folowing colour components:
- CTEXT = general text
colour
- CQUOTE = colour for
quoted strings ('xxx' or "xxx")
- CCOMM = colour for
comments (/*...*/, *...; and %*...;)
- CLABEL = colour for
labels (both definition and use in link/goto statements)
- CENTRY = colour for
entry or method statements
- CSUBMIT= colour for
submit code blocks
- CSUBLAB= colour for
submit/endsubmit statements
- CRETURN= colour for
return, leave or endmethod statements
- CSYMBOL= colour for
symbolic references (&xx and %yy type, macro or SCL-substitution
variables)
- CLEAVE = colour
which will be left unchanged on output (useful for programmers' special
highlighting, such as temporary code that needs to be changed before
production use)
- MACCAPS= do you want
symbolic references capitalised? (macro or SCL-substitution variables.
Specify symbols = just &xx type, macros = just %yy type, both = both
types)
- LABELCAP= do you
want label-names capitalised? yes if you do
By adding a toolbar icon to your SAS AWS, the coloriser is just a click away
when editing SCL or SOURCE code, in either Version 6 or Version 8
environments
For an example of before-and-after, download the transport file colorise.xpt and import it using CIMPORT procedure.
The catalog contains two SCL entries - one 'plain', the other colorised.
|