Wednesday, June 27, 2012

Re: Ensuring unique sign IDs

Ben Fritz wrote:
> :help :sign-place says:
>
> It's up to the user to make sure the {id} is used only once in
> each file (if it's used several times unplacing will also have
> to be done several times and making changes may not work as
> expected).
>
> While it is easy enough to ensure that any one given plugin does not
> re-use signs, what is a good way to ensure that multiple plugins don't use
> overlapping signs?
>
> I can check the redirected output of :sign place buffer={buffer number}
> before I place any signs, but I'd guess not all plugin authors do this, so
> they could clobber my signs fairly easily.
>
> Is this the recommended approach or is the problem mostly ignored?
>
>
May I suggest looking into my RltvNmbr plugin
(http://www.drchip.org/astronaut/vim/index.html#RLTVNMBR) and glancing
at its "s:AvoidOtherSigns()" function.

Regards,
Chip Campbell

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

No comments: