Mercurial > vim
comparison runtime/indent/css.vim @ 11062:1218c5353e2b
Runtime file updates.
commit https://github.com/vim/vim/commit/214641f77df6f318a4b3a0b09723c19859a103f4
Author: Bram Moolenaar <Bram@vim.org>
Date: Sun Mar 5 17:04:09 2017 +0100
Runtime file updates.
author | Christian Brabandt <cb@256bit.org> |
---|---|
date | Sun, 05 Mar 2017 17:15:05 +0100 |
parents | 9cb3a75a20b9 |
children | 9c221ad9634a |
comparison
equal
deleted
inserted
replaced
11061:0f11b92d7f5e | 11062:1218c5353e2b |
---|---|
1 " Vim indent file | 1 " Vim indent file |
2 " Language: CSS | 2 " Language: CSS |
3 " Maintainer: Nikolai Weibull <now@bitwi.se> | 3 " Maintainer: Nikolai Weibull <now@bitwi.se> |
4 " Latest Revision: 2012-05-30 | 4 " Latest Revision: 2012-05-30 |
5 " Use of shiftwidth() added by Oleg Zubchenko. | |
5 | 6 |
6 if exists("b:did_indent") | 7 if exists("b:did_indent") |
7 finish | 8 finish |
8 endif | 9 endif |
9 let b:did_indent = 1 | 10 let b:did_indent = 1 |
73 let pnum = s:prevnonblanknoncomment(v:lnum - 1) | 74 let pnum = s:prevnonblanknoncomment(v:lnum - 1) |
74 if pnum == 0 | 75 if pnum == 0 |
75 return 0 | 76 return 0 |
76 endif | 77 endif |
77 | 78 |
78 return indent(pnum) + s:count_braces(pnum, 1) * &sw | 79 return indent(pnum) + s:count_braces(pnum, 1) * shiftwidth() |
79 \ - s:count_braces(v:lnum, 0) * &sw | 80 \ - s:count_braces(v:lnum, 0) * shiftwidth() |
80 endfunction | 81 endfunction |
81 | 82 |
82 let &cpo = s:keepcpo | 83 let &cpo = s:keepcpo |
83 unlet s:keepcpo | 84 unlet s:keepcpo |