Tuesday, May 28, 2013

Re: use of vim signs


On May 28, 2013 10:43 PM, "Marc Weber" <marco-oweber@gmx.de> wrote:
>
> Excerpts from glts's message of Tue May 28 20:22:35 +0200 2013:
> > - ":set nonu nornu" means: I don't want any line numbers;
> > - ":set nu nornu" means: I want to see only absolute numbers;
> > - ":set nonu rnu" means: I want to see only relative numbers;
> > - ":set nu rnu" means: I want to have the best of both worlds.
> fun myfun(absolute_number, cursor_pos)
>   return format(.. whatever you want)
> endfun
>
> Why not 'line_number_fun=myfun()'
>
> The it would be you being able to control contents of the bar, whatever
> you want to be there ..

If you want to be generic, it would be better to use

    set columnfunctions=myfun1,myfun2,myfun3

. All functions should return a 2-tuple (hl group, text). This way you don't need to choose whether you want a error marker or a change marker from the plugin described earlier. This suggestion is mainly a replacement for signs, but it is just as good for numbers.

> Marc Weber
>
> --
> --
> 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.
>
>

--
--
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:

Post a Comment