Bug#204373: Current status

Juhapekka Tolvanen juhtolv at iki.fi
Sat Dec 22 02:50:31 UTC 2007


Right now I have these mapping in my ~/.vimrc

" Use Ctrl-J to justify just like in pico or nano
" In Vim LaTeX Suite Ctrl-j is already reserved.

" In visual mode format the highlighted text
"vmap <C-J>    gq<CR>
vmap <C-J>    gq

" In normal mode format current paragraph
"nmap <C-J>    gqap<CR>
nmap <C-J>    gqap

" In insert mode format current paragraph
"imap <C-J>    <ESC>gqap<CR>i
imap <C-J>    <ESC>gqapi

" Use Ctrl-J just like in pico or nano
"nmap <C-J> vipgq


If I give these commands right after startup:

:let @a=""
:redir @A
:map
:redir END
"ap

It outputs this to my text:

   <C-H>       * <C-W>h
   <NL>        * <C-W>j
   <C-K>       * <C-W>k
   <C-L>       * <C-W>l
   --            :call BenIndent()<CR>
v  <           * <gv
v  >           * >gv
   \mbt          <Plug>TMiniBufExplorer
   \mbu          <Plug>UMiniBufExplorer
   \mbc          <Plug>CMiniBufExplorer
   \mbe          <Plug>MiniBufExplorer
n  gx            <Plug>NetrwBrowseX
n  <Plug>NetrwBrowseX * :call netrw#NetBrowseX(expand("<cWORD>"),0)<CR>
   <C-Right>   * <C-W>l
   <C-Left>    * <C-W>h
   <C-Up>      * <C-W>k
   <C-Down>    * <C-W>j
   <Plug>TMiniBufExplorer & :call <SNR>20_ToggleExplorer()<CR>:<BS>
   <Plug>UMiniBufExplorer & :call <SNR>20_AutoUpdate(-1)<CR>:<BS>
   <Plug>CMiniBufExplorer & :call <SNR>20_StopExplorer(1)<CR>:<BS>
   <Plug>MiniBufExplorer & :call <SNR>20_StartExplorer(1, -1)<CR>:<BS>
   <F4>          :emenu <C-Z>
n  <F9>        * :TlistSync<CR>
n  <F8>        * :Tlist<CR>
n  <F7>        * :TlistUpdate<CR>


These mappings do not work:

" In visual mode format the highlighted text
"vmap <C-J>    gq<CR>
vmap <C-J>    gq

" In normal mode format current paragraph
"nmap <C-J>    gqap<CR>
nmap <C-J>    gqap

But this works:

" In insert mode format current paragraph
"imap <C-J>    <ESC>gqap<CR>i
imap <C-J>    <ESC>gqapi

If I set those mappings by hand after startup, they work. If after that
I capture mappings in aforementioned way, it looks like this:

   <C-H>       * <C-W>h
n  <NL>          gqap
v  <NL>          gq
o  <NL>        * <C-W>j
   <C-K>       * <C-W>k
   <C-L>       * <C-W>l
   --            :call BenIndent()<CR>
v  <           * <gv
v  >           * >gv
   \mbt          <Plug>TMiniBufExplorer
   \mbu          <Plug>UMiniBufExplorer
   \mbc          <Plug>CMiniBufExplorer
   \mbe          <Plug>MiniBufExplorer
n  gx            <Plug>NetrwBrowseX
n  <Plug>NetrwBrowseX * :call netrw#NetBrowseX(expand("<cWORD>"),0)<CR>
   <C-Right>   * <C-W>l
   <C-Left>    * <C-W>h
   <C-Up>      * <C-W>k
   <C-Down>    * <C-W>j
   <Plug>TMiniBufExplorer & :call <SNR>20_ToggleExplorer()<CR>:<BS>
   <Plug>UMiniBufExplorer & :call <SNR>20_AutoUpdate(-1)<CR>:<BS>
   <Plug>CMiniBufExplorer & :call <SNR>20_StopExplorer(1)<CR>:<BS>
   <Plug>MiniBufExplorer & :call <SNR>20_StartExplorer(1, -1)<CR>:<BS>
   <F4>          :emenu <C-Z>
n  <F9>        * :TlistSync<CR>
n  <F8>        * :Tlist<CR>
n  <F7>        * :TlistUpdate<CR>


-- 
Juhapekka "naula" Tolvanen * http colon slash slash iki dot fi slash juhtolv
"eiga wo miyou kimi no yakusoku dohri te wo tsunai de. yoru ni wa owakare
desu ringo to ichigo ga kusaru mae ni. yume wa hirogaru kimi no yakusoku
dohri kisu wo shi nagara."                                       Dir en grey





More information about the pkg-vim-maintainers mailing list