From: Heikki Junes Date: Thu, 11 Mar 2004 22:52:08 +0000 (+0000) Subject: change to (default). X-Git-Tag: release/2.1.31~23 X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=e657f59b0c629a4274cf0cea0eb6694e92ed4b5e;p=lilypond.git change to (default). --- diff --git a/ChangeLog b/ChangeLog index 1e9d507928..9d5f84c792 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,7 +1,7 @@ 2004-03-12 Heikki Junes - * vim/lilypond-indent.vim: use is indent character in - insert-mode. add indenting rules. + * vim/lilypond-indent.vim: use (default) as indent key + in insert-mode. add indenting rules. 2004-03-11 Jan Nieuwenhuizen diff --git a/vim/lilypond-indent.vim b/vim/lilypond-indent.vim index 1f6c681e3b..ea2523a135 100644 --- a/vim/lilypond-indent.vim +++ b/vim/lilypond-indent.vim @@ -10,7 +10,7 @@ endif let b:did_indent = 1 setlocal indentexpr=GetLilyPondIndent() -setlocal indentkeys+==},>>,! +setlocal indentkeys+==},>>,!^F " Only define the function once. if exists("*GetLilyPondIndent") @@ -24,15 +24,15 @@ function GetLilyPondIndent() "Find a non-blank line above the current line. let lnum = prevnonblank(v:lnum - 1) - "Check if a block was started: '{' or '<<' is the last non-blank character of the line. + "Check if a block was started: '{' or '<<' is the last non-blank character of the previous line. if getline(lnum) =~ '^.*\({\|<<\)\s*$' let ind = indent(lnum) + &sw else let ind = indent(lnum) endif - "Check if a block was ended: '}' or '>>' is the first non-blank character of the line. - if getline(v:lnum) =~ '^\s*\(}\|>>\)' + "Check if a block was ended: '}' or '>>' is the first non-blank character of the current line. + elseif getline(v:lnum) =~ '^\s*\(}\|>>\)' let ind = ind - &sw endif