added xterm support