tabline
Solution: Add a new option which inverses the position of buffer and
tabs
If switch_buffer_and_tabs is 0 (default) buffer are on the left and tabs
on the right else if is 1 the order is reversed.
This is a new tabline extension, that displays both the buffers open and
the available tabs. This has been requested by #639 and fixes#639.
This is based on blings work on branch spike.
This uses the new highlight groups tab*_right, so that the separators
have the correct color. Also this makes some configuration variable
obsolete and therefore, they have been removed.
remove unused combined config variable, remove space after tab
This should make the buflist algorithm faster.
Also there is an alternative implementation in branch 535 available,
which avoids looping over the complete range, I'll stay with the current
approach, as it does not depend on BufAdd/BufDelete autocommands.
details:
instead of testing for buflisted() and bufexists() we only test for
buflisted() because, this also tests for the existence of the buffer.
Also instead of a second loop of the exclude patterns, we'll join all
of them together with '\|' and check if they match the current buffer.
The rest of the conditions have been joined into a single condition.
This together made up an improvement of
Orig:
FUNCTION airline#extensions#tabline#buflist#list()
Called 94 times
Total time: 0.267305
Self time: 0.267305
New:
FUNCTION airline#extensions#tabline#buflist#list()
Called 85 times
Total time: 0.124572
Self time: 0.124572
Solution: Use the current one from ctrlspace 5.0 + minor style fixes
Problem: CtrlSpace 5.0 does no longer work with airline
Solution: Modify the ctrlspace extension to call the new APIs
The statusline work fine but the custom ctrlspace function
somehow/somewhere gets overridden and I could not figure out where.
Therefore the user must add
let g:CtrlSpaceStatuslineFunction = "airline#extensions#ctrlspace#statusline()"
to its .vimrc.
Problem: Ctrlspace 5.0 does not integrate well into tabline
Solution: Write a tabline extensions for ctrlspace 5.0.
The extensions is capable of showing both tabs and buffers, but only the
buffers of a current tab are shown.
This commit resolves compatibility issue with fugitive plugin. When
using "Gdiff" command on some file, fugitive attempts to open the
current and the index version of the file. For example, if the file is
/home/taketwo/path/to/the/project/README.md
then fugitive will use the following path to open the index version:
fugitive:///home/taketwo/path/to/the/project/.git//0/README.md
Opening this file leads to a cascade of errors like this:
Error detected while processing function
airline#extensions#tabline#get..<SNR>162_get_buffers..<SNR>162_get_visible_buffers..airline#extensions#tabline#get_buffer_name..airline#extensions#tabline#unique_tail_improved#format:
line 20:
E713: Cannot use empty key for Dictionary
The problem is that when a filename like this is being tokenized, there
appear empty "" tokens, and an error occurs when using them as keys in
`path_tokens[token_index]` dictionary. This fix simply skips empty
tokens.