2006/11/5, A.J.Mechelynck <[EMAIL PROTECTED]>:
Eddy Zhao wrote: > 2006/11/5, A.J.Mechelynck <[EMAIL PROTECTED]>: >> Eddy Zhao wrote: >> >> >> >> I tried this on FC2: >> >> >> >> :set stl=%{&imd} >> >> :inoremap <ESC> <ESC>:set imd<CR> >> >> :nnoremap i :set noimd<CR>i >> >> >> >> The first line (along with my usual :set laststatus=2) means that I >> can >> >> check my 'imd' setting in the status line. When I go between >> Normal and >> >> Insert modes with i and <Esc>, it changes from 1 to 0 and back, so I >> >> think it is working. >> >> >> > >> > Yes, I get the same result. >> > >> >> Please try this and see whether you get anything different. >> Also, >> >> try it with >> >> >> >> $ vim -u NONE >> >> :set nocp >> >> >> >> If you get the same results but are still having trouble, then the >> >> problem might be some other setting. >> >> >> >> HTH --Benji Fisher >> >> >> > >> > When starting with "-u NONE", status line isn't showed. >> > Is there anything else I can do to locate the problem? >> > >> > Thanks >> > Eddy >> > >> >> Enter ":set stl=%{&imd} ls=2" after starting Vim, and the status line >> will be >> shown, with 0 ('noimdisable') or 1 ('imdisable') on it. >> >> > > Thanks (I forget to set ls). > > I do the following > - gvim -u NONE > - :set stl=%{&imd} ls=2 > - :inoremap <ESC> <ESC>:set imd<CR> > - :nnoremap i :set noimd<CR>i > - :set nocp > - switching back & forth between normal mode & insert mode using "ESC" & > "i" > > When I pressing "i", the input focus is on command line & command line > shows ":set noimd<CR>i". > > If I using ":nnoremap i :set noimd<CR>i<CR>", pressing "i" get me to > insert mode (with an extra newline). But switching back & forth between > normal mode & insert mode, status line always shows "0" > > BTW, I discover that in vim (not gvim), even start without "-u NONE", > statusline always shows "0" (while gvim statusline will switch between > "0" & "1") > > Anything I can do to further nail down the problem? > > Thanks > Eddy >- Is your console Vim compiled with IM support? (I suppose it is, but check the ":version" output for +xim or +multi_byte_ime). Note: On Unix-like systems, IM support may require X11 support, and IM functionality may require access to an X server (thus, maybe in xterm displaying through X, not in /dev/tty which has no access to X). - Does it make any difference if you start Console Vim in 'nocompatible' mode, e.g. vim -u NONE -i NONE -N "+set stl=%{&imd} ls=2" ?
Hi Tony, I only using IM in gvim. So I only want IM work correctly in gvim. gvim is with +xim support. Thanks Eddy
