Added modifications for non-terminal emacs.