string operations on emacs buffers