Coder Social home page Coder Social logo

taboo.vim's Introduction

taboo.vim

Taboo aims to ease the way you set the vim tabline. In addition, Taboo provides fews useful utilities for renaming tabs.

Installation

Install either with Vundle, Pathogen or Neobundle.

NOTE: tabs look different in terminal vim than in gui versions. If you wish having terminal style tabs even in gui versions you have to add the following line to your .vimrc file

set guioptions-=e

Taboo is able to remember tab names when you save the current session but you are required to set the following option in your .vimrc file

set sessionoptions+=tabpages,globals

Commands

  • TabooRename <tabname> Renames the current tab with the name provided.
  • TabooOpen <tabname> Opens a new tab and and gives it the name provided.
  • TabooReset Removes the custom label associated with the current tab.

Basic options

g:taboo_tab_format

With this option you can customize the look of tabs. Below all the available items:

  • %f: the name of the first buffer open in the tab
  • %a: the path relative to $HOME of the first buffer open in the tab
  • %n: the tab number, but only on the active tab
  • %N: the tab number on each tab
  • %w: the number of windows opened into the tab, but only on the active tab
  • %W: the number of windows opened into the tab, on each tab
  • %u: same as %w, but using unicode characters
  • %U: same as %W, but using unicode characters
  • %m: the modified flag
  • %p: the tab current working directory
  • %P: the last component of the tab current working directory

Default: " %f%m "

g:taboo_renamed_tab_format

Same as g:taboo_tab_format but for renamed tabs. In addition, you can use the following items:

  • %l: the custom tab name set with :TabooRename

NOTE: with renamed tabs the items %f and %a will be evaluated to an empty string.

Default: " [%l]%m "

g:taboo_modified_tab_flag

This option controls how the modified flag looks like.

Default: "*"

g:taboo_tabline

Turn off this option and Taboo won't generate the tabline. This may be useful if you want to do it yourself with the help of the functions TabooTabTitle(..) or TabooTabName(..).

Default: 1

Public interface

Taboo provides a couple of public functions that may be used by third party plugins:

  • TabooTabTitle(tabnumber) -> string

    This function returns the formatted tab title according to the options g:taboo_tab_format and g:taboo_renamed_tab_format (for renamed tabs).

  • TabooTabName(tabnumber) -> string

    This function returns the name of a renamed tab. If a tab has no name, an empty string is returned.

taboo.vim's People

Contributors

ryanflannery avatar manicolosi avatar darthgandalf avatar choco avatar gcmt avatar gryftir avatar ipod825 avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.