Hello Benjamin,
Excerpt from Benjamin R. Haskell: > Three related questions about statusline: > > 1. The help for 'stl' states that the statusline will be evaluated with· > each window (and buffer) set to the current window (and buffer). So, is· > it a bug in the following that the local settings of the current window· > are mirrored in all statusline entries? (Version info below¹) I currently working on something similar it seems. This has helped me: http://vim.1045645.n5.nabble.com/wish-different-statusline-format-for-noncurrent-statusline-td1209896.html > " This isn't what I'm actually doing in my function > " It's just a reduced test case > fun! StatusLine() > let indent = '('.repeat('·', &l:sw).')' > let cole = &l:cole ? ' ['.&l:cole.']' : '' > return indent . cole > endf > > let &stl = '%!StatusLine()' > > 2. Is there a way to access the 'actual_curbuf' variable from within a· > function called as part of 'stl'? > > E.g.: > se stl=%!StatusLine() > fun! StatusLine() > " access actual_curbuf from here? > endf > > > 3. Trying a non-function approach, should the following work (change the· > highlighting for non-current statuslines)? > > let &stl = '%<%f%{bufnr("")==actual_curbuf?"":"%#Error#"}blahblahblah' -- <snip> -- -- Regards, Thilo 4096R/0xC70B1A8F 721B 1BA0 095C 1ABA 3FC6 7C18 89A4 A2A0 C70B 1A8F -- 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
