feedkeys \<cr> Enter key

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

feedkeys \<cr> Enter key

Ni Va
Hi,


In order to easily test command I have mapped this following.

feedkeys enters well WEATHER chars but not <Enter> key.



nnoremap <F5>            :!start gvim -c "call feedkeys(':WEATHER\<cr>')"<cr>

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: feedkeys \<cr> Enter key

Lifepillar
On 01/04/2018 10:09, Ni Va wrote:
> Hi,
>
> In order to easily test command I have mapped this following.
>
> feedkeys enters well WEATHER chars but not <Enter> key.
>
> nnoremap <F5>            :!start gvim -c "call feedkeys(':WEATHER\<cr>')"<cr>

Surround feedkeys()'s argument in double, not single, quotes.

Life.



--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: feedkeys \<cr> Enter key

Ni Va
Le dimanche 1 avril 2018 11:01:45 UTC+2, Lifepillar a écrit :

> On 01/04/2018 10:09, Ni Va wrote:
> > Hi,
> >
> > In order to easily test command I have mapped this following.
> >
> > feedkeys enters well WEATHER chars but not <Enter> key.
> >
> > nnoremap <F5>            :!start gvim -c "call feedkeys(':WEATHER\<cr>')"<cr>
>
> Surround feedkeys()'s argument in double, not single, quotes.
>
> Life.
nnoremap <F5>            :!start gvim -c "call feedkeys(":WEATHER\<cr>")"<cr>

gives me error

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: feedkeys \<cr> Enter key

Lifepillar
On 01/04/2018 11:18, Ni Va wrote:

> Le dimanche 1 avril 2018 11:01:45 UTC+2, Lifepillar a écrit :
>> On 01/04/2018 10:09, Ni Va wrote:
>>> Hi,
>>>
>>> In order to easily test command I have mapped this following.
>>>
>>> feedkeys enters well WEATHER chars but not <Enter> key.
>>>
>>> nnoremap <F5>            :!start gvim -c "call feedkeys(':WEATHER\<cr>')"<cr>
>>
>> Surround feedkeys()'s argument in double, not single, quotes.
>>
>> Life.
>
> nnoremap <F5>            :!start gvim -c "call feedkeys(":WEATHER\<cr>")"<cr>
>
> gives me error

Try: ... 'call feedkeys(":WEATHER\<cr>")'<cr>
i.e., use single quotes for the outer quoting.

Life.

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: feedkeys \<cr> Enter key

Ni Va
It results in that, I think double quote is needed to embrace call feedkey and inside double single quote ''

"D:/Logiciels/Vim/feedkeys(:WEATHER/" Illegal file name
Error detected while processing command line:


2018-04-01 11:30 GMT+02:00 Lifepillar <[hidden email]>:
On 01/04/2018 11:18, Ni Va wrote:
Le dimanche 1 avril 2018 11:01:45 UTC+2, Lifepillar a écrit :
On 01/04/2018 10:09, Ni Va wrote:
Hi,

In order to easily test command I have mapped this following.

feedkeys enters well WEATHER chars but not <Enter> key.

nnoremap <F5>            :!start gvim -c "call feedkeys(':WEATHER\<cr>')"<cr>

Surround feedkeys()'s argument in double, not single, quotes.

Life.

nnoremap <F5>            :!start gvim -c "call feedkeys(":WEATHER\<cr>")"<cr>

gives me error

Try: ... 'call feedkeys(":WEATHER\<cr>")'<cr>
i.e., use single quotes for the outer quoting.

Life.


--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- You received this message because you are subscribed to a topic in the Google Groups "vim_use" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/vim_use/UYd_FOUyDw0/unsubscribe.
To unsubscribe from this group and all its topics, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: feedkeys \<cr> Enter key

Bram Moolenaar

Ni Va wrote:

> It results in that, I think double quote is needed to embrace call feedkey
> and inside double single quote ''
>
> "D:/Logiciels/Vim/feedkeys(:WEATHER/" Illegal file name
> Error detected while processing command line:

[...]

> >>>> In order to easily test command I have mapped this following.
> >>>>
> >>>> feedkeys enters well WEATHER chars but not <Enter> key.
> >>>>
> >>>> nnoremap <F5>            :!start gvim -c "call
> >>>> feedkeys(':WEATHER\<cr>')"<cr>

The problem is that this is inside a mapping.  I haven't tried it, but
most likely the mapping will eat the backslash.  Either leave out the
backslash, so the mapping converts it to a real CR, or add another
backslash.

--
From "know your smileys":
 =):-) Uncle Sam

 /// Bram Moolenaar -- [hidden email] -- http://www.Moolenaar.net   \\\
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: feedkeys \<cr> Enter key

Christian Brabandt
In reply to this post by Ni Va

On So, 01 Apr 2018, Ni Va wrote:

> It results in that, I think double quote is needed to embrace call feedkey and
> inside double single quote ''
>
> "D:/Logiciels/Vim/feedkeys(:WEATHER/" Illegal file name
> Error detected while processing command line:

Quoting on the command line in Windows is nasty. I suggest to put the
command into a vim script file and source that using the -u command line
or similar.

Best,
Christian
--
Bescheidenheit ist die zarte Kunst, deinen Charme zu erhöhen, indem du
vorgibst, seiner nicht gewahr zu sein.
                -- Oliver Herford

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: feedkeys \<cr> Enter key

Ni Va
Le dimanche 1 avril 2018 13:14:41 UTC+2, Christian Brabandt a écrit :

> On So, 01 Apr 2018, Ni Va wrote:
>
> > It results in that, I think double quote is needed to embrace call feedkey and
> > inside double single quote ''
> >
> > "D:/Logiciels/Vim/feedkeys(:WEATHER/" Illegal file name
> > Error detected while processing command line:
>
> Quoting on the command line in Windows is nasty. I suggest to put the
> command into a vim script file and source that using the -u command line
> or similar.
>
> Best,
> Christian
> --
> Bescheidenheit ist die zarte Kunst, deinen Charme zu erhöhen, indem du
> vorgibst, seiner nicht gewahr zu sein.
> -- Oliver Herford
Ok thank you.

Best mapping I have done is that one even if I have to enter <Enter> key

nnoremap <F5>            :!start gvim -c "call feedkeys(':WEATHER')"<cr>

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.