CSMACRO user's guide
====================
 The application is a small macro processor, used from the command line, which can automatically
substitute symbols from a file with the determined values (strings). These pairs (symbol - value to substitute) can be set in definition files.
 The program, using the extension of the target file, uses default definition files:
- for C/C++ source-files - with the extension c, cpp, h - the definition file: cmacro.txt
- for Java source-files  - with the extension java - the def.file: jmacro.txt
- for SQL scripts - with the extension sql - the def.file: sqlmacro.txt
- for files with other extensions - the def.file: macro.txt.
This is the default behaviour of the program, the user can force the use of any definition file.
 The syntax of the command is:
	csmacro [definition_file] target_file
If definition_file is not supplied, the program selects the default definition files, as stated
above.

The symbol-value pairs can be defined on a single, row, the symbol and the corresponding value
must be separated by a space(blank) character.
Example:

# example.txt
exe example
nosh no shit
sex System.exit

If the command is used with this definition file, then any appearance of "exe" will be replaced
with "example", "nosh" with "no shit" and "sex" with "System.exit".
The symbols(tokens) in the target file must be delimited with characters from the following set:
space(blank);,.[]{}()+-=/*.
Comments in the definition file can be entered by using the char # (it must be the first 
character in the line and it shouldn't have no spaces before).
The number of definitions is limited currently to 200 definitions in a definition file, the length of a symbol(tag) to 16 characters and the length of the substitution value(string) to 128 characters.

The program can be used from the command line, or can be integrated as a tool in various 
text editors.
It has been tested by the author with the Crimson Editor, ConText Editor and JCreator 3.50 Lite.

Example - how to use csmacro as a tool from the Crimson Editor
--------------------------------------------------------------
Crimson Editor, freeware version 3.70 - Copyright (C) 1999-2004 Ingyu Kang. All rights reserved.

From the Tools menu select the option Conf.User Tools...
In the configuration window which is displayed as a result, select from the list User Tools an
empty set, and fill in the fields as follows:
 Menu Text:   - the text/name which should be displayed in the menu Tools
 Command:     - csmacro.exe
 Argument:    - $(FilePath)
 Initial Dir: - the directory where you have the program csmacro (e.g. C:\CSMacro\ ).
 Hotkey:      - when the cursor is in this field, press the key combination you would like to use to launch the program.
You can set the options Save before execute (it will save the active document before launching csmacro) and Capture output (it will display the messages printed to the stdout by csmacro), too.
After the settings have been saved, using the set hotkey you can use the program.
After the use of csmacro, you must reload the document which has been processed (the Reload option from the File menu or the Reload Document from the Document menu), to use the modified document.


The porgram can be used and distributed freely; however, you must distribute it in its original form.
The author declines any responsability for the corectness and the fitness for the purpose
of the application, or for any damages that may arise from using this application.
Comments & bug reports can be sent to: amate2@email.ro.
2005.9.16.
(c) Mate Albert, 2005.