/* Say.AMIRX
// $VER: Say.AMIRX 4.1 (29.07.96) (MCF Extra command)
\\ Written by Donald T. Becker (dtbecker@prolog.net) IRC: StarDustr
//
\\ ** What to do with this file?   Put this script in REXX:
//	then type  /rx say TEXT
\\  to start BOLD        use      \b
//  to start REVERSE     use      \r
\\  to start UNDERSCORE  use      \u
//  then use the same to remove the attribute from the text line
*/
parse arg argline

xx = pos('\', argline)
aline = ""

if xx > 0			then do
	do			until xx = 0
		yy = xx - 1
		zz = xx + 1
		xx = xx + 2
		rchar = substr(argline, zz, 1)
		if rchar = 'b'		then RepChar = '02'x
		if rchar = 'r'		then RepChar = '16'x
		if rchar = 'u'		then RepChar = '1f'x
		if xx > 2		then
			aline = aline || left(argline, yy) || RepChar
		else	aline = aline || RepChar
		argline = substr(argline, xx)
		xx = pos('\', argline)
	end
	if argline ~= ""		then aline = aline || argline
end

"say "aline

exit
