benstaniford / vim-bargreybars

bargreybars.vim: remove gray bars from maximised gvim windows, on Windows

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

bargreybars.vim

Gvim windows have a grey background hidden behind the text area. When maximised their dimensions are not a multiple of the font size, so the background shows up as grey bars on the right and bottom side of the windows.

The goggles do nothing!

This plugin keeps the windows background in sync with your color scheme.

Nice and uniform

Grey bars gone, the world is safe again!

Note: the plugin works only on Windows. GTK-based Vim can be tweaked in a different way, and the issue has been reported in the Vim tracker.

Features

By default, bargreybars.vim runs automatically when you start gvim and when you switch colorscheme. This behaviour can be disabled in your .vimrc file with:

let g:bargreybars_auto = 0

If the automatic color-matching is disabled, you can use the Colorscheme command to apply a scheme and match the window background color. It works the same way as the standard colorscheme command.

:Colorscheme zenburn

Installation

The plugin is compatible with pathogen.vim and a similar plugin managers.

Here's the clone command for you copy-paste convenience:

git clone https://github.com/dreadnaut/vim-bargreybars.git

There, no further configuration is needed, you are ready to go.

Building the dll from source

The plugin relies on a C library that modifies the window attributes. It is heavily inspired by gvimfullscreen, and compatible with it. Source code for the library is included in the dll directory.

The x86 dll in the repository is built with the Visual C++ 2015 Build Tools. The code also compiles as x64.

Choose your target environment by opening the correct Visual C++ command prompt, then build the dll file with nmake, the included batch script, or the command below —I like options.

cl.exe /LD bargreybars.c Gdi32.lib User32.lib

About

bargreybars.vim: remove gray bars from maximised gvim windows, on Windows

License:GNU General Public License v3.0


Languages

Language:C 50.9%Language:Vim Script 45.1%Language:Makefile 3.0%Language:Batchfile 1.0%