wow...that helps! sorry for my stupid question. it seems I did't learn taglist well.. thanks!
but, I think my question might remain valid as a generic question: how to define a new map : 1) in .vimrc 2) specific to a ft and local buffer 3) make it overide all other plugins/scripts, but just overide in that local buffer/ft. thanks! On Sun, Dec 22, 2013 at 3:00 PM, Yegappan Lakshmanan <[email protected]>wrote: > Hi, > > On Sun, Dec 22, 2013 at 11:48 AM, ping song <[email protected]> > wrote: > > gee..I just tried this idea on another scenario, didn't work... > > > > "this doesn't work, guess overided by taglist > > augroup MyTagListCommand > > au! > > au BufEnter FileType taglist nnoremap <buffer> <CR> <CR><C-W>p > > augroup END > > > > > > n <CR> *@:call <SNR>117_Tlist_Window_Jump_To_Tag('useopen')<CR> > > Last set from ~/.vim/plugin/taglist.vim > > Press ENTER or type command to continue > > > > kind of a tricky request, like:how to make the <CR> not to jump over, > while > > after borrowing taglist's <CR> magic? > > > > In the taglist window, you can press the 'p' key to jump to the tag but > remain > in the taglist window. You don't need to map <CR> for this. Also, note that > the taglist plugin doesn't use the quickfix feature (i.e. the taglist > window is > not a quickfix window). > > - Yegappan > > > > > > > On Sat, Dec 21, 2013 at 8:51 PM, ping song <[email protected]> > wrote: > >> > >> thanks Chris, this works! I didn't know that vim can: > >> define a map for just one filetype > >> further, just for one buffer. > >> that's nice! > >> > >> > >> On Wed, Dec 18, 2013 at 4:39 AM, Christian Brabandt <[email protected] > > > >> wrote: > >>> > >>> On Wed, December 18, 2013 10:30, ping song wrote: > >>> > I guess this is an old topic, at least I asked earlier some time ago. > >>> > but I seems never got the good resolution... > >>> > > >>> > quickfix windows is handy. the :cXXX commands are also good. current > >>> > work > >>> > flow is sth like this: > >>> > > >>> > 1. you search via vimgrep > >>> > :vimgrep /abc/gj ## > >>> > > >>> > 2. :cw to open the quickfix(QF) win > >>> > > >>> > 3. navigate in the QF win and , hit enter in a match > >>> > > >>> > 4. the original buffer which contains the matched line will be > >>> > displayed > >>> > > >>> > 5. at the same time you will be moved into the original buffer on to > >>> > that > >>> > matched line > >>> > > >>> > 6. you have to jump back to the QF win manually > >>> > > >>> > 7. go to 3. > >>> > > >>> > everything is great, except step 5 & 6 here cause some extra work. > >>> > > >>> > is there a way to avoid just step 4, that is to just remain in the QF > >>> > window when you hit <ENTER> on a matched line ? that will be really > >>> > much > >>> > faster when you navigate through the matched lines in QF win.. > >>> > > >>> > this is a nice feature that I ever seen from notepad++ or ultraeditor > >>> > that > >>> > my colleague is using... > >>> > > >>> > I was thinking to make some maps to automatically jump back after a > >>> > <ENTER>, but I don't know how to make that map to only work under QF > >>> > window. > >>> > >>> either use a ftplugin file and map <CR> only for the qf filetype > >>> or create an autocommand like this > >>> > >>> augroup MyQFCommand > >>> au! > >>> au FileType qf nnoremap <buffer> <CR> <CR><C-W>p > >>> augroup END > >>> > >>> regards, > >>> Christian > >>> > > -- > -- > 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 [email protected]. > For more options, visit https://groups.google.com/groups/opt_out. > -- -- 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 [email protected]. For more options, visit https://groups.google.com/groups/opt_out.
