make it work with vt100 and vt52, detect colors and A_REVERSE
and also set terminal title only on terminals that support it