[prev in list] [next in list] [prev in thread] [next in thread] 

List:       vim
Subject:    Re: multi-mark
From:       "Yegappan Lakshmanan" <yegappanl () gmail ! com>
Date:       2006-12-21 21:59:15
Message-ID: 8671d6a0612211359p6459fae7ifd85ce38b7f07d0b () mail ! gmail ! com
[Download RAW message or body]

Hi,

On 12/21/06, Alan G Isaac <aisaac@american.edu> wrote:
> On Thu, 21 Dec 2006, Yakov Lerner apparently wrote:
> > I am looking for the "multi-marks" plugin.
> > I want to "mark" multilpe lines (not with 'a,'b,'c, but with
> > some kind of mark that can mark multiple lines),
> > then cycle through the marked lines.
>
> I believe the request for anonymous marks comes up about
> once a year.  Here was a specific proposal:
> http://permalink.gmane.org/gmane.editors.vim/16693
> I agree it would be a useful feature.
> I found the implementation in the TextPad editor very useful.
>

You can use the Vim7 location list feature to implement the
anonymous marks support.

Each Vim window can have a separate location list. You
can have more than one location list for a single window.

To add the current line and file to the location list, use the
":laddexpr" command:

  :laddexpr expand("%") . ":" . line('.') . ":" . ":" . getline('.')

To remove a location from the location list, get the location
list using the getloclist() function, remove the desired line
from the returned List and then set the location list using
the setloclist() function.

To browse the list of locations, use the various location
list commands like ":llist", ":lnext", ":lprevious", ":lnfile",
":lpfile", etc.

To switch between the location lists for a single window,
use the ":lolder" and ":lnewer" commands.

- Yegappan
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic