~dricottone/vim-xml

86304204b5da8b8287458281603a73044be9fd49 — Dominic Ricottone 2 years ago 5c40cc9
De-emphasize end tag

My preference is for the end tag to be less visible. This makes that
happen.

Half of the time, my XML files are actually XHTML, and I am closing
blocks with...

</div> <!-- class name -->

Highlighting these lines with differing colors is distracting, and it
would be too difficult to find a way to pattern match these types of
comments. Therefore my preference is to not highlight at all.
1 files changed, 5 insertions(+), 4 deletions(-)

M syntax/xml.vim
M syntax/xml.vim => syntax/xml.vim +5 -4
@@ 199,9 199,10 @@ else
	\ matchgroup=xmlTag end=+>+
	\ contains=xmlError,xmlTagName,xmlAttrib,xmlEqual,xmlString,@xmlStartTagHook

    syn match   xmlEndTag
	\ +</[^ /!?<>"']\+>+
	\ contains=xmlNamespace,xmlAttribPunct,@xmlTagHook
    syn region   xmlEndTag
	\ matchgroup=xmlTag start=+</[^ /!?<>"']\@=+
	\ matchgroup=xmlTag end=+>+
        \ contains=xmlTagName,xmlNamespace,xmlAttribPunct,@xmlTagHook

endif



@@ 310,7 311,7 @@ syn sync minlines=100
hi def link xmlTodo		Todo
hi def link xmlTag		Function
hi def link xmlTagName		Function
hi def link xmlEndTag		Identifier
hi def link xmlEndTag		Function
if !exists("g:xml_namespace_transparent")
    hi def link xmlNamespace	Tag
endif