comparison runtime/syntax/mail.vim @ 230:9281a51ca7a2

updated for version 7.0064
author vimboss
date Fri, 25 Mar 2005 21:53:48 +0000
parents ef254e0f2365
children 006e9c8a6a8a
comparison
equal deleted inserted replaced
229:723a01584c3e 230:9281a51ca7a2
1 " Vim syntax file 1 " Vim syntax file
2 " Language: Mail file 2 " Language: Mail file
3 " Previous Maintainer: Felix von Leitner <leitner@math.fu-berlin.de> 3 " Previous Maintainer: Felix von Leitner <leitner@math.fu-berlin.de>
4 " Maintainer: Gautam Iyer <gautam@math.uchicago.edu> 4 " Maintainer: Gautam Iyer <gautam@math.uchicago.edu>
5 " Last Change: Thu 10 Feb 2005 09:46:26 AM CST 5 " Last Change: 2005 Mar 23
6 6
7 " Quit when a syntax file was already loaded 7 " Quit when a syntax file was already loaded
8 if exists("b:current_syntax") 8 if exists("b:current_syntax")
9 finish 9 finish
10 endif 10 endif
34 syn match mailHeaderKey contained contains=mailHeaderEmail,mailEmail,@NoSpell "\v(^(\> ?)*)@<=(from|reply-to):.*$" 34 syn match mailHeaderKey contained contains=mailHeaderEmail,mailEmail,@NoSpell "\v(^(\> ?)*)@<=(from|reply-to):.*$"
35 syn match mailHeaderKey contained "\v(^(\> ?)*)@<=date:" 35 syn match mailHeaderKey contained "\v(^(\> ?)*)@<=date:"
36 syn match mailSubject contained "\v(^(\> ?)*)@<=subject:.*$" 36 syn match mailSubject contained "\v(^(\> ?)*)@<=subject:.*$"
37 37
38 " Anything in the header between < and > is an email address 38 " Anything in the header between < and > is an email address
39 syn match mailHeaderEmail contained "<.\{-}>" 39 syn match mailHeaderEmail contained "<.\{-}>" contains=@NoSpell
40 40
41 " Mail Signatures. (Begin with "-- ", end with change in quote level) 41 " Mail Signatures. (Begin with "-- ", end with change in quote level)
42 syn region mailSignature keepend contains=@mailLinks,@mailQuoteExps start="^\z(\(> \?\)*\)-- $" end="^\z1$" end="^\z1\@!"me=s-1 end="^\z1\(> \?\)\+"me=s-1 42 syn region mailSignature keepend contains=@mailLinks,@mailQuoteExps start="^\z(\(> \?\)*\)-- $" end="^\z1$" end="^\z1\@!"me=s-1 end="^\z1\(> \?\)\+"me=s-1
43 43
44 " URLs start with a known protocol or www,web,w3. 44 " URLs start with a known protocol or www,web,w3.
45 syn match mailURL `\v<(((https?|ftp|gopher)://|(mailto|file|news):)[^' <>"]+|(www|web|w3)[a-z0-9_-]*\.[a-z0-9._-]+\.[^' <>"]+)[a-z0-9/]` 45 syn match mailURL `\v<(((https?|ftp|gopher)://|(mailto|file|news):)[^' <>"]+|(www|web|w3)[a-z0-9_-]*\.[a-z0-9._-]+\.[^' <>"]+)[a-z0-9/]` contains=@NoSpell
46 syn match mailEmail "\v[_=a-z\./+0-9-]+\@[a-z0-9._-]+\a{2}" 46 syn match mailEmail "\v[_=a-z\./+0-9-]+\@[a-z0-9._-]+\a{2}" contains=@NoSpell
47 47
48 " Make sure quote markers in regions (header / signature) have correct color 48 " Make sure quote markers in regions (header / signature) have correct color
49 syn match mailQuoteExp1 contained "\v^(\> ?)" 49 syn match mailQuoteExp1 contained "\v^(\> ?)"
50 syn match mailQuoteExp2 contained "\v^(\> ?){2}" 50 syn match mailQuoteExp2 contained "\v^(\> ?){2}"
51 syn match mailQuoteExp3 contained "\v^(\> ?){3}" 51 syn match mailQuoteExp3 contained "\v^(\> ?){3}"