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

Re: moving virual rectange about in virtualedit mode

Expand Messages
  • Charles E Campbell Jr
    ... With DrawIt v8d, you can move a selected rectangle about with your mouse. Here s the relevant portion of the help for DrawIt: One may drag
    Message 1 of 6 , May 2, 2007
    • 0 Attachment
      Yakov Lerner wrote:

      > I 'set ve=all' and selected a rectangle with Ctrl-V.
      > How can I move this rectangle up/down left/right with arrows ?

      With DrawIt v8d, you can move a selected rectangle about with your mouse.
      Here's the relevant portion of the help for DrawIt:

      <ctrl-leftmouse>

      One may drag and move a selection with <ctrl-leftmouse>. First,
      select the region using the <leftmouse>. Release the mouse button,
      then press ctrl and the <leftmouse> button; while continuing to press
      the button, move the mouse. The selected block of text will then
      move along with the cursor.

      Here's how to get & install DrawIt (when 7.1 comes out, this will become
      lots easier - just steps 3&4)

      To get an up-to-date version of drawit, you'll also need to get an
      up-to-date version of vimball. So:

      1) Get an up-to-date version of vimball:
      http://vim.sourceforge.net/scripts/script.php?script_id=1502
      -or- http://mysite.verizon.net/astronaut/vim/index.html#VimBall
      (the mysite.verizon.net one will be the more recent version)

      2) Remove the old vimball plugin and install the new one:

      Linux:
      cd /usr/local/share/vim/vim70
      /bin/rm plugin/vimball*.vim autoload/vimball*.vim doc/pi_vimball.txt
      mv (wherever it was downloaded)/vimball.tar.gz .
      gunzip vimball.tar.gz
      tar -xvf vimball.tar

      Windows:
      Under Windows, check your runtimepath to determine where your
      vim 7.0's runtime directories are:

      vim
      :echo &rtp
      :q

      The first directory is likely your personal plugins directory,
      the second one is your vim system directory.

      cd (to your vim system directory)
      del plugin\vimballPlugin.vim
      del autoload\vimball.vim
      del doc\pi_vimball.txt
      ren (wherever)\vimball.tar.gz vimball.tar.gz
      gunzip vimball.tar.gz
      tar -xvf vimball.tar


      3) Get DrawIt:
      http://vim.sourceforge.net/scripts/script.php?script_id=40
      http://mysite.verizon.net/astronaut/vim/index.html#DRAWIT

      4) Install an up-to-date version of Drawit:
      vim DrawIt.vba.gz
      :so %
      :q
    • Gary Johnson
      ... Unfortunately, this works only for gvim, not vim. in an xterm opens the Main Options menu. ... One may need to uninstall (i.e., delete)
      Message 2 of 6 , May 2, 2007
      • 0 Attachment
        On 2007-05-02, Charles E Campbell Jr <drchip@...> wrote:
        > Yakov Lerner wrote:
        >
        > > I 'set ve=all' and selected a rectangle with Ctrl-V.
        > > How can I move this rectangle up/down left/right with arrows ?
        >
        > With DrawIt v8d, you can move a selected rectangle about with your mouse.
        > Here's the relevant portion of the help for DrawIt:
        >
        > <ctrl-leftmouse>
        >
        > One may drag and move a selection with <ctrl-leftmouse>. First,
        > select the region using the <leftmouse>. Release the mouse button,
        > then press ctrl and the <leftmouse> button; while continuing to press
        > the button, move the mouse. The selected block of text will then
        > move along with the cursor.

        Unfortunately, this works only for gvim, not vim. <ctrl-leftmouse>
        in an xterm opens the Main Options menu.

        > Here's how to get & install DrawIt (when 7.1 comes out, this will become
        > lots easier - just steps 3&4)

        > 3) Get DrawIt:
        > http://vim.sourceforge.net/scripts/script.php?script_id=40
        > http://mysite.verizon.net/astronaut/vim/index.html#DRAWIT
        >
        > 4) Install an up-to-date version of Drawit:
        > vim DrawIt.vba.gz
        > :so %
        > :q
        >

        One may need to uninstall (i.e., delete) any earlier version of
        DrawIt, too, specifically the file ~/.vim/plugin/DrawIt.vim. The
        symptoms of needing to do this include vim complaining at startup
        that \di has been defined twice.

        I use the line-drawing capability of DrawIt all the time. I haven't
        done much with the visual-block commands, so I thought I'd try one.
        I think I found a bug in the version of DrawIt from the astronaut
        site.

        I inserted the following two paragraphs of text into a buffer,
        started DrawIt by typing \di, left-clicked the mouse on the
        character in the upper left corner of the region (the 'e' in
        "everywhere", no longer visible below), dragged the visual selection
        to the lower right corner, and typed \b to draw a box.

        Mary had a little lamb,
        Its fleece was white as snow,
        And +------------------+ went,
        The |amb was sure to go|
        ||
        It f|llowed her to scho|l one day,
        Whic+------------------+le,
        And made the children laugh and play
        To see a lamb at school.

        Note that the two bars between the paragraphs are in columns 1 and 2
        instead of 8 and 27.

        Regards,
        Gary

        --
        Gary Johnson | Agilent Technologies
        garyjohn@... | Mobile Broadband Division
        | Spokane, Washington, USA
      • Charles E Campbell Jr
        ... See DrawIt s help, lines 253-256. The visual-block commands require spaces to work in. Most of these commands are imported from Sylvain Viart s
        Message 3 of 6 , May 2, 2007
        • 0 Attachment
          Gary Johnson wrote:

          >On 2007-05-02, Charles E Campbell Jr <drchip@...> wrote:
          >
          >
          >> Yakov Lerner wrote:
          >>
          >>
          >>
          >>>I 'set ve=all' and selected a rectangle with Ctrl-V.
          >>>How can I move this rectangle up/down left/right with arrows ?
          >>>
          >>>
          >> With DrawIt v8d, you can move a selected rectangle about with your mouse.
          >> Here's the relevant portion of the help for DrawIt:
          >>
          >> <ctrl-leftmouse>
          >>
          >> One may drag and move a selection with <ctrl-leftmouse>. First,
          >> select the region using the <leftmouse>. Release the mouse button,
          >> then press ctrl and the <leftmouse> button; while continuing to press
          >> the button, move the mouse. The selected block of text will then
          >> move along with the cursor.
          >>
          >>
          >
          >Unfortunately, this works only for gvim, not vim. <ctrl-leftmouse>
          >in an xterm opens the Main Options menu.
          >
          >
          >
          >> Here's how to get & install DrawIt (when 7.1 comes out, this will become
          >> lots easier - just steps 3&4)
          >>
          >>
          >
          >
          >
          >> 3) Get DrawIt:
          >> http://vim.sourceforge.net/scripts/script.php?script_id=40
          >> http://mysite.verizon.net/astronaut/vim/index.html#DRAWIT
          >>
          >> 4) Install an up-to-date version of Drawit:
          >> vim DrawIt.vba.gz
          >> :so %
          >> :q
          >>
          >>
          >>
          >
          >One may need to uninstall (i.e., delete) any earlier version of
          >DrawIt, too, specifically the file ~/.vim/plugin/DrawIt.vim. The
          >symptoms of needing to do this include vim complaining at startup
          >that \di has been defined twice.
          >
          >I use the line-drawing capability of DrawIt all the time. I haven't
          >done much with the visual-block commands, so I thought I'd try one.
          >I think I found a bug in the version of DrawIt from the astronaut
          >site.
          >
          >I inserted the following two paragraphs of text into a buffer,
          >started DrawIt by typing \di, left-clicked the mouse on the
          >character in the upper left corner of the region (the 'e' in
          >"everywhere", no longer visible below), dragged the visual selection
          >to the lower right corner, and typed \b to draw a box.
          >
          > Mary had a little lamb,
          > Its fleece was white as snow,
          > And +------------------+ went,
          > The |amb was sure to go|
          >||
          > It f|llowed her to scho|l one day,
          > Whic+------------------+le,
          > And made the children laugh and play
          > To see a lamb at school.
          >
          >Note that the two bars between the paragraphs are in columns 1 and 2
          >instead of 8 and 27.
          >
          >
          See DrawIt's help, lines 253-256. The visual-block commands require
          spaces to work in.
          Most of these commands are imported from Sylvain Viart's drawing.vim; I
          haven't tried
          making the "holer" routine obsolete yet.

          Regards,
          Chip Campbell
        Your message has been successfully submitted and would be delivered to recipients shortly.