Bram Moolenaar | 42eeac3 | 2005-06-29 22:40:58 +0000 | [diff] [blame] | 1 | " Vim syntax file |
| 2 | " Language: limits(5) configuration file |
Bram Moolenaar | 57657d8 | 2006-04-21 22:12:41 +0000 | [diff] [blame] | 3 | " Maintainer: Nikolai Weibull <now@bitwi.se> |
| 4 | " Latest Revision: 2006-04-19 |
Bram Moolenaar | 42eeac3 | 2005-06-29 22:40:58 +0000 | [diff] [blame] | 5 | |
| 6 | if exists("b:current_syntax") |
| 7 | finish |
| 8 | endif |
| 9 | |
| 10 | let s:cpo_save = &cpo |
| 11 | set cpo&vim |
| 12 | |
| 13 | syn keyword limitsTodo contained TODO FIXME XXX NOTE |
| 14 | |
| 15 | syn region limitsComment display oneline start='^\s*#' end='$' |
| 16 | \ contains=limitsTodo,@Spell |
| 17 | |
| 18 | syn match limitsBegin display '^' |
| 19 | \ nextgroup=limitsUser,limitsDefault,limitsComment |
| 20 | \ skipwhite |
| 21 | |
| 22 | syn match limitsUser contained '[^ \t#*]\+' |
| 23 | \ nextgroup=limitsLimit,limitsDeLimit skipwhite |
| 24 | |
| 25 | syn match limitsDefault contained '*' |
| 26 | \ nextgroup=limitsLimit,limitsDeLimit skipwhite |
| 27 | |
| 28 | syn match limitsLimit contained '[ACDFMNRSTUKLP]' nextgroup=limitsNumber |
| 29 | syn match limitsDeLimit contained '-' |
| 30 | |
| 31 | syn match limitsNumber contained '\d\+\>' nextgroup=limitsLimit skipwhite |
| 32 | |
| 33 | hi def link limitsTodo Todo |
| 34 | hi def link limitsComment Comment |
| 35 | hi def link limitsUser Keyword |
| 36 | hi def link limitsDefault Macro |
| 37 | hi def link limitsLimit Identifier |
| 38 | hi def link limitsDeLimit Special |
| 39 | hi def link limitsNumber Number |
| 40 | |
| 41 | let b:current_syntax = "limits" |
| 42 | |
| 43 | let &cpo = s:cpo_save |
| 44 | unlet s:cpo_save |