vile
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [vile] under-cursor


From: Thomas Dickey
Subject: Re: [vile] under-cursor
Date: Thu, 11 Apr 2013 04:36:33 -0400
User-agent: Mutt/1.5.20 (2009-06-14)

On Fri, Mar 22, 2013 at 08:05:20PM -0400, Wayne Cuddy wrote:
> On Fri, Mar 22, 2013 at 06:32:11PM -0400, Thomas Dickey wrote:
> > On Fri, Mar 22, 2013 at 12:41:52PM -0400, Wayne Cuddy wrote:
> > > On Thu, Mar 21, 2013 at 07:08:52PM -0400, Thomas Dickey wrote:
> > > > 
> > > > Since it's a writable mode, you could in principle redefine it.  The 
> > > > only
> > > > gotcha is that it starts from the current position, so you would get
> > > > interesting matches.
> > > 
> > > I'm not sure I understand the implications of this comment. It starts
> > > from the current position right now correct? So the behavior would be
> > > the same I think.
> > 
> > yes - I was partly thinking aloud, trying to recall which uses would
> > search back to the beginning of the word (tags do).  It might be nice
> > to have the option to use that behavior in macros.
> 
> Indeed it would, I find that 99% of time I'd prefer that behavior. I
> think it's rare to be searching for a half word.

hmm - still working on 9.8j, I have 3-4 items left.  On this one, I had
in mind adding a buffer mode, but see that what you're asking for is
already doable.  There are two related features:

   tagword (tw)
           When scanning the word to lookup from the cursor position for the
           tags mechanism, grab the whole word rather than the substring
           starting at the cursor position. The latter, which is vi-like, is
           the default. (B)

   |---------------------+--------------------------------------------------|
   | $get-it-all         | match entire "identifier-like" word under the    |
   |                     | cursor.                                          |
   |---------------------+--------------------------------------------------|

The $get-it-all variable is used when computing $identifier, and is useful
for scripting.  Both it and tagword default to false (for the usual legacy
and compatibility reasons).  There might be some additional case where
neither of those applies, but starting from these, we can see if/how to
improve it.

-- 
Thomas E. Dickey <address@hidden>
http://invisible-island.net
ftp://invisible-island.net

Attachment: signature.asc
Description: Digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]