mirror of
https://github.com/mattn/emmet-vim.git
synced 2025-12-06 10:44:24 +08:00
merge lines. close issue #52
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
"=============================================================================
|
||||
" zencoding.vim
|
||||
" Author: Yasuhiro Matsumoto <mattn.jp@gmail.com>
|
||||
" Last Change: 11-Jan-2012.
|
||||
" Last Change: 17-Jan-2012.
|
||||
|
||||
let s:save_cpo = &cpo
|
||||
set cpo&vim
|
||||
@@ -999,6 +999,13 @@ function! zencoding#splitJoinTag()
|
||||
endwhile
|
||||
endfunction
|
||||
|
||||
function! zencoding#mergeLines() range
|
||||
let lines = join(map(getline(a:firstline, a:lastline), 'matchstr(v:val, "^\\s*\\zs.*\\ze\\s*$")'), '')
|
||||
let indent = substitute(getline('.'), '^\(\s*\).*', '\1', '')
|
||||
silent! exe "normal! gvc"
|
||||
call setline('.', indent . lines)
|
||||
endfunction
|
||||
|
||||
function! zencoding#removeTag()
|
||||
let curpos = getpos('.')
|
||||
while 1
|
||||
|
||||
Reference in New Issue
Block a user