Behavior of <space> and <backspace>

12 views
Skip to first unread message

Justin M. Keyes

unread,
May 4, 2015, 11:33:44 PM5/4/15
to vim_use
With "vim -u NONE -N", given the following text:

ABC
DEF

- With cursor on D, <backspace> moves to C.
- With cursor on D, `h` does nothing.
- With cursor on C, <space> moves to D.
- With cursor on C, `l` does nothing.

Where is this documented? Is this behavior affected by any options?
Note that "vim -u NONE -C" (Vi-compatible) does not behave in this
way.

":help <space>" implies that <space> is equivalent to `l`, which is
clearly wrong. Likewise for ":help <backspace>".

Thanks.

Justin M. Keyes

Nikolay Pavlov

unread,
May 4, 2015, 11:41:34 PM5/4/15
to vim...@googlegroups.com
2015-05-05 6:32 GMT+03:00 Justin M. Keyes <just...@gmail.com>:
> With "vim -u NONE -N", given the following text:
>
> ABC
> DEF
>
> - With cursor on D, <backspace> moves to C.
> - With cursor on D, `h` does nothing.
> - With cursor on C, <space> moves to D.
> - With cursor on C, `l` does nothing.
>
> Where is this documented? Is this behavior affected by any options?

This behaviour is affected by &whichwrap option.

> Note that "vim -u NONE -C" (Vi-compatible) does not behave in this
> way.
>
> ":help <space>" implies that <space> is equivalent to `l`, which is
> clearly wrong. Likewise for ":help <backspace>".

It is not that wrong. Just space and l, as well as backspace and h can
be configured separately by &whichwrap option and Vim defaults make
them behave differently.

>
> Thanks.
>
> Justin M. Keyes
>
> --
> --
> 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+u...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

Justin M. Keyes

unread,
May 5, 2015, 12:36:57 AM5/5/15
to vim_use
On Mon, May 4, 2015 at 11:41 PM, Nikolay Pavlov <zyx...@gmail.com> wrote:
> 2015-05-05 6:32 GMT+03:00 Justin M. Keyes <just...@gmail.com>:
>> With "vim -u NONE -N", given the following text:
>>
>> ABC
>> DEF
>>
>> - With cursor on D, <backspace> moves to C.
>> - With cursor on D, `h` does nothing.
>> - With cursor on C, <space> moves to D.
>> - With cursor on C, `l` does nothing.
>>
>> Where is this documented? Is this behavior affected by any options?
>
> This behaviour is affected by &whichwrap option.
>
>> Note that "vim -u NONE -C" (Vi-compatible) does not behave in this
>> way.
>>
>> ":help <space>" implies that <space> is equivalent to `l`, which is
>> clearly wrong. Likewise for ":help <backspace>".
>
> It is not that wrong. Just space and l, as well as backspace and h can
> be configured separately by &whichwrap option and Vim defaults make
> them behave differently.

Thanks! A mention of |whichwrap| at :help <space> would be intuitive.

Justin M. Keyes
Reply all
Reply to author
Forward
0 new messages