This guide contains the following topics:
Slick-C® is a macro programming language that blends object-oriented features from C++, Java, and Python. Much of the code in the SlickEdit® editor is written in Slick-C, which covers many of the actions normally performed in a code editor including navigation and buffer modification. The Slick-C source is provided when SlickEdit is installed. You can use Slick-C to modify the look and feel of the editor, write macros to perform custom operations, add new language support, and essentially extend the editor's functionality until it is completely customized according to your preferences.
After SlickEdit® is installed, the Slick-C macro files are located in the macros subdirectory of your installation directory.
Slick-C macros are stored in files ending in the .e extension. The Slick-C macro translator compiles these files to byte code which is saved in a corresponding file with the .ex extension.
Slick-C follows a C-style linking model with the distinction that macros can be loaded and reloaded dynamically. Compiled macros and dialog box templates are stored in the state file vslick.sta (UNIX®: vslick.stu), which is located in your configuration directory.
Slick-C is preprocessed like C. Slick-C header files use the .sh extension. All Slick-C source files #include slick.sh.
The table below outlines Slick-C naming conventions.
|
Type |
Example Name |
Details |
|---|---|---|
|
Namespaces |
se.example |
Lowercase, with an underscore or dot to separate multiple words. |
|
Classes |
ExampleName |
Mixed case, first letter must be capitalized, all caps only acceptable for acronyms like "FTP". |
|
Interfaces |
IExampleName |
Like class names, but with "I" prefix. |
|
Enums |
ExampleName |
Like class names (idea of "E" prefix rejected). |
|
Enum Flags |
ExampleFlags |
Like enums, but ends with "Flags" (idea of "F" prefix rejected). |
|
Member Funcs |
exampleName |
Mixed case with the first letter lowercase. |
|
Member Vars |
m_exampleName |
Mixed case, first letter lowercase, and an "m_" prefix. |
|
Properties |
m_exampleName |
Same as member variables (should not distinguish from var). |
|
Class Vars |
s_exampleName |
Mixed case, first letter lowercase, and an "s_" prefix. |
|
Namespace Vars |
g_exampleName |
Like member vars except with a "g_" prefix. |
|
Namespace Funcs |
example_name |
Lowercase with words separated with underscores. |
|
Global Vars |
<anything> |
No rules. |
|
Global funcs |
<anything> |
No rules. |
|
Typedefs |
<anything> |
No rules. |