Re: viw / how to select a one char word ?

2020-02-05 Thread M Kelly
Hi,

Yes, I'll wager this has something to do with my terminal and its terminfo 
capabilities.

thx,
-m

On Monday, February 3, 2020 at 8:45:14 AM UTC-5, Tony Mechelynck wrote:
>
> On Mon, Feb 3, 2020 at 2:33 PM M Kelly > 
> wrote: 
> > 
> > Hi, 
> > 
> > ok I found my error and fixed it. It was in a bad vmap I had for iw 
> > Thank you all, as always, for the info. 
> > Now I think 'viw' works well for me in all cases :-) 
> > I wish the one char word, when selected, changed colour but not a 
> problem. 
>
> In my gvim the one-character visually selected word's Visual highlight 
> is visible during the "off" phase of the blinking cursor; and with 
> 'showcmd' on the number of characters (and bytes, if different) in the 
> selection is displayed near bottom right of the Vim screen. 
>
> Best regards, 
> Tony. 
>

-- 
-- 
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_use+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_use/3f324d66-cb05-4088-a500-142d901d9345%40googlegroups.com.


Re: Triplicate text after mix-matching vim and nvi

2020-02-05 Thread Tim Chase
On 2020-02-05 08:38, 'Ottavio Caruso' via vim_use wrote:
> the command works in both vim and nvi. The remap only in vim. I'll
> try to find a way of making it work in nvi, but this would be off
> topic.

Ah, good point.  The "" notation is a vim thing.  You can either
use some other key such as "Q"

  :map Q :1m$^M

where ^M is entered using control+V followed by control+M

(just tested in the nvi that I have here on FreeBSD)

Alternatively, if you know the escape sequence for the key you want
such as F5, you might be able to enter it literally, escaping with
control+V as above.

(as I type this, your follow-up email arrived where you do just that)

> (BTW: if anybody knows a of a vi/nvi mailing list or usenet group,
> please let me know, on of off list)

I think this list is the closest there is.  I regularly use vi/nvi,
vim, and ed(1), and occasionally neovim.  I'm sure there are others.
There's enough overlap between vi/nvi and vim/neovim that even if
you're asking questions about vi/nvi here, you'll hopefully get some
good answers.  It also helps get relevant answers if you mention that
your question is about vi/nvi instead of vim, so folks don't try to
reply with vim-specific answers.

-tim


-- 
-- 
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_use+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_use/20200205072126.224f67a3%40bigbox.attlocal.net.


Re: Triplicate text after mix-matching vim and nvi

2020-02-05 Thread 'Ottavio Caruso' via vim_use
On Wed, 5 Feb 2020 at 08:38, Ottavio Caruso
 wrote:
>
> On Tue, 4 Feb 2020 at 14:10, Christian Brabandt  wrote:
> >
> >
> > On Di, 04 Feb 2020, Tim Chase wrote:
> >
> > > On 2020-02-04 14:43, Christian Brabandt wrote:
> > > > On Di, 04 Feb 2020, 'Ottavio Caruso' via vim_use wrote:
> > > > > 1) dd
> > > > > 2) [shift] + g
> > > > > 3) p
> > > >
> > > > :1t$
> > >
> > > That copies where Ottavio's command sequence moves, so he'd want
> > >
> > > :1m$
> > >
> >
> > Oh, yes he wanted to move and not copy. Sorry.
>
> Tim & Christian,
>
> the command works in both vim and nvi. The remap only in vim. I'll try
> to find a way of making it work in nvi, but this would be off topic.

Correction: I had to prefix the maps with [ctrl]+v and now it works on nvi too:

nvi:
map ^[[15~ :1m$^M

vim:
map  :1m$

Thanks Tony, Christian and Tim!


-- 
Ottavio Caruso

-- 
-- 
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_use+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_use/CAEJNuHziw5NHqJYsTMPPCnD7Md%3DLBCKx2tV7Okq%2B7%3DY8r7X8%3DA%40mail.gmail.com.


Re: Triplicate text after mix-matching vim and nvi

2020-02-05 Thread 'Ottavio Caruso' via vim_use
On Tue, 4 Feb 2020 at 14:10, Christian Brabandt  wrote:
>
>
> On Di, 04 Feb 2020, Tim Chase wrote:
>
> > On 2020-02-04 14:43, Christian Brabandt wrote:
> > > On Di, 04 Feb 2020, 'Ottavio Caruso' via vim_use wrote:
> > > > 1) dd
> > > > 2) [shift] + g
> > > > 3) p
> > >
> > > :1t$
> >
> > That copies where Ottavio's command sequence moves, so he'd want
> >
> > :1m$
> >
>
> Oh, yes he wanted to move and not copy. Sorry.

Tim & Christian,

the command works in both vim and nvi. The remap only in vim. I'll try
to find a way of making it work in nvi, but this would be off topic.

(BTW: if anybody knows a of a vi/nvi mailing list or usenet group,
please let me know, on of off list)

-- 
Ottavio Caruso

-- 
-- 
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_use+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_use/CAEJNuHwe6cXd%2BRNQOuzmm1-16uZ2DCJA8WFbV5mkQT_SSRf7Ow%40mail.gmail.com.


Re: Triplicate text after mix-matching vim and nvi

2020-02-05 Thread 'Ottavio Caruso' via vim_use
On Tue, 4 Feb 2020 at 13:27, Tony Mechelynck
 wrote:

> The following mapping will move the first line from top to bottom of
> the file (at least in Vim in 'nocompatible' mode, I'm not sure about
> vi (or 'compatible' Vim) and nvi):
>
> :map  :1d$put
>
> ( rather than | to avoid interpreting the rest when declaring the
> mapping rather than when executing it). Of course you can use any
> convenirnt {lhs} instead of 
>

Thanks. The remap works in vim but not in vi, probably because I'm
using the wrong syntax.

-- 
Ottavio Caruso

-- 
-- 
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_use+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_use/CAEJNuHx8ypGffZQGabrvoff0aM9yca5QxsL3JgkgGy1TcbkBAA%40mail.gmail.com.