Monday, September 21, 2015

Re: I have forgotten what these fns assigned to F keys are for . .

Phil,

F10 looks like it's set up to add the current character under the cursor to the '/' register, so if you have "abcdef" on the screen and hit F9 on the first character and then F10 on each subsequent one, you'll get "abcdef" in the / register (this is because you're using .= instead of = after "let @/".

.~\\ is a list of 3 characters ( '.', '~' and '\', the latter of which is escaped for the string) that you're passing to the escape function so that it will prefix them with a backslash.

As to why you have these mappings, no idea I'm afraid!  If you don't use them ever (which I can only assume is the case since you don't know what they do), it might be a good time to delete them.

F10 will be opening the file menu on the xfce4-term because the terminal window is presumably intercepting F10 before it gets to vim.

Al

On 21 September 2015 at 11:31, Philip Rhoades <phil@pricom.com.au> wrote:
People,

I have these in my .vimrc file:

  nnoremap <F9>  :let @/=escape(getline('.')[col('.')-1], '.~\\')<cr>
  nnoremap <F10> :let @/.=escape(getline('.')[col('.')-1], '.~\\')<cr>

I didn't get very far doing a lot of Googling, but from experimenting with them I found F9 puts the current character under the cursor into the "/" register but F10 opens the file menu on my xfce4-term !  What is:

  '.~\\'

supposed to do?

Thanks (I am putting comments into my .vimrc file as I write this . . ),

Phil.
--
Philip Rhoades

PO Box 896
Cowra  NSW  2794
Australia
E-mail:  phil@pricom.com.au

--
--
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 vim_use+unsubscribe@googlegroups.com.
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 vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment