Well, if you know that % will always be remapped, then using.
Up vote 0 down vote favorite share g+ share fb share tw.
I'm a big fan of the matchit. Vim plugin, but I prefer to jump between matching delimiters with the key. However, it seems that matchit is hard-coded to activate when pressing the % key.
My first thought would be that I would simply put this line in my . Vimrc, and change '%' to '', thus binding the Match_wrapper call to the tab key: nnoremap % :call Match_wrapper('',1,'n') However, this doesn't seem to work; I'm guessing it has got something to do with the (which as far as I understand is an ID unique to the script? ) or the fact that Match_wrapper is script-local.
(I'm pretty new to Vimscript) Thus far I've managed to get by mapping to % with 'nmap', but it's a pretty fragile hack. Anyway, any help would be greatly appreciated! :) vim link|improve this question edited Feb 9 at 9:18 asked Feb 7 at 21:40Christoffer374 75% accept rate.
Nnoremap % works for me. So does nmap % – Kevin Feb 7 at 22:07 Sorry, maybe I was a bit unclear - I WANT to use nnoremap, but since the idea of nnoremap is not to interfere with other scripts it will have no effect on plugins that remap the %-key, which is what matchit does. – Christoffer Feb 9 at 9:16 What I'm unclear on is why you think they don't work.
I do have matchit and tested, both worked the way you seem to want - tab switched between pairs specified in matchit that % wouldn't by default. And I believe the noremap only applies to patterns that appear in the input, in this case tab. – Kevin Feb 9 at 13:55 Ok, that's weird... I couldn't get it to work with nnoremap before, I'll have to try again.
What version of matchit are you using? – Christoffer Feb 9 at 16:26.
Well, if you know that % will always be remapped, then using map % is safe (absence of n in front is intentional: % is defined in all modes covered by :map). But what you can always do is to replace with {N}_ where {N} is the number of the matchit script in the outputs of :scriptnames. In a newer vim you can also use maparg('%', 'n', 0, 1), it will output a dictionary that among other values contains lhs and sid.
In this case code may look like this: for s:mode in 'n', 'v', 'o' let s:map=maparg('%', s:mode, 0, 1) execute s:mode. 'noremap '. Substitute(s:map.
Lhs, '', ''. S:map.sid. '_', 'g') endfor In this case for s:mode in 'n', 'v', 'o' execute s:mode.
'noremap '. Maparg('%', s:mode) endfor is also acceptable as “old” (without fourth argument) behavior of maparg is to expand .
I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.