Wednesday, May 29, 2013

Re: Why use relative line numbers?

On Do, 30 Mai 2013, Marc Weber wrote:

> Well - relative line numbers were introduced to solve a problem (navigating).
>
> What do relative line numbers do?
> + they show you where the cursor is (you could miss this)
> + they allow to navigate using less keys
>
> issues:
> - they slow you down. If I open :h having 'relativenumbers' set on 9k is
> signifcantly slower ! (at least for me having 230 lines)

Of course it is, because Vim needs to redraw more often, since the
numbers change on almost every move of the cursor. This is also true for
'cursorline'/'cursorcolumn' option.

> I hope that this is a somewhat accurate description about pro/cons of
> relativenumbers feature.
>
> The alternative I proposed does not suffer from the slowness, and G j k
> like movements could be made understanding 'lasts digits' only.

No, because it doesn't work for each use case as has been pointed out,
plus it doesn't work reliably (as you also state in your snippet). So it
is no complete alternative.

> Anyway if you love it and already have a solution - then go for it.

In the thread I mentioned, Bram already said, he doesn't like to remove
or deprecate options.

regards,
Christian
--
Wie viele Jahre Gefängnis entfallen auf die
tausendneunhundertsiebenundfünfzig Jahre nach Christus?
-- Stanislaw Jerzy Lec (eig. S. J. de Tusch-Letz)

--
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

No comments: