From 231428ebcdbd65a3e817a747d2256ba99d54a799 Mon Sep 17 00:00:00 2001 From: Ayman Bagabas Date: Thu, 4 Jul 2019 05:22:16 -0400 Subject: [PATCH] Add uctags markdown support This adds basic markdown headings support based on Universal ctags. https://github.com/universal-ctags/ctags/pull/1727 #489 Signed-off-by: Ayman Bagabas --- autoload/tagbar/types/uctags.vim | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/autoload/tagbar/types/uctags.vim b/autoload/tagbar/types/uctags.vim index da3f4a6..bb2c4c7 100644 --- a/autoload/tagbar/types/uctags.vim +++ b/autoload/tagbar/types/uctags.vim @@ -575,6 +575,18 @@ function! tagbar#types#uctags#init(supported_types) abort \ {'short' : 't', 'long' : 'targets', 'fold' : 0, 'stl' : 1} \ ] let types.make = type_make + " Markdown {{{1 + let type_markdown = tagbar#prototypes#typeinfo#new() + let type_markdown.ctagstype = 'markdown' + let type_markdown.kinds = [ + \ {'short' : 'c', 'long' : 'h1', 'fold' : 0, 'stl' : 0}, + \ {'short' : 's', 'long' : 'h2', 'fold' : 0, 'stl' : 0}, + \ {'short' : 'S', 'long' : 'h3', 'fold' : 0, 'stl' : 0}, + \ {'short' : 't', 'long' : 'h4', 'fold' : 0, 'stl' : 0}, + \ {'short' : 'T', 'long' : 'h5', 'fold' : 0, 'stl' : 0}, + \ {'short' : 'u', 'long' : 'h6', 'fold' : 0, 'stl' : 0}, + \ ] + let types.markdown = type_markdown " Matlab {{{1 let type_matlab = tagbar#prototypes#typeinfo#new() let type_matlab.ctagstype = 'matlab'