annotate runtime/syntax/man.vim @ 2861:e6ce47f06836 v7.3.204

updated for version 7.3.204 Problem: Compiler warning. Solution: Add type cast. (Mike Williams)
author Bram Moolenaar <bram@vim.org>
date Wed, 25 May 2011 17:29:44 +0200
parents 7bc41231fbc7
children 17333ebd2bbd
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1 " Vim syntax file
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
2 " Language: Man page
2034
7bc41231fbc7 Update runtime files.
Bram Moolenaar <bram@zimbu.org>
parents: 1621
diff changeset
3 " Maintainer: SungHyun Nam <goweol@gmail.com>
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
4 " Previous Maintainer: Gautam H. Mudunuri <gmudunur@informatica.com>
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
5 " Version Info:
2034
7bc41231fbc7 Update runtime files.
Bram Moolenaar <bram@zimbu.org>
parents: 1621
diff changeset
6 " Last Change: 2008 Sep 17
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
8 " Additional highlighting by Johannes Tanzler <johannes.tanzler@aon.at>:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
9 " * manSubHeading
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
10 " * manSynopsis (only for sections 2 and 3)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
11
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
12 " For version 5.x: Clear all syntax items
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
13 " For version 6.x: Quit when a syntax file was already loaded
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
14 if version < 600
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
15 syntax clear
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
16 elseif exists("b:current_syntax")
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
17 finish
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
18 endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
19
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
20 " Get the CTRL-H syntax to handle backspaced text
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
21 if version >= 600
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
22 runtime! syntax/ctrlh.vim
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
23 else
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
24 source <sfile>:p:h/ctrlh.vim
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
25 endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
26
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
27 syn case ignore
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
28 syn match manReference "\f\+([1-9][a-z]\=)"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
29 syn match manTitle "^\f\+([0-9]\+[a-z]\=).*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
30 syn match manSectionHeading "^[a-z][a-z ]*[a-z]$"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
31 syn match manSubHeading "^\s\{3\}[a-z][a-z ]*[a-z]$"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
32 syn match manOptionDesc "^\s*[+-][a-z0-9]\S*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
33 syn match manLongOptionDesc "^\s*--[a-z0-9-]\S*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
34 " syn match manHistory "^[a-z].*last change.*$"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
35
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
36 if getline(1) =~ '^[a-zA-Z_]\+([23])'
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
37 syntax include @cCode <sfile>:p:h/c.vim
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
38 syn match manCFuncDefinition display "\<\h\w*\>\s*("me=e-1 contained
1621
82b5078be2dd updated for version 7.2a
vimboss
parents: 7
diff changeset
39 syn region manSynopsis start="^SYNOPSIS"hs=s+8 end="^\u\+\s*$"me=e-12 keepend contains=manSectionHeading,@cCode,manCFuncDefinition
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
40 endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
41
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
42
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
43 " Define the default highlighting.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
44 " For version 5.7 and earlier: only when not done already
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
45 " For version 5.8 and later: only when an item doesn't have highlighting yet
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
46 if version >= 508 || !exists("did_man_syn_inits")
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
47 if version < 508
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
48 let did_man_syn_inits = 1
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
49 command -nargs=+ HiLink hi link <args>
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
50 else
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
51 command -nargs=+ HiLink hi def link <args>
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
52 endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
53
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
54 HiLink manTitle Title
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
55 HiLink manSectionHeading Statement
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
56 HiLink manOptionDesc Constant
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
57 HiLink manLongOptionDesc Constant
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
58 HiLink manReference PreProc
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
59 HiLink manSubHeading Function
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
60 HiLink manCFuncDefinition Function
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
61
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
62 delcommand HiLink
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
63 endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
64
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
65 let b:current_syntax = "man"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
66
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
67 " vim:ts=8 sts=2 sw=2: