mirror of
https://github.com/dhruvasagar/vim-table-mode.git
synced 2025-11-09 03:23:47 -05:00
Fixed #19
Updated tablemode#table#IsRow() to allow hiphens within the row.
This commit is contained in:
@@ -153,15 +153,14 @@ function! tablemode#table#EndExpr() "{{{2
|
|||||||
endif
|
endif
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! tablemode#table#IsRow(line) "{{{2
|
|
||||||
return getline(a:line) =~# (tablemode#table#StartExpr() . g:table_mode_separator . '[^' .
|
|
||||||
\ g:table_mode_fillchar . ']*[^' . g:table_mode_corner . ']*$')
|
|
||||||
endfunction
|
|
||||||
|
|
||||||
function! tablemode#table#IsHeader(line) "{{{2
|
function! tablemode#table#IsHeader(line) "{{{2
|
||||||
return getline(a:line) =~# s:HeaderBorderExpr()
|
return getline(a:line) =~# s:HeaderBorderExpr()
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
|
function! tablemode#table#IsRow(line) "{{{2
|
||||||
|
return !tablemode#table#IsHeader(a:line) && getline(a:line) =~# (tablemode#table#StartExpr() . g:table_mode_separator)
|
||||||
|
endfunction
|
||||||
|
|
||||||
function! tablemode#table#AddHeaderBorder(line) "{{{2
|
function! tablemode#table#AddHeaderBorder(line) "{{{2
|
||||||
call setline(a:line, s:GenerateHeaderBorder(a:line))
|
call setline(a:line, s:GenerateHeaderBorder(a:line))
|
||||||
endfunction
|
endfunction
|
||||||
|
|||||||
Reference in New Issue
Block a user