Wednesday, June 10, 2020

Re: Input continuous stream of digraphs

Hi, thanks for your reply.

On 11/06/20 1:47 am, John Passaro wrote:
you could write a function with a while 1 loop that calls getchar() twice and calls exec 'normal i<C-K>' . char1 . char2, then calls itself recursively. Then ctrl-C would get you out.

I ran into a some issues while doing this. I could not make <C-k> work under execute. For e.g.:

> function! TestFunc()

>    execute "normal! i<C-k>aa"

> endfunction

The above snippet is printing `<C-k>aa` as it is. How can I make it consider `<C-k>` as the control character rather than a string.

--
Manas
CSAM Undergraduate 2022

No comments: