Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Vim sign column toggle

Tags:

vim

When signs are defined in Vim, a column appears at the left of the screen.

From the Vim help:

When signs are defined for a file, Vim will automatically add a column of two
characters to display them in. When the last sign is unplaced the column
disappears again.

Is it possible to remove the column whilst there are still signs defined?

Ideally I would like to toggle the column on / off.

like image 525
aaren Avatar asked Aug 19 '13 17:08

aaren


1 Answers

If you are using Vim 8.0 or newer (or NeoVim), this is now a simple setting:

$ vim "+help signcolumn" "+only"

For instance,

:set scl=no   " force the signcolumn to disappear
:set scl=yes  " force the signcolumn to appear
:set scl=auto " return the signcolumn to the default behaviour
like image 100
ELLIOTTCABLE Avatar answered Nov 16 '22 00:11

ELLIOTTCABLE