Mercurial > vim
diff src/edit.c @ 5438:878ed73c7070 v7.4.069
updated for version 7.4.069
Problem: Cannot right shift lines starting with #.
Solution: Allow the right shift when 'cino' contains #N with N > 0.
(Christian Brabandt)
Refactor parsing 'cino', store the values in the buffer.
author | Bram Moolenaar <bram@vim.org> |
---|---|
date | Tue, 05 Nov 2013 07:13:41 +0100 |
parents | 86bf09a1b6d0 |
children | faf7e86203b5 |
line wrap: on
line diff
--- a/src/edit.c +++ b/src/edit.c @@ -8958,7 +8958,7 @@ ins_bs(c, mode, inserted_space_p) *inserted_space_p = FALSE; if (p_sta && in_indent) - ts = (int)get_sw_value(); + ts = (int)get_sw_value(curbuf); else ts = (int)get_sts_value(); /* Compute the virtual column where we want to be. Since @@ -9647,7 +9647,7 @@ ins_tab() * When nothing special, insert TAB like a normal character */ if (!curbuf->b_p_et - && !(p_sta && ind && curbuf->b_p_ts != get_sw_value()) + && !(p_sta && ind && curbuf->b_p_ts != get_sw_value(curbuf)) && get_sts_value() == 0) return TRUE; @@ -9663,7 +9663,7 @@ ins_tab() AppendToRedobuff((char_u *)"\t"); if (p_sta && ind) /* insert tab in indent, use 'shiftwidth' */ - temp = (int)get_sw_value(); + temp = (int)get_sw_value(curbuf); else if (curbuf->b_p_sts != 0) /* use 'softtabstop' when set */ temp = (int)get_sts_value(); else /* otherwise use 'tabstop' */