Loading ...
Sorry, an error occurred while loading the content.
 

RE: Folding bug. (6.0w, win2k)

Expand Messages
  • Moore, Paul
    From: Mark Brophy [mailto:mbrophy@esmertec.com] ... Right. I get it now, with gvim -u NONE. I don t get it with my vimrc. Trimming it down, it s the nowrap
    Message 1 of 5 , Mar 1, 2001
      From: Mark Brophy [mailto:mbrophy@...]
      > "Moore, Paul" wrote:
      > >
      > > From: Mark Brophy [mailto:mbrophy@...]
      > > > I've noticed a bug using gvim 6.0w under windows.
      > > > You can reproduce it the following way.
      > > >
      > > > start gvim with an empty window.
      > > >
      > > > insert a few lines of text, select it
      > > > and hit zf to fold it. Then click with the mouse,
      > > > just below the fold (and off the text, in the ~'s area).
      > > >
      > > > You should get lots of errors/Hit Return prompts.
      > >
      > > I can't reperoduce this (gvim 6.0w on Windows 2000,
      > compiled myself with
      > > MSVC). Can you be a little more specific in what you did?
      > >
      > > Paul.
      >
      > Ok, I just tried it without my vimrc, and it still
      > happens. I only have the standard plugins distributed with
      > 6.0.
      >
      > Start gvim.
      > itest<return>test<ESC>Vkzf
      >
      > Now, click on any ~ line with the left mouse button.
      > You should get an error message (more messages the
      > further down you click), and the cursor will be where you
      > clicked (outside the text).

      Right. I get it now, with gvim -u NONE. I don't get it with my vimrc.

      Trimming it down, it's the nowrap option.

      gvim -u NONE -U NONE gives the problem
      gvim -u NONE -U NONE -c "set nowrap" does not.

      Not that I know how to fix it, of course...

      Paul.
    • Bram Moolenaar
      ... I see it on Unix too. This patch should fix it: ... *************** *** 2041,2047 **** break; first = FALSE; #ifdef FEAT_FOLDING !
      Message 2 of 5 , Mar 1, 2001
        Mark Brophy wrote:

        > I've noticed a bug using gvim 6.0w under windows.
        > You can reproduce it the following way.
        >
        > start gvim with an empty window.
        >
        > insert a few lines of text, select it
        > and hit zf to fold it. Then click with the mouse,
        > just below the fold (and off the text, in the ~'s area).
        >
        > You should get lots of errors/Hit Return prompts.

        I see it on Unix too. This patch should fix it:

        *** ui.c.orig Fri Feb 23 22:50:24 2001
        --- ui.c Thu Mar 1 16:25:04 2001
        ***************
        *** 2041,2047 ****
        break;
        first = FALSE;
        #ifdef FEAT_FOLDING
        ! hasFolding(curwin->w_topline, NULL, &curwin->w_topline);
        #endif
        }
        redraw_later(VALID);
        --- 2041,2049 ----
        break;
        first = FALSE;
        #ifdef FEAT_FOLDING
        ! if (hasFolding(curwin->w_topline, NULL, &curwin->w_topline)
        ! && curwin->w_topline == curbuf->b_ml.ml_line_count)
        ! break;
        #endif
        }
        redraw_later(VALID);
        ***************
        *** 2163,2177 ****
        col += curwin->w_skipcol;
        break;
        }
        if (lnum == curbuf->b_ml.ml_line_count)
        {
        retval = TRUE;
        break; /* past end of file */
        }
        row -= count;
        - #ifdef FEAT_FOLDING
        - (void)hasFolding(lnum, NULL, &lnum);
        - #endif
        ++lnum;
        }
        }
        --- 2165,2179 ----
        col += curwin->w_skipcol;
        break;
        }
        + #ifdef FEAT_FOLDING
        + (void)hasFolding(lnum, NULL, &lnum);
        + #endif
        if (lnum == curbuf->b_ml.ml_line_count)
        {
        retval = TRUE;
        break; /* past end of file */
        }
        row -= count;
        ++lnum;
        }
        }

        --
        hundred-and-one symptoms of being an internet addict:
        37. You start looking for hot HTML addresses in public restrooms.

        /// Bram Moolenaar -- Bram@... -- http://www.moolenaar.net \\\
        ((( Creator of Vim - http://www.vim.org -- ftp://ftp.vim.org/pub/vim )))
        \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org ///
      Your message has been successfully submitted and would be delivered to recipients shortly.