Deprecated, use wintabs instead
Vim script
Clone or download
Pull request Compare This branch is 19 commits ahead of vim-scripts:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.


This is a fork of


This is a simple script that shows a tabs-like list of buffers in the 
statusline. The biggest advantage of this script over various others is that 
it does not create new window, and thus will not conflit with other navigation 
plugins such as nerdtree.


a few opened files in one window:
3 windows - nerdtree, help and files:
3 windows - fugitive and files:

(color scheme used in screenshots is


Just copy the file to vim plugin directory, it will start showing buffer list 
on your statusline. By default, it will take over the entire statusline; but 
if you want to use only part of the statusline for buftabs, please check the 
configuration options below.

It might be handy to create a few maps for easy switching of buffers in your
.vimrc file. For example:

  noremap <F1> :bprev!<CR>
  noremap <F2> :bnext!<CR>
  noremap <F4> :confirm bd<CR>


The following extra configuration variables are availabe:

* statusline

  By default buftabs will take up the whole statusline. You can
  alternatively specify precisely where it goes using #{buftabs} e.g.:

  :set laststatus=2
  :set statusline=\ #{buftabs}%=\ \ Ln\ %-5.5l\ Col\ %-4.4v

  NOTICE: If you customize your statusline like above, you will HAVE to 
  specify the total charactor length of non-buftabs components in the 
  statusline. By default, it is 0 since there are no other components. To 

  " for the example statusline above, length of other components is 20
  :let g:buftabs_other_components_length=20

* g:buftabs_active_highlight_group (default '')

  The name of a highlight group (:help highligh-groups) which is used to
  show the name of the current active buffer. To change:

  :let g:buftabs_active_highlight_group="Visual"

* g:buftabs_only_basename (default 1)

  This variable makes buftabs only print the filename of each buffer,
  omitting the preceding directory name. To unset:

  :let g:buftabs_only_basename=0

* g:buftabs_show_number     1
* g:buftabs_marker_start    [
* g:buftabs_marker_end      ]
* g:buftabs_separator       -
* g:buftabs_marker_modified !

  These strings are drawn around each tab as separators, the 'marker_modified' 
  symbol is used to denote a modified (unsaved) buffer. If
  'buftabs_show_number' is set to 0, neither buffer number nor separator is
  shown. To change:

  :let g:buftabs_separator = "."  
  :let g:buftabs_marker_start = " "
  :let g:buftabs_marker_end = " "
  :let g:buftabs_marker_modified = " +"

* g:buftabs_blacklist (default ["^NERD_tree_[0-9]*$"])

  You might not want to show buftabs when working with some buffers (e.g.
  NERDtree). You can add patterns of these buffer names to

  :let g:buftabs_blacklist = ["^NERD_tree_[0-9]*$", "^__Tagbar__$"]