annotate runtime/syntax/fdcc.vim @ 2953:9f71f5a526af v7.3.249

updated for version 7.3.249 Problem: Wrong indenting for array initializer. Solution: Detect '}' in a better way. (Lech Lorens)
author Bram Moolenaar <bram@vim.org>
date Fri, 15 Jul 2011 14:12:30 +0200
parents 3fc0f57ecb91
children 43efa4f5a8ea
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: fdcc or locale files
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
3 " Maintainer: Dwayne Bailey <dwayne@translate.org.za>
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
4 " Last Change: 2004 May 16
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
5 " Remarks: FDCC (Formal Definitions of Cultural Conventions) see ISO TR 14652
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
6
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
7 " For version 5.x: Clear all syntax items
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
8 " For version 6.x: Quit when a syntax file was already loaded
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
9 if version < 600
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
10 syntax clear
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
11 elseif exists("b:current_syntax")
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
12 finish
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
13 endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
14
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
15 syn sync minlines=150
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
16 setlocal iskeyword+=-
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
17
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
18 " Numbers
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
19 syn match fdccNumber /[0-9]*/ contained
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
20
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
21 " Unicode codings and strings
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
22 syn match fdccUnicodeInValid /<[^<]*>/ contained
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
23 syn match fdccUnicodeValid /<U[0-9A-F][0-9A-F][0-9A-F][0-9A-F]>/ contained
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
24 syn region fdccString start=/"/ end=/"/ contains=fdccUnicodeInValid,fdccUnicodeValid
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
25
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
26 " Valid LC_ Keywords
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
27 syn keyword fdccKeyword escape_char comment_char
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
28 syn keyword fdccKeywordIdentification title source address contact email tel fax language territory revision date category
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
29 syn keyword fdccKeywordCtype copy space translit_start include translit_end outdigit class
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
30 syn keyword fdccKeywordCollate copy script order_start order_end collating-symbol reorder-after reorder-end collating-element symbol-equivalence
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
31 syn keyword fdccKeywordMonetary copy int_curr_symbol currency_symbol mon_decimal_point mon_thousands_sep mon_grouping positive_sign negative_sign int_frac_digits frac_digits p_cs_precedes p_sep_by_space n_cs_precedes n_sep_by_space p_sign_posn n_sign_posn int_p_cs_precedes int_p_sep_by_space int_n_cs_precedes int_n_sep_by_space int_p_sign_posn int_n_sign_posn
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
32 syn keyword fdccKeywordNumeric copy decimal_point thousands_sep grouping
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
33 syn keyword fdccKeywordTime copy abday day abmon mon d_t_fmt d_fmt t_fmt am_pm t_fmt_ampm date_fmt era_d_fmt first_weekday first_workday week cal_direction time_zone era alt_digits era_d_t_fmt
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
34 syn keyword fdccKeywordMessages copy yesexpr noexpr yesstr nostr
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
35 syn keyword fdccKeywordPaper copy height width
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
36 syn keyword fdccKeywordTelephone copy tel_int_fmt int_prefix tel_dom_fmt int_select
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
37 syn keyword fdccKeywordMeasurement copy measurement
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
38 syn keyword fdccKeywordName copy name_fmt name_gen name_mr name_mrs name_miss name_ms
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
39 syn keyword fdccKeywordAddress copy postal_fmt country_name country_post country_ab2 country_ab3 country_num country_car country_isbn lang_name lang_ab lang_term lang_lib
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
40
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
41 " Comments
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
42 syn keyword fdccTodo TODO FIXME contained
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
43 syn match fdccVariable /%[a-zA-Z]/ contained
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
44 syn match fdccComment /[#%].*/ contains=fdccTodo,fdccVariable
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
45
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
46 " LC_ Groups
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
47 syn region fdccBlank matchgroup=fdccLCIdentification start=/^LC_IDENTIFICATION$/ end=/^END LC_IDENTIFICATION$/ contains=fdccKeywordIdentification,fdccString,fdccComment
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
48 syn region fdccBlank matchgroup=fdccLCCtype start=/^LC_CTYPE$/ end=/^END LC_CTYPE$/ contains=fdccKeywordCtype,fdccString,fdccComment,fdccUnicodeInValid,fdccUnicodeValid
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
49 syn region fdccBlank matchgroup=fdccLCCollate start=/^LC_COLLATE$/ end=/^END LC_COLLATE$/ contains=fdccKeywordCollate,fdccString,fdccComment,fdccUnicodeInValid,fdccUnicodeValid
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
50 syn region fdccBlank matchgroup=fdccLCMonetary start=/^LC_MONETARY$/ end=/^END LC_MONETARY$/ contains=fdccKeywordMonetary,fdccString,fdccComment,fdccNumber
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
51 syn region fdccBlank matchgroup=fdccLCNumeric start=/^LC_NUMERIC$/ end=/^END LC_NUMERIC$/ contains=fdccKeywordNumeric,fdccString,fdccComment,fdccNumber
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
52 syn region fdccBlank matchgroup=fdccLCTime start=/^LC_TIME$/ end=/^END LC_TIME$/ contains=fdccKeywordTime,fdccString,fdccComment,fdccNumber
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
53 syn region fdccBlank matchgroup=fdccLCMessages start=/^LC_MESSAGES$/ end=/^END LC_MESSAGES$/ contains=fdccKeywordMessages,fdccString,fdccComment
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
54 syn region fdccBlank matchgroup=fdccLCPaper start=/^LC_PAPER$/ end=/^END LC_PAPER$/ contains=fdccKeywordPaper,fdccString,fdccComment,fdccNumber
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
55 syn region fdccBlank matchgroup=fdccLCTelephone start=/^LC_TELEPHONE$/ end=/^END LC_TELEPHONE$/ contains=fdccKeywordTelephone,fdccString,fdccComment
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
56 syn region fdccBlank matchgroup=fdccLCMeasurement start=/^LC_MEASUREMENT$/ end=/^END LC_MEASUREMENT$/ contains=fdccKeywordMeasurement,fdccString,fdccComment,fdccNumber
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
57 syn region fdccBlank matchgroup=fdccLCName start=/^LC_NAME$/ end=/^END LC_NAME$/ contains=fdccKeywordName,fdccString,fdccComment
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
58 syn region fdccBlank matchgroup=fdccLCAddress start=/^LC_ADDRESS$/ end=/^END LC_ADDRESS$/ contains=fdccKeywordAddress,fdccString,fdccComment,fdccNumber
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
59
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
60
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
61 " For version 5.7 and earlier: only when not done already
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
62 " 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
63 if version >= 508 || !exists("did_fdcc_syn_inits")
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
64 if version < 508
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
65 let did_fdcc_syn_inits = 1
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
66 command -nargs=+ HiLink hi link <args>
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
67 else
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
68 command -nargs=+ HiLink hi def link <args>
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
69 endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
70
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
71 HiLink fdccBlank Blank
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
72
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
73 HiLink fdccTodo Todo
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
74 HiLink fdccComment Comment
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
75 HiLink fdccVariable Type
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
76
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
77 HiLink fdccLCIdentification Statement
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
78 HiLink fdccLCCtype Statement
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
79 HiLink fdccLCCollate Statement
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
80 HiLink fdccLCMonetary Statement
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
81 HiLink fdccLCNumeric Statement
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
82 HiLink fdccLCTime Statement
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
83 HiLink fdccLCMessages Statement
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
84 HiLink fdccLCPaper Statement
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
85 HiLink fdccLCTelephone Statement
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
86 HiLink fdccLCMeasurement Statement
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
87 HiLink fdccLCName Statement
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
88 HiLink fdccLCAddress Statement
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
89
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
90 HiLink fdccUnicodeInValid Error
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
91 HiLink fdccUnicodeValid String
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
92 HiLink fdccString String
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
93 HiLink fdccNumber Blank
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
94
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
95 HiLink fdccKeywordIdentification fdccKeyword
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
96 HiLink fdccKeywordCtype fdccKeyword
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
97 HiLink fdccKeywordCollate fdccKeyword
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
98 HiLink fdccKeywordMonetary fdccKeyword
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
99 HiLink fdccKeywordNumeric fdccKeyword
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
100 HiLink fdccKeywordTime fdccKeyword
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
101 HiLink fdccKeywordMessages fdccKeyword
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
102 HiLink fdccKeywordPaper fdccKeyword
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
103 HiLink fdccKeywordTelephone fdccKeyword
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
104 HiLink fdccKeywordMeasurement fdccKeyword
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
105 HiLink fdccKeywordName fdccKeyword
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
106 HiLink fdccKeywordAddress fdccKeyword
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
107 HiLink fdccKeyword Identifier
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
108
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
109 delcommand HiLink
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
110 endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
111
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
112 let b:current_syntax = "fdcc"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
113
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
114 " vim: ts=8