home *** CD-ROM | disk | FTP | other *** search
- ***************************************************************************
- Echo
-
- (C) 1986 by Larry Phillips
- SYSOP - ICUG
- All Rights Reserved
-
- **************************************************************************
-
- This is an improved ECHO command, with options to control
- colour, screen placement of text, etc.
-
- USAGE: ECHO [-[c0123tbiuds)!@#] [string]
-
- OPTIONS: -c Clear screen before printing string.
- -0 Set character colour to (same as default background colour).
- -1 Set character colour to (same as default character colour).
- -2 Set character colour to (same as in push/ pop gadgets).
- -3 Set character colour to (to same as trashcan).
- -t Tab.
- -b Boldface.
- -i Italic.
- -u Underline
- -d Set default screen colours and styles.
- -) Set background colour to colour 0 (note: shifted 0).
- -! Set background colour to colour 1 (note: shifted 1).
- -@ Set background colour to colour 2 (note: shifted 2).
- -# Set background colour to colour 3 (note: shifted 3).
- -s Supress new line after printing.
-
- The options are optional, as is the string to be printed. If no string is
- provided, a blank line will be printed. Quotes are optional as well, and
- are checked for only for compatibility with the ECHO command supplied with
- the Amiga. Quotes may be included in the string, and will be printed. See
- NOTES for special cases and caveats about quotes.
-
- NOTES: 1. The ending quote in a quoted string is not specifically checked.
- If a string starts with a quote, and has no closing quote, the
- last character in the string will be lost. To print quotes at the
- beginning of a line, use two quotes as follows:
-
- ECHO ""This is a quote," she said."
-
- will print
-
- "This is a quote," she said.
-
-
- 2. Options may be strung together in any order, and will affect the
- output string in the order supplied. ie. if you have the statement
-
- ECHO -ct3tb Hello there.
-
- The screen will clear (c), and the phrase "Hello there." (without
- the quotes) will be printed two tabs from the left margin (t) in
- colour #3 (3) and in boldface (b). The order is important in some
- cases, for example, if the options (-tc) are given, the tab will
- be performed, the the screen will be cleared, losing the tab.
-
- 3. Supression of linefeeds (s), is particularly handy if you want to
- highlight only part of a screen message. The sequence:
-
- ECHO -sb3 "WARNING: "
- ECHO -d This program is addictive!
-
- will print
-
- WARNING: This program is addictive!
-
- with WARNING: in boldface, colour #3, and the remainder of the
- line in normal default text style and colours. Due to the lack of
- a "set plain text style" sequence in the console driver, the (d)
- option will reset the colours, both foreground and background, so
- you must remember to set them back to what they were. ie. if the
- characters were printing in colour #2 before the above example,
- and you wantd to reset them to colour #2 after the WARNING:
- highlight, you could change the options in the second command
- to (-d2).
-
- 4. Options may be entered in upper or lower case where applicable.
- If you wish to echo a line that starts with a '-' (the option
- delimiter), you must quote the string to prevent ECHO from using
- your first word as options. If an invalid option is entered, it
- will be ignored by the option parser, and will also not be printed.
-
- 5. To install this command, simply copy it into your C: directory.
- The original echo will be replaced, and you can now "jazz up"
- your script files.
-
- ****************************************************************************
-
- Please see the example script file ETEST.SCR, for examples of what is
- possible with the improved ECHO command.
-
- To get a preview, just type EXECUTE ETEST.SCR
-
- This program is freely distributable for non commercial purposes only, and
- provided that this documentation accompany all copies of the program.
-
- Any questions, suggestions, flames, may be sent to Larry Phillips on...
-
- The Source -- SIG021 (Drop by ICUGSIG for more Amiga goodies)
- Compuserve -- 74025,636
- CityLink (in beautiful Vancouver, BC)
-