aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--plugin/tabs_grep.vim17
1 files changed, 14 insertions, 3 deletions
diff --git a/plugin/tabs_grep.vim b/plugin/tabs_grep.vim
index 644bf44..d9abe40 100644
--- a/plugin/tabs_grep.vim
+++ b/plugin/tabs_grep.vim
@@ -9,9 +9,8 @@ function! TabsGrep(search)
call filter(tabs, function('s:MatchString', [a:search]))
let tabs = s:FilterTabPageElements(tabs)
- for line in tabs
- echo line
- endfor
+
+ call s:EchoTabs(tabs)
endfunction
function! s:MatchString(search, index, value)
@@ -61,4 +60,16 @@ function! s:FilterTabPageElements(list)
return a:list
endfunction
+function! s:EchoTabs(tab_list)
+ for line in a:tab_list
+ if s:IsTabPageLine(line)
+ echohl Title
+ echo line
+ echohl None
+ else
+ echo line
+ endif
+ endfor
+endfunction
+
command! -nargs=1 TabsGrep :call TabsGrep(<f-args>)