GithubHelp home page GithubHelp logo

konstruktionist / vim-neatstatus Goto Github PK

View Code? Open in Web Editor NEW

This project forked from maciakl/vim-neatstatus

0.0 1.0 0.0 199 KB

Neat Status Line Plugin for Vim

Home Page: http://www.vim.org/scripts/script.php?script_id=4587

Vim Script 100.00%

vim-neatstatus's Introduction

Neat Status Line

Yet another status line plugin. The aim of Neat Status is to provide neat, and simple UI with just basic information and no bells and whistles for those users who consider things like Powerline to be overkill.

Neat Status is loosely based on the status line script created by Tomas Restrepo. The original can be seen here:

The basic idea is roughly the same, but the script was heavily modified and made more customizable and modular to work better as a plugin rather than just a .vimrc snippet.

Note: this is not a drop-in replacement for Powerline but rather a much simpler and streamlined plugin. The aim of the project is not to achieve one to one feature compatibility but merely to implement a narrow subset of said features for users who want something simple and easy. If you would like a robust, feature-full Powerline replacement you should check out Vim-Airline.

Screenshots

Here is how this status line will look in Gvim on Windows with the Solarized color scheme:

Neat Statusline

Information provided from left to right:

  • Mode Indicator - changes color depending on the editor mode
  • Server/Session - displays vim servername (graphical) or terminal name (cli)
  • File path for the file associated with current buffer
  • File type (eg. python, ruby, etc..)
  • File format (eg. unix, dos, etc..)
  • File encoding (eg. utf8, latin1, etc..)
  • Buffer number
  • Current line, total number of lines (purple box)
  • Percentage of file read
  • Relative column number (from first character)
  • Absolute column number (from start of line)
  • Modified / Unmodified (blue box)

Installation

To install with Pathogen:

cd ~/.vim/bundle
git clone git://github.com/maciakl/vim-neatstatus.git

If your .vim is under source control with Git do this instead:

cd ~/.vim
git submodule add git://github.com/maciakl/vim-neatstatus.git bundle/vim-neatstatus
git submodule init
git submodule update

Installing without pathogen:

  • Copy neatstatus.vim to ~/.vim/after/plugins directory

Configuration

You can configure the colors of the status line elements by defining the following global vars in your .vimrc:

  • g:NeatStatusLine_color_normal - the color of the mode indicator when in normal mode
  • g:NeatStatusLine_color_insert - the color of the mode indicator when in insert mode
  • g:NeatStatusLine_color_replace - the color of the mode indicator when in replace mode
  • g:NeatStatusLine_color_position - the color of the cursor position box (and session box)
  • g:NeatStatusLine_color_line - the color of the line number in the cursor position box
  • g:NeatStatusLine_color_modified - the color of the "modified" indicator on the right
  • g:NeatStatusLine_color_filetype - the color of the filetype box

Make sure you define values both for graphical and terminal clients when you do this. Here is a quick example that shows you hot to redefine the insert mode colors:

let g:NeatStatusLine_color_insert = 'guifg=#ffffff guibg=#ff0000 gui=bold ctermfg=15 ctermbg=9 cterm=bold'

Note that these only affect the small boxes created by NeatStatus. Your status line will remain the default color as per your color scheme. This works very well if you also happen to use the Obvious-Mode plugin.

If you want to style your status line, you can do it in your .vimrc normally using the hi StatusLine and hi StatusLineNC commands.

You can also change the separator character that divides the boxes by changing:

  • g:NeatStatusLine_separator

By default the separator is set to the pipe | character. You can disable the separator by setting it to empty string.

vim-neatstatus's People

Contributors

maciakl avatar

Watchers

 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.