On 8/28/07, Bram Moolenaar <[EMAIL PROTECTED]> wrote:
>
>
>
> Yakov Lerner wrote:
>
> > > > I get weird up/down behaviour when cursor traverses the braces. vim
> > > 7.1.87,
> > > > no custom plugins. This is apparently somehow related to matchparen.
> > > >
> > > > The testfile is x.c below.
> > > > Here is what happens if I press down starting from the beginning of
> > > file,
> > > > position 1:
> > > >
> > > > 1. Down. instead of going to line 2, cursor shows at line 4 !!!
> > > > 2. Down. cursor is at line 3
> > > > 3. Down. cursor is at line 2 !!!
> > > > 4. Down. cursor is at line 5
> > > > 6. Up. Cursor is at line 2!!!
> > > > 7. Up. Cursor is at line 3.
> > > > 8. Up. Cursor is '}' line 4!!!
> > > > 9. Up. Cursor is at line 1.
> > > >
> > > > ----------- x.c ----------------
> > > > int foo()
> > > > {
> > > >     return 0;
> > > > }
> > > > /* */
> > >
> > > I don't have a vt220 so I can't try it out.  I wonder if you are
> > > actually using a vt220 anyway, these are quite rare these days...
> >
> >
> > I observe same results when setting XTERM to xterm-mono.
> > The terminal was actually xterm.
> > You can change vt220 to xterm-mono and see the same results.
> >
> > > How can you tell where the cursor is and it's not the highlighting
> that
> > > makes you think the cursor is somewhere else?
> >
> > I can do :echo line('.') col('.'). This shows me that cursor is not
> > where vim shows the white block on the screen.
> >
> > > Try using a different color scheme.
> >
> > I normally work in color xterm. There is no problem there.
> > I do not normally work in B/W term. What we were doing, we were checking
> how
> > some console software  (not vim) behaves under the black-and-white TERM.
> >
> > As a side effect, I noticed that matchparen behaves weirdly on
> B/W  term. In
> > the mentioned B/W setup, the colorscheme was default because .vimrc is
> > empty.
> >
> > Anyway, if you want to see the matchparen problem on BW term (with
> default
> > colorscheme), you can set TERM to xterm-mono and see for yousrself.
>
> After I do ":set term=xterm-mono" I get no syntax HL and no matchparen
> highlighting.  The cursor shows up in the expected position.
>
> I suspect there is something wrong with your termcap/terminfo entry for
> xterm-mono.  Check the output of ":set termcap".


Output of :set termcap is below. More details about reproducing this:
This happens to me on the konsole with (1) white-on-black konsole
schema and (2) no blinking cursor. Maybe this is konsole problem.
I get matchparen display wrong in the following scenario:

1. In konsole, disable blinking cursor. Set 'White on Black' konsole schema.
2.  cp /dev/null /tmp/.vimrc            # simulate empty .vimrc
3. HOME=/tmp TERM=xterm-mono vim
a
{

}<esc><up><up><up><down><down><down>
-------------------------------------------------------------------------------------
:set termcap
--- Terminal codes ---
  t_AB=               t_CV=               t_ks=^[[?1h^[=
t_RV=^[[>c          t_us=^[[4m
  t_AF=               t_ut=y              t_le=^H
t_Sb=               t_vi=^[[?25l
  t_AL=^[[%p1%dL      t_da=               t_mb=^[[5m
t_Sf=               t_vs=^[[?12;25h
  t_al=^[[L           t_db=               t_md=^[[1m
t_se=^[[27m         t_SI=
  t_bc=               t_DL=^[[%p1%dM      t_me=^[[m
t_so=^[[7m          t_EI=
  t_cd=^[[J           t_dl=^[[M           t_mr=^[[7m
t_sr=^[M            t_xs=
  t_ce=^[[K           t_fs=^G             t_ms=y
t_ts=^[]2;          t_ZH=^[[7m
  t_cl=^[[H^[[2J      t_IE=^G             t_nd=^[[C
t_te=^[[?1049l      t_ZR=^[[m
  t_Co=               t_IS=^[]1;          t_op=               t_ti=^[[?1049h
  t_CS=               t_ke=^[[?1l^[>      t_RI=^[[%p1%dC      t_ue=^[[m
  t_cm=^[[%i%p1%d;%p2%dH
  t_cs=^[[%i%p1%d;%p2%dr
  t_vb=^[[?5h$<100/>^[[?5l
  t_ve=^[[?12l^[[?25h
  t_WP=^[[3;%p1%d;%p2%dt
  t_WS=^[[8;%p1%d;%p2%dt
--- Terminal keys ---
t_#2 <S-Home>    ^[[1;2H   t_K8 <kDivide>   ^[O*o     t_k; <F10>
^[[21;*~       <xF1>       ^[O*P
t_#4 <S-Left>    ^[[1;2D   t_K9 <kMultiply> ^[O*j     t_kB <S-Tab>
^[[Z           <xF2>       ^[O*Q
t_%1 <Help>      ^[[28;*~  t_KA <kEnter>    ^[O*M     t_kD <Del>
^[[3~          <xF3>       ^[O*R
t_%i <S-Right>   ^[[1;2C   t_KB <kPoint>    ^[O*n     t_kI <Insert>
^[[2;*~        <xF4>       ^[O*S
t_&8 <Undo>      ^[[26;*~  t_k1 <F1>        ^[[11;*~  t_kN <PageDown>
^[[6;*~        <xEnd>      ^[O*F
t_*7 <S-End>     ^[[1;2F   t_k2 <F2>        ^[[12;*~  t_kP <PageUp>
^[[5;*~        <zEnd>      ^[[8;*~
[EMAIL PROTECTED] <End>       ^[[1;*F   t_k3 <F3>        ^[[13;*~  t_kb <BS>
^?             <xHome>     ^[O*H
t_F1 <F11>       ^[[23;*~  t_k4 <F4>        ^[[14;*~  t_kd <Down>
^[O*B          <zHome>     ^[[7;*~
t_F2 <F12>       ^[[24;*~  t_k5 <F5>        ^[[15;*~  t_kh <Home>
^[[1;*H        <xUp>       ^[[1;*A
t_K1 <kHome>     ^[[1;*~   t_k6 <F6>        ^[[17;*~  t_kl <Left>
^[O*D          <xDown>     ^[[1;*B
t_K4 <kEnd>      ^[[4;*~   t_k7 <F7>        ^[[18;*~  t_kr <Right>
^[O*C          <xLeft>     ^[[1;*D
t_K6 <kPlus>     ^[O*k     t_k8 <F8>        ^[[19;*~  t_ku <Up>
^[O*A          <xRight>    ^[[1;*C
t_K7 <kMinus>    ^[O*m     t_k9 <F9>        ^[[20;*~       <Mouse>
^[[M           <kDel>      ^[[3;*~

Yakov

--~--~---------~--~----~------------~-------~--~----~
You received this message from the "vim_dev" maillist.
For more information, visit http://www.vim.org/maillist.php
-~----------~----~----~----~------~----~------~--~---

Raspunde prin e-mail lui