Skip to content

Commit ea39fa5

Browse files
committed
commit version 1.94 (released on Dec 19, 2002)
1 parent f61ddc1 commit ea39fa5

File tree

1 file changed

+33
-10
lines changed

1 file changed

+33
-10
lines changed

plugin/taglist.vim

Lines changed: 33 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
" File: taglist.vim
22
" Author: Yegappan Lakshmanan (yegappan AT yahoo DOT com)
3-
" Version: l.93
4-
" Last Modified: Dec 15, 2002
3+
" Version: l.94
4+
" Last Modified: Dec 19, 2002
55
"
66
" Overview
77
" --------
@@ -201,7 +201,15 @@
201201
" you single click on the tag name using the mouse. By default this variable
202202
" is set to zero.
203203
"
204-
" let Tlist_Use_SingleClick = 0
204+
" let Tlist_Use_SingleClick = 1
205+
"
206+
" By default, the taglist window will contain text that display the name of
207+
" the file, sort order information and the key to press to get help. Also,
208+
" empty lines will be used to separate different groups of tags. If you
209+
" don't need these information, you can set the Tlist_Compact_Format variable
210+
" to one to get a compact display.
211+
"
212+
" let Tlist_Compact_Format = 1
205213
"
206214
" ****************** Do not modify after this line ************************
207215
if exists('loaded_taglist') || &cp
@@ -263,6 +271,12 @@ if !exists('Tlist_Use_SingleClick')
263271
let Tlist_Use_SingleClick = 0
264272
endif
265273

274+
" Control whether additional help is displayed as part of the taglist or not.
275+
" Also, controls whether empty lines are used to separate the tag tree.
276+
if !exists('Tlist_Compact_Format')
277+
let Tlist_Compact_Format = 0
278+
endif
279+
266280
" File types supported by taglist
267281
let s:tlist_file_types = 'asm asp awk c cpp cobol eiffel fortran java ' .
268282
\ 'lisp lua make pascal perl php python rexx ruby scheme sh ' .
@@ -602,10 +616,12 @@ function! s:Tlist_Open_Window(bufnum)
602616
let b:tlist_bufname = fnamemodify(bufname(a:bufnum), ':p')
603617
let b:tlist_ftype = getbufvar(a:bufnum, '&filetype')
604618

605-
call append(0, '" Press ? for help')
606-
call append(1, '" Sorted by ' . b:tlist_sort_type)
607-
call append(2, '" =' . fnamemodify(filename, ':t') . ' (' .
608-
\ fnamemodify(filename, ':p:h') . ')')
619+
if g:Tlist_Compact_Format == 0
620+
call append(0, '" Press ? for help')
621+
call append(1, '" Sorted by ' . b:tlist_sort_type)
622+
call append(2, '" =' . fnamemodify(filename, ':t') . ' (' .
623+
\ fnamemodify(filename, ':p:h') . ')')
624+
endif
609625

610626
" Mark the buffer as not modifiable
611627
setlocal nomodifiable
@@ -871,8 +887,13 @@ function! s:Tlist_Explore_File(bufnum)
871887
let ttype = s:tlist_{ftype}_{i}_name
872888
" Add the tag type only if there are tags for that type
873889
if l:tlist_{ftype}_{ttype} != ''
874-
let b:tlist_{ftype}_{ttype}_start = line('.') + 1
875-
silent! put =ttype
890+
if g:Tlist_Compact_Format == 0
891+
let b:tlist_{ftype}_{ttype}_start = line('.') + 1
892+
silent! put =ttype
893+
else
894+
let b:tlist_{ftype}_{ttype}_start = line('.')
895+
silent! put! =ttype
896+
endif
876897
silent! put =l:tlist_{ftype}_{ttype}
877898

878899
" create a fold for this tag type
@@ -889,7 +910,9 @@ function! s:Tlist_Explore_File(bufnum)
889910
endif
890911
" Separate the tag types with a empty line
891912
normal! G
892-
silent! put =''
913+
if g:Tlist_Compact_Format == 0
914+
silent! put =''
915+
endif
893916
endif
894917
let i = i + 1
895918
endwhile

0 commit comments

Comments
 (0)