On 2015-05-26 19:10:30 +0000, Nikolay Pavlov said:
>> All works as expected (including <C-w><C-o>!) if I open windows with :new,
>> :vnew, etc...
>> But when I split a window, say with <C-w><C-s>, SetupLocalStatusLine()
>> is not called, which means that somehow the current &l:statusline is
>> re-used. The rest
>> is just a consequence of that. I have no idea how to fix this.
>>
>> I have also noticed that when I split a window, BuildStatusLine() is called
>> three times, while
>> I'd expect it to be called twice (once per split window). Is that expected
>> behaviour?
>
> Ah, now I remember that bug that appeared years ago in powerline.
>
> Fix that powerline uses is simple: SetupLocalStatusLine is called each
> time. Specifically this is why I had an advice not to set &statusline
> value if it is correct:
> [snip]
Simply brilliant. It works like a charm!
> : this one will update get window number and update &stl value if
> necessary. To be called always. Highly optimized (main VimL
> optimization principle: the less Ex commands the better: additional
> getwinvar() calls are nothing compared to additional :let, not to
> mention cycle which is at least two (:for and :endfor) commands
> multiplied by a number of windows).
I'm glad I have decided to implement my own status line instead of
using a plugin: I am learning a lot along the way.
Thanks,
Nicola
--
--
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/d/optout.
Tuesday, May 26, 2015
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment