Hi Bram,
The latest development version of Vim currently only supports the
compact syntax of the RELAX NG schema language. Attached is a simple
runtime/syntax/rng.vim file that implements highlighting for the RELAX
NG XML syntax, and a patch for the $VIMRUNTIME/filetype.vim file that
adds file type detection for this schema.
Thank you,
--
Jaromir Hradilek
--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups "vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.
" Vim syntax file
" Language: RELAX NG
" Maintainer: Jaromir Hradilek <[email protected]>
" URL: https://github.com/jhradilek/vim-rng
" Last Change: 25 March 2013
" Description: A syntax file for RELAX NG, a schema language for XML
if exists('b:current_syntax')
finish
endif
do Syntax xml
syn spell toplevel
syn cluster xmlTagHook add=rngTagName
syn case match
syn keyword rngTagName anyName attribute choice data define div contained
syn keyword rngTagName element empty except externalRef grammar contained
syn keyword rngTagName group include interleave list mixed name contained
syn keyword rngTagName notAllowed nsName oneOrMore optional param contained
syn keyword rngTagName parentRef ref start text value zeroOrMore contained
hi def link rngTagName Statement
let b:current_syntax = 'rng'
--- a/runtime/filetype.vim 2013-03-25 01:11:35.836997571 +0100
+++ b/runtime/filetype.vim 2013-03-25 01:14:32.249313983 +0100
@@ -1650,6 +1650,9 @@
" Relax NG Compact
au BufNewFile,BufRead *.rnc setf rnc
+" Relax NG XML
+au BufNewFile,BufRead *.rng setf rng
+
" RPL/2
au BufNewFile,BufRead *.rpl setf rpl