#!/bin/sh
## shell script to change the title on an xterm window and/or its icon.
if [ $# -ne 2 ]
then
    echo "Usage: xtitle { -t | -i | -b } string" 1>&2
else
    if [ "$1" = -t ]
    then
	echo -n "]2;$2"
    elif [ "$1" = -i ]
    then
	echo -n "]1;$2"
    elif [ "$1" = -b ]
    then
	echo -n "]0;$2"
    else
	echo "Usage: xtitle { -t | -i | -b } string" 1>&2
    fi
fi
