diff --git a/autoload/signature/sign.vim b/autoload/signature/sign.vim index 2ba66d8..bee78c7 100644 --- a/autoload/signature/sign.vim +++ b/autoload/signature/sign.vim @@ -201,8 +201,8 @@ function! signature#sign#ToggleDummy(...) " Arguments: (optional) 0 : force remove " 1 : force place - let l:place = a:0 ? a:1 : (len(b:sig_marks) + len(b:sig_markers) == 1) && !b:sig_DummyExists - let l:remove = a:0 ? !a:1 : (len(b:sig_marks) + len(b:sig_markers) == 0) && b:sig_DummyExists + let l:place = a:0 ? a:1 : (g:SignatureGutterAlwaysOn ? 1 : len(b:sig_marks) + len(b:sig_markers) == 1) && !b:sig_DummyExists + let l:remove = a:0 ? !a:1 : (g:SignatureGutterAlwaysOn ? 0 : len(b:sig_marks) + len(b:sig_markers) == 0) && b:sig_DummyExists if (l:place) sign define Signature_Dummy diff --git a/doc/signature.txt b/doc/signature.txt index 43c3fe3..0bf1b60 100644 --- a/doc/signature.txt +++ b/doc/signature.txt @@ -373,6 +373,13 @@ etc. These are not defined by default When set to 1, will always place markers instead of toggling them + *g:SignatureGutterAlwaysOn* + Boolean, Default: 0 + + When set to 1, will always display the gutter irrespective of whether there + are currently any marks to show or not. + + ============================================================================== 4. Contributing *SignatureContributing* diff --git a/plugin/signature.vim b/plugin/signature.vim index f8376b9..9783c40 100644 --- a/plugin/signature.vim +++ b/plugin/signature.vim @@ -39,6 +39,7 @@ call signature#utils#Set('g:SignatureErrorIfNoAvailableMarks', 1 call signature#utils#Set('g:SignatureForceRemoveGlobal', 0 ) call signature#utils#Set('g:SignatureForceMarkPlacement', 0 ) call signature#utils#Set('g:SignatureForceMarkerPlacement', 0 ) +call signature#utils#Set('g:SignatureGutterAlwaysOn', 0 ) call signature#utils#Set('g:SignatureMap', {} )