#!/bin/sh # yell - abuse xterm for popup messages # originally by smarry@vex.net. # Start an xterm exactly big enough for the string, echo it and the # control sequence that turns on sending the mouse position on button # press, set the TTY to non-canonical blocking input, read one character, # and exit. SPEW="$*" \ xterm +sb -geometry `echo -n "$*"|wc -c`x1+100+100 \ -e sh -c 'echo -n "[?9h$SPEW" tput civis stty -echo -icanon min 1 time 0 dd bs=1 count=1 >/dev/null 2>&1'