mirror of
https://github.com/vim/vim.git
synced 2025-07-04 23:07:33 -04:00
Updated runtime files.
This commit is contained in:
parent
38ec50bea8
commit
0187ca0bdf
@ -1,4 +1,4 @@
|
||||
*insert.txt* For Vim version 7.3. Last change: 2013 Jan 09
|
||||
*insert.txt* For Vim version 7.3. Last change: 2013 Apr 12
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@ -1869,13 +1869,15 @@ NOTE: These commands cannot be used with |:global| or |:vglobal|.
|
||||
See |++opt| for the possible values of [++opt].
|
||||
|
||||
*:r!* *:read!*
|
||||
:[range]r[ead] !{cmd} Execute {cmd} and insert its standard output below
|
||||
:[range]r[ead] [++opt] !{cmd}
|
||||
Execute {cmd} and insert its standard output below
|
||||
the cursor or the specified line. A temporary file is
|
||||
used to store the output of the command which is then
|
||||
read into the buffer. 'shellredir' is used to save
|
||||
the output of the command, which can be set to include
|
||||
stderr or not. {cmd} is executed like with ":!{cmd}",
|
||||
any '!' is replaced with the previous command |:!|.
|
||||
See |++opt| for the possible values of [++opt].
|
||||
|
||||
These commands insert the contents of a file, or the output of a command,
|
||||
into the buffer. They can be undone. They cannot be repeated with the "."
|
||||
|
@ -1,4 +1,4 @@
|
||||
*todo.txt* For Vim version 7.3. Last change: 2013 Apr 06
|
||||
*todo.txt* For Vim version 7.3. Last change: 2013 Apr 12
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@ -41,8 +41,6 @@ Go through more coverity reports.
|
||||
|
||||
Valgrind errors in test 16.
|
||||
|
||||
Memory leaks in Lua, uncovered by test 85.
|
||||
|
||||
Discussion about canonicalization of Hebrew. (Ron Aaron, 2011 April 10)
|
||||
|
||||
Checking runtime scripts: Thilo Six, 2012 Jun 6.
|
||||
@ -56,11 +54,6 @@ The CompleteDone autocommand needs some info passed to it:
|
||||
- The word that was selected (empty if abandoned complete)
|
||||
- Type of completion: tag, omnifunc, user func.
|
||||
|
||||
Patch to fix sorting order when 'fileignorecase' is set. (Hirohito Higashi,
|
||||
2013 Mar 20) Update Mar 24.
|
||||
|
||||
Patch to add test for what 7.3.879 fixes. (David Bürgin / glts, 2013 Apr 6)
|
||||
|
||||
Using ":call foo#d.f()" doesn't autoload the "foo.vim" file.
|
||||
That is, calling a dictionary function on an autoloaded dict.
|
||||
Works OK for echo, just not for ":call" and ":call call()". (Ted, 2011 Mar
|
||||
@ -142,8 +135,15 @@ MS-Windows: Crash opening very long file name starting with "\\".
|
||||
It's probably a good idea to make a negative value for 'sts' use the value of
|
||||
'sw'. Patch by So8res, Oct 3 2012
|
||||
|
||||
Test 79 fails on Windows only. (Michael Soyka, 2013 Apr 11).
|
||||
What makes the test script mapping continue after an error?
|
||||
|
||||
patch to add "combine" flag to syntax commands. (so8res, 2012 Dec 6)
|
||||
|
||||
Combining characters are not used when executing a register with :@w.
|
||||
(William Fugh, 2013 Apr 5, more info from Ben Fritz)
|
||||
Patch by Christian Brabandt, 2013 Apr 6. Second one.
|
||||
|
||||
Bug in completion menu. (Olivier Teuliere, 2013 Feb 15)
|
||||
Patch by Christian Brabandt, Feb 16.
|
||||
|
||||
@ -227,9 +227,6 @@ URXVT:
|
||||
|
||||
MS-Windows: test 17 fails. Analysis by Michael Soyka, 2012 Nov 5.
|
||||
|
||||
Combining characters are not used when executing a register with :@w.
|
||||
(William Fugh, 2013 Apr 5, more info from Ben Fritz)
|
||||
|
||||
Patch to add tests for if_xcmdsrv.c., Jul 8, need some more work. (Brian Burns)
|
||||
New tests Jul 13. Update Jul 17. Discussion Jul 18.
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
" Vim support file to detect file types
|
||||
"
|
||||
" Maintainer: Bram Moolenaar <Bram@vim.org>
|
||||
" Last Change: 2013 Apr 06
|
||||
" Last Change: 2013 Apr 08
|
||||
|
||||
" Listen very carefully, I will say this only once
|
||||
if exists("did_load_filetypes")
|
||||
@ -1638,10 +1638,6 @@ func! s:FTr()
|
||||
endif
|
||||
endfunc
|
||||
|
||||
" ReDIF
|
||||
" TODO: Not all .rdf files are redif, need a better way to detect.
|
||||
" au BufRead,BufNewFile *.rdf setf redif
|
||||
|
||||
" Remind
|
||||
au BufNewFile,BufRead .reminders,*.remind,*.rem setf remind
|
||||
|
||||
@ -2567,6 +2563,20 @@ au BufNewFile,BufRead *termcap*
|
||||
\| let b:ptcap_type = "term" | call s:StarSetf('ptcap')
|
||||
\|endif
|
||||
|
||||
" ReDIF
|
||||
" Only used when the .rdf file was not detected to be XML.
|
||||
au BufRead,BufNewFile *.rdf call s:Redif()
|
||||
func! s:Redif()
|
||||
let lnum = 1
|
||||
while lnum <= 5 && lnum < line('$')
|
||||
if getline(lnum) =~ "^\ctemplate-type:"
|
||||
setf redif
|
||||
return
|
||||
endif
|
||||
let lnum = lnum + 1
|
||||
endwhile
|
||||
endfunc
|
||||
|
||||
" Remind
|
||||
au BufNewFile,BufRead .reminders* call s:StarSetf('remind')
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
" Vim syntax file
|
||||
" Language: Vim help file
|
||||
" Maintainer: Bram Moolenaar (Bram@vim.org)
|
||||
" Last Change: 2012 Jul 16
|
||||
" Last Change: 2013 Apr 07
|
||||
|
||||
" Quit when a (custom) syntax file was already loaded
|
||||
if exists("b:current_syntax")
|
||||
@ -40,7 +40,7 @@ syn match helpVim "Vim version [0-9.a-z]\+"
|
||||
syn match helpVim "VIM REFERENCE.*"
|
||||
syn match helpOption "'[a-z]\{2,\}'"
|
||||
syn match helpOption "'t_..'"
|
||||
syn match helpCommand "`[^` ]*`"hs=s+1,he=e-1 contains=helpBacktick
|
||||
syn match helpCommand "`[^` ]\+`"hs=s+1,he=e-1 contains=helpBacktick
|
||||
syn match helpHeader "\s*\zs.\{-}\ze\s\=\~$" nextgroup=helpIgnore
|
||||
syn match helpGraphic ".* \ze`$" nextgroup=helpIgnore
|
||||
if has("conceal")
|
||||
|
@ -1,13 +1,13 @@
|
||||
" ninja build file syntax.
|
||||
" Language: ninja build file as described at
|
||||
" http://martine.github.com/ninja/manual.html
|
||||
" Version: 1.2
|
||||
" Last Change: 2012/06/01
|
||||
" Version: 1.3
|
||||
" Last Change: 2013 Apr 12
|
||||
" Maintainer: Nicolas Weber <nicolasweber@gmx.de>
|
||||
|
||||
" ninja lexer and parser are at
|
||||
" https://github.com/martine/ninja/blob/master/src/lexer.in.cc
|
||||
" https://github.com/martine/ninja/blob/master/src/parsers.cc
|
||||
" https://github.com/martine/ninja/blob/master/src/manifest_parser.cc
|
||||
|
||||
if exists("b:current_syntax")
|
||||
finish
|
||||
@ -19,9 +19,10 @@ syn match ninjaComment /#.*/ contains=@Spell
|
||||
|
||||
" Toplevel statements are the ones listed here and
|
||||
" toplevel variable assignments (ident '=' value).
|
||||
" lexer.in.cc, ReadToken() and parsers.cc, Parse()
|
||||
" lexer.in.cc, ReadToken() and manifest_parser.cc, Parse()
|
||||
syn match ninjaKeyword "^build\>"
|
||||
syn match ninjaKeyword "^rule\>"
|
||||
syn match ninjaKeyword "^pool\>"
|
||||
syn match ninjaKeyword "^default\>"
|
||||
syn match ninjaKeyword "^include\>"
|
||||
syn match ninjaKeyword "^subninja\>"
|
||||
@ -30,9 +31,12 @@ syn match ninjaKeyword "^subninja\>"
|
||||
" on the first line without indent. 'rule' allows only a
|
||||
" limited set of magic variables, 'build' allows general
|
||||
" let assignments.
|
||||
" parsers.cc, ParseRule()
|
||||
" manifest_parser.cc, ParseRule()
|
||||
syn region ninjaRule start="^rule" end="^\ze\S" contains=ALL transparent
|
||||
syn keyword ninjaRuleCommand contained command depfile description generator restat
|
||||
syn keyword ninjaRuleCommand contained command deps depfile description generator pool restat rspfile rspfile_content
|
||||
|
||||
syn region ninjaPool start="^pool" end="^\ze\S" contains=ALL transparent
|
||||
syn keyword ninjaPoolCommand contained depth
|
||||
|
||||
" Strings are parsed as follows:
|
||||
" lexer.in.cc, ReadEvalString()
|
||||
@ -58,6 +62,7 @@ syn match ninjaOperator "\(=\|:\||\|||\)\ze\s"
|
||||
hi def link ninjaComment Comment
|
||||
hi def link ninjaKeyword Keyword
|
||||
hi def link ninjaRuleCommand Statement
|
||||
hi def link ninjaPoolCommand Statement
|
||||
hi def link ninjaWrapLineOperator ninjaOperator
|
||||
hi def link ninjaOperator Operator
|
||||
hi def link ninjaSimpleVar ninjaVar
|
||||
|
@ -1,22 +1,19 @@
|
||||
" Vim syntax file
|
||||
" Language: ReDIF
|
||||
" Maintainer: Axel Castellane <axel.castellane@polytechnique.edu>
|
||||
" Last Change: 2013 Feb 20
|
||||
" Last Change: 2013 April 08
|
||||
" Original Author: Axel Castellane
|
||||
" Source: http://openlib.org/acmes/root/docu/redif_1.html
|
||||
" File Extension: rdf
|
||||
" Note: The ReDIF format is used by RePEc.
|
||||
|
||||
" Start with a check for "b:current_syntax". If it is defined, some other
|
||||
" syntax file, earlier in 'runtimepath' was already loaded:
|
||||
if exists("b:current_syntax")
|
||||
" To be compatible with Vim 5.8 use:
|
||||
if version < 600
|
||||
syntax clear
|
||||
elseif exists("b:current_syntax")
|
||||
finish
|
||||
endif
|
||||
|
||||
" Sync: The template-type (ReDIF-Paper, ReDIF-Archive, etc.) influences which
|
||||
" fields can follow. Thus sync must start from the beginning to know which
|
||||
" fields are right or wrong.
|
||||
syntax sync fromstart
|
||||
|
||||
" ReDIF is case-insensitive
|
||||
syntax case ignore
|
||||
|
||||
@ -27,61 +24,80 @@ syntax case ignore
|
||||
" *-Institution
|
||||
" Those fields span a syntax region over several lines so that these regions
|
||||
" can only contain their respective items.
|
||||
"
|
||||
" Other fields (except comments) can only happen in one of these regions.
|
||||
|
||||
" Comments must start with # as the first character of the line, otherwise
|
||||
" I believe that they are considered as part of an argument.
|
||||
syntax region redifComment start=/^#/ end=/$/ containedin=ALL display
|
||||
" Any line which is not a correct template or part of an argument is an error.
|
||||
" This comes at the very beginning, so it has the lowest priority and will
|
||||
" only match if nothing else did.
|
||||
syntax match redifWrongLine /^.\+/ display
|
||||
|
||||
" Beginning: Anything which is not a comment is not allowed before a
|
||||
" "Template-Type:" statement. However, not to trouble the users when beginning
|
||||
" writing a Template-Type, this are not highlighted as errors.
|
||||
syntax region redifIncorrectBeginningOfFile start=/\%^/ end=/^Template-Type:\_s*ReDIF-\%(Paper\|Article\|Chapter\|Book\|Software\|Archive\|Series\|Institution\|Person\) \d\+\.\d\+/me=s-1 contains=redifComment,redifBeginningOfCorrectTemplateType,redifFieldTemplateType
|
||||
syntax match redifBeginningOfCorrectTemplateType /^\cT\%[emplate-Type:]$/ display
|
||||
highlight def link redifWrongLine redifError
|
||||
|
||||
highlight def link redifIncorrectBeginningOfFile redifError
|
||||
" Comments must start with # and it must be the first character of the line,
|
||||
" otherwise I believe that they are considered as part of an argument.
|
||||
syntax match redifComment /^#.*/ containedin=ALL display
|
||||
|
||||
" Defines the 9 possible multi-lines regions of Template-Type and the fields
|
||||
" they can contain.
|
||||
syntax region redifRegionTemplatePaper start=/^Template-Type:\_s*ReDIF-Paper \d\+\.\d\+/ end=/^Template-Type:\_s*ReDIF-\%(Paper\|Article\|Chapter\|Book\|Software\|Archive\|Series\|Institution\|Person\) \d\+\.\d\+/me=s-1 contains=redifUnknownField,redifRegionClusterAuthor,redifRegionClusterFile,redifFieldTitle,redifFieldHandleOfWork,redifFieldLanguage,redifFieldContactEmail,redifFieldAbstract,redifFieldClassificationJEL,redifFieldKeywords,redifFieldNumber,redifFieldCreationDate,redifFieldRevisionDate,redifFieldPublicationStatus,redifFieldNote,redifFieldLength,redifFieldSeries,redifFieldAvailability,redifFieldOrderURL,redifFieldArticleHandle,redifFieldBookHandle,redifFieldChapterHandle,redifFieldPaperHandle,redifFieldSoftwareHandle,redifFieldRestriction,redifFieldPrice,redifFieldNotification,redifFieldPublicationType,redifFieldTemplateType
|
||||
syntax region redifRegionTemplateArticle start=/^Template-Type:\_s*ReDIF-Article \d\+\.\d\+/ end=/^Template-Type:\_s*ReDIF-\%(Paper\|Article\|Chapter\|Book\|Software\|Archive\|Series\|Institution\|Person\) \d\+\.\d\+/me=s-1 contains=redifUnknownField,redifRegionClusterAuthor,redifRegionClusterFile,redifFieldTitle,redifFieldHandleOfWork,redifFieldLanguage,redifFieldContactEmail,redifFieldAbstract,redifFieldClassificationJEL,redifFieldKeywords,redifFieldNumber,redifFieldCreationDate,redifFieldPublicationStatus,redifFieldOrderURL,redifFieldArticleHandle,redifFieldBookHandle,redifFieldChapterHandle,redifFieldPaperHandle,redifFieldSoftwareHandle,redifFieldRestriction,redifFieldPrice,redifFieldNotification,redifFieldPublicationType,redifFieldJournal,redifFieldVolume,redifFieldYear,redifFieldIssue,redifFieldMonth,redifFieldPages,redifFieldNumber,redifFieldArticleHandle,redifFieldBookHandle,redifFieldChapterHandle,redifFieldPaperHandle,redifFieldSoftwareHandle,redifFieldTemplateType
|
||||
syntax region redifRegionTemplateChapter start=/^Template-Type:\_s*ReDIF-Chapter \d\+\.\d\+/ end=/^Template-Type:\_s*ReDIF-\%(Paper\|Article\|Chapter\|Book\|Software\|Archive\|Series\|Institution\|Person\) \d\+\.\d\+/me=s-1 contains=redifUnknownField,redifRegionClusterAuthor,redifRegionClusterFile,redifRegionClusterProvider,redifRegionClusterPublisher,redifRegionClusterEditor,redifFieldHandleOfWork,redifFieldTitle,redifFieldContactEmail,redifFieldAbstract,redifFieldClassificationJEL,redifFieldKeywords,redifFieldBookTitle,redifFieldYear,redifFieldMonth,redifFieldPages,redifFieldChapter,redifFieldVolume,redifFieldEdition,redifFieldSeries,redifFieldISBN,redifFieldPublicationStatus,redifFieldNote,redifFieldInBook,redifFieldOrderURL,redifFieldArticleHandle,redifFieldBookHandle,redifFieldChapterHandle,redifFieldPaperHandle,redifFieldSoftwareHandle,redifFieldTemplateType
|
||||
syntax region redifRegionTemplateBook start=/^Template-Type:\_s*ReDIF-Book \d\+\.\d\+/ end=/^Template-Type:\_s*ReDIF-\%(Paper\|Article\|Chapter\|Book\|Software\|Archive\|Series\|Institution\|Person\) \d\+\.\d\+/me=s-1 contains=redifUnknownField,redifRegionClusterAuthor,redifRegionClusterFile,redifRegionClusterProvider,redifRegionClusterPublisher,redifRegionClusterEditor,redifFieldTitle,redifFieldHandleOfWork,redifFieldContactEmail,redifFieldYear,redifFieldMonth,redifFieldVolume,redifFieldEdition,redifFieldSeries,redifFieldISBN,redifFieldPublicationStatus,redifFieldNote,redifFieldAbstract,redifFieldClassificationJEL,redifFieldKeywords,redifFieldHasChapter,redifFieldPrice,redifFieldOrderURL,redifFieldNumber,redifFieldCreationDate,redifFieldPublicationDate,redifFieldArticleHandle,redifFieldBookHandle,redifFieldChapterHandle,redifFieldPaperHandle,redifFieldSoftwareHandle,redifFieldTemplateType
|
||||
syntax region redifRegionTemplateSoftware start=/^Template-Type:\_s*ReDIF-Software \d\+\.\d\+/ end=/^Template-Type:\_s*ReDIF-\%(Paper\|Article\|Chapter\|Book\|Software\|Archive\|Series\|Institution\|Person\) \d\+\.\d\+/me=s-1 contains=redifUnknownField,redifRegionClusterAuthor,redifRegionClusterFile,redifFieldHandleOfWork,redifFieldTitle,redifFieldProgrammingLanguage,redifFieldAbstract,redifFieldNumber,redifFieldVersion,redifFieldClassificationJEL,redifFieldKeywords,redifFieldSize,redifFieldSeries,redifFieldCreationDate,redifFieldRevisionDate,redifFieldNote,redifFieldRequires,redifFieldArticleHandle,redifFieldBookHandle,redifFieldChapterHandle,redifFieldPaperHandle,redifFieldSoftwareHandle,redifFieldTemplateType
|
||||
syntax region redifRegionTemplateArchive start=/^Template-Type:\_s*ReDIF-Archive \d\+\.\d\+/ end=/^Template-Type:\_s*ReDIF-\%(Paper\|Article\|Chapter\|Book\|Software\|Archive\|Series\|Institution\|Person\) \d\+\.\d\+/me=s-1 contains=redifUnknownField,redifFieldHandleOfArchive,redifFieldURL,redifFieldMaintainerEmail,redifFieldName,redifFieldMaintainerName,redifFieldMaintainerPhone,redifFieldMaintainerFax,redifFieldClassificationJEL,redifFieldHomepage,redifFieldDescription,redifFieldNotification,redifFieldRestriction,redifFieldTemplateType
|
||||
syntax region redifRegionTemplateSeries start=/^Template-Type:\_s*ReDIF-Series \d\+\.\d\+/ end=/^Template-Type:\_s*ReDIF-\%(Paper\|Article\|Chapter\|Book\|Software\|Archive\|Series\|Institution\|Person\) \d\+\.\d\+/me=s-1 contains=redifUnknownField,redifRegionClusterProvider,redifRegionClusterPublisher,redifRegionClusterEditor,redifFieldName,redifFieldHandleOfSeries,redifFieldMaintainerEmail,redifFieldType,redifFieldOrderEmail,redifFieldOrderHomepage,redifFieldOrderPostal,redifFieldPrice,redifFieldRestriction,redifFieldMaintainerPhone,redifFieldMaintainerFax,redifFieldMaintainerName,redifFieldDescription,redifFieldClassificationJEL,redifFieldKeywords,redifFieldNotification,redifFieldISSN,redifFieldFollowup,redifFieldPredecessor,redifFieldTemplateType
|
||||
syntax region redifRegionTemplateInstitution start=/^Template-Type:\_s*ReDIF-Institution \d\+\.\d\+/ end=/^Template-Type:\_s*ReDIF-\%(Paper\|Article\|Chapter\|Book\|Software\|Archive\|Series\|Institution\|Person\) \d\+\.\d\+/me=s-1 contains=redifUnknownField,redifRegionClusterPrimary,redifRegionClusterSecondary,redifRegionClusterTertiary,redifRegionClusterQuaternary,redifFieldHandleOfInstitution,redifFieldPrimaryDefunct,redifFieldSecondaryDefunct,redifFieldTertiaryDefunct,redifFieldTemplateType
|
||||
syntax region redifRegionTemplatePerson start=/^Template-Type:\_s*ReDIF-Person \d\+\.\d\+/ end=/^Template-Type:\_s*ReDIF-\%(Paper\|Article\|Chapter\|Book\|Software\|Archive\|Series\|Institution\|Person\) \d\+\.\d\+/me=s-1 contains=redifUnknownField,redifRegionClusterWorkplace,redifFieldHandleOfPerson,redifFieldNameFull,redifFieldNameFirst,redifFieldNameLast,redifFieldNamePrefix,redifFieldNameMiddle,redifFieldNameSuffix,redifFieldNameASCII,redifFieldEmail,redifFieldHomepage,redifFieldFax,redifFieldPostal,redifFieldPhone,redifFieldWorkplaceOrganization,redifFieldAuthorPaper,redifFieldAuthorArticle,redifFieldAuthorSoftware,redifFieldAuthorBook,redifFieldAuthorChapter,redifFieldEditorBook,redifFieldEditorSeries,redifFieldClassificationJEL,redifFieldShortId,redifFieldLastLoginDate,redifFieldRegisteredDate,redifFieldTemplateType
|
||||
syntax region redifRegionTemplatePaper start=/^Template-Type:\_s*ReDIF-Paper \d\+\.\d\+/ end=/^Template-Type:/me=s-1 contains=redifContainerFieldsPaper,redifWrongLine,redifRegionClusterAuthor,redifRegionClusterFile fold
|
||||
syntax region redifRegionTemplateArticle start=/^Template-Type:\_s*ReDIF-Article \d\+\.\d\+/ end=/^Template-Type:/me=s-1 contains=redifContainerFieldsArticle,redifWrongLine,redifRegionClusterAuthor,redifRegionClusterFile fold
|
||||
syntax region redifRegionTemplateChapter start=/^Template-Type:\_s*ReDIF-Chapter \d\+\.\d\+/ end=/^Template-Type:/me=s-1 contains=redifContainerFieldsChapter,redifWrongLine,redifRegionClusterAuthor,redifRegionClusterFile,redifRegionClusterProvider,redifRegionClusterPublisher,redifRegionClusterEditor fold
|
||||
syntax region redifRegionTemplateBook start=/^Template-Type:\_s*ReDIF-Book \d\+\.\d\+/ end=/^Template-Type:/me=s-1 contains=redifContainerFieldsBook,redifWrongLine,redifRegionClusterAuthor,redifRegionClusterFile,redifRegionClusterProvider,redifRegionClusterPublisher,redifRegionClusterEditor fold
|
||||
syntax region redifRegionTemplateSoftware start=/^Template-Type:\_s*ReDIF-Software \d\+\.\d\+/ end=/^Template-Type:/me=s-1 contains=redifContainerFieldsSoftware,redifWrongLine,redifRegionClusterAuthor,redifRegionClusterFile fold
|
||||
syntax region redifRegionTemplateArchive start=/^Template-Type:\_s*ReDIF-Archive \d\+\.\d\+/ end=/^Template-Type:/me=s-1 contains=redifContainerFieldsArchive,redifWrongLine fold
|
||||
syntax region redifRegionTemplateSeries start=/^Template-Type:\_s*ReDIF-Series \d\+\.\d\+/ end=/^Template-Type:/me=s-1 contains=redifContainerFieldsSeries,redifWrongLine,redifRegionClusterProvider,redifRegionClusterPublisher,redifRegionClusterEditor fold
|
||||
syntax region redifRegionTemplateInstitution start=/^Template-Type:\_s*ReDIF-Institution \d\+\.\d\+/ end=/^Template-Type:/me=s-1 contains=redifContainerFieldsInstitution,redifWrongLine,redifRegionClusterPrimary,redifRegionClusterSecondary,redifRegionClusterTertiary,redifRegionClusterQuaternary fold
|
||||
syntax region redifRegionTemplatePerson start=/^Template-Type:\_s*ReDIF-Person \d\+\.\d\+/ end=/^Template-Type:/me=s-1 contains=redifContainerFieldsPerson,redifWrongLine,redifRegionClusterWorkplace fold
|
||||
|
||||
" For each template, non-whitespaces ending with a colon must be
|
||||
" correct fields. By default, they are wrong fields.
|
||||
syntax match redifUnknownField /^\S\{-1,}:/ contained display
|
||||
" All fields are foldable (These come before clusters, so they have lower
|
||||
" priority). So they are contained in a foldable syntax region.
|
||||
syntax region redifContainerFieldsPaper start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldTitle,redifFieldHandleOfWork,redifFieldLanguage,redifFieldContactEmail,redifFieldAbstract,redifFieldClassificationJEL,redifFieldKeywords,redifFieldNumber,redifFieldCreationDate,redifFieldRevisionDate,redifFieldPublicationStatus,redifFieldNote,redifFieldLength,redifFieldSeries,redifFieldAvailability,redifFieldOrderURL,redifFieldArticleHandle,redifFieldBookHandle,redifFieldChapterHandle,redifFieldPaperHandle,redifFieldSoftwareHandle,redifFieldRestriction,redifFieldPrice,redifFieldNotification,redifFieldPublicationType,redifFieldTemplateType,redifWrongLine contained transparent fold
|
||||
syntax region redifContainerFieldsArticle start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldTitle,redifFieldHandleOfWork,redifFieldLanguage,redifFieldContactEmail,redifFieldAbstract,redifFieldClassificationJEL,redifFieldKeywords,redifFieldNumber,redifFieldCreationDate,redifFieldPublicationStatus,redifFieldOrderURL,redifFieldArticleHandle,redifFieldBookHandle,redifFieldChapterHandle,redifFieldPaperHandle,redifFieldSoftwareHandle,redifFieldRestriction,redifFieldPrice,redifFieldNotification,redifFieldPublicationType,redifFieldJournal,redifFieldVolume,redifFieldYear,redifFieldIssue,redifFieldMonth,redifFieldPages,redifFieldNumber,redifFieldArticleHandle,redifFieldBookHandle,redifFieldChapterHandle,redifFieldPaperHandle,redifFieldSoftwareHandle,redifFieldTemplateType,redifWrongLine contained transparent fold
|
||||
syntax region redifContainerFieldsChapter start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldHandleOfWork,redifFieldTitle,redifFieldContactEmail,redifFieldAbstract,redifFieldClassificationJEL,redifFieldKeywords,redifFieldBookTitle,redifFieldYear,redifFieldMonth,redifFieldPages,redifFieldChapter,redifFieldVolume,redifFieldEdition,redifFieldSeries,redifFieldISBN,redifFieldPublicationStatus,redifFieldNote,redifFieldInBook,redifFieldOrderURL,redifFieldArticleHandle,redifFieldBookHandle,redifFieldChapterHandle,redifFieldPaperHandle,redifFieldSoftwareHandle,redifFieldTemplateType,redifWrongLine contained transparent fold
|
||||
syntax region redifContainerFieldsBook start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldTitle,redifFieldHandleOfWork,redifFieldContactEmail,redifFieldYear,redifFieldMonth,redifFieldVolume,redifFieldEdition,redifFieldSeries,redifFieldISBN,redifFieldPublicationStatus,redifFieldNote,redifFieldAbstract,redifFieldClassificationJEL,redifFieldKeywords,redifFieldHasChapter,redifFieldPrice,redifFieldOrderURL,redifFieldNumber,redifFieldCreationDate,redifFieldPublicationDate,redifFieldArticleHandle,redifFieldBookHandle,redifFieldChapterHandle,redifFieldPaperHandle,redifFieldSoftwareHandle,redifFieldTemplateType,redifWrongLine contained transparent fold
|
||||
syntax region redifContainerFieldsSoftware start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldHandleOfWork,redifFieldTitle,redifFieldProgrammingLanguage,redifFieldAbstract,redifFieldNumber,redifFieldVersion,redifFieldClassificationJEL,redifFieldKeywords,redifFieldSize,redifFieldSeries,redifFieldCreationDate,redifFieldRevisionDate,redifFieldNote,redifFieldRequires,redifFieldArticleHandle,redifFieldBookHandle,redifFieldChapterHandle,redifFieldPaperHandle,redifFieldSoftwareHandle,redifFieldTemplateType,redifWrongLine contained transparent fold
|
||||
syntax region redifContainerFieldsArchive start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldHandleOfArchive,redifFieldURL,redifFieldMaintainerEmail,redifFieldName,redifFieldMaintainerName,redifFieldMaintainerPhone,redifFieldMaintainerFax,redifFieldClassificationJEL,redifFieldHomepage,redifFieldDescription,redifFieldNotification,redifFieldRestriction,redifFieldTemplateType,redifWrongLine contained transparent fold
|
||||
syntax region redifContainerFieldsSeries start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldName,redifFieldHandleOfSeries,redifFieldMaintainerEmail,redifFieldType,redifFieldOrderEmail,redifFieldOrderHomepage,redifFieldOrderPostal,redifFieldPrice,redifFieldRestriction,redifFieldMaintainerPhone,redifFieldMaintainerFax,redifFieldMaintainerName,redifFieldDescription,redifFieldClassificationJEL,redifFieldKeywords,redifFieldNotification,redifFieldISSN,redifFieldFollowup,redifFieldPredecessor,redifFieldTemplateType,redifWrongLine contained transparent fold
|
||||
syntax region redifContainerFieldsInstitution start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldHandleOfInstitution,redifFieldPrimaryDefunct,redifFieldSecondaryDefunct,redifFieldTertiaryDefunct,redifFieldTemplateType,redifWrongLine contained transparent fold
|
||||
syntax region redifContainerFieldsPerson start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldHandleOfPerson,redifFieldNameFull,redifFieldNameFirst,redifFieldNameLast,redifFieldNamePrefix,redifFieldNameMiddle,redifFieldNameSuffix,redifFieldNameASCII,redifFieldEmail,redifFieldHomepage,redifFieldFax,redifFieldPostal,redifFieldPhone,redifFieldWorkplaceOrganization,redifFieldAuthorPaper,redifFieldAuthorArticle,redifFieldAuthorSoftware,redifFieldAuthorBook,redifFieldAuthorChapter,redifFieldEditorBook,redifFieldEditorSeries,redifFieldClassificationJEL,redifFieldShortId,redifFieldLastLoginDate,redifFieldRegisteredDate,redifWrongLine contained transparent fold
|
||||
|
||||
highlight def link redifUnknownField redifError
|
||||
" Defines the 10 possible clusters and what they can contain
|
||||
" A field not in the cluster ends the cluster.
|
||||
syntax region redifRegionClusterWorkplace start=/^Workplace-Name:/ skip=/^Workplace-\%(Name-English\|Homepage\|Postal\|Location\|Email\|Phone\|Fax\|Institution\):/ end=/^\S\{-}:/me=s-1 contained contains=redifWrongLine,redifContainerFieldsWorkplace fold
|
||||
syntax region redifRegionClusterPrimary start=/^Primary-Name:/ skip=/^Primary-\%(Name-English\|Homepage\|Postal\|Location\|Email\|Phone\|Fax\|Institution\):/ end=/^\S\{-}:/me=s-1 contained contains=redifWrongLine,redifContainerFieldsPrimary fold
|
||||
syntax region redifRegionClusterSecondary start=/^Secondary-Name:/ skip=/^Secondary-\%(Name-English\|Homepage\|Postal\|Location\|Email\|Phone\|Fax\|Institution\):/ end=/^\S\{-}:/me=s-1 contained contains=redifWrongLine,redifContainerFieldsSecondary fold
|
||||
syntax region redifRegionClusterTertiary start=/^Tertiary-Name:/ skip=/^Tertiary-\%(Name-English\|Homepage\|Postal\|Location\|Email\|Phone\|Fax\|Institution\):/ end=/^\S\{-}:/me=s-1 contained contains=redifWrongLine,redifContainerFieldsTertiary fold
|
||||
syntax region redifRegionClusterQuaternary start=/^Quaternary-Name:/ skip=/^Quaternary-\%(Name-English\|Homepage\|Postal\|Location\|Email\|Phone\|Fax\|Institution\):/ end=/^\S\{-}:/me=s-1 contained contains=redifWrongLine,redifContainerFieldsQuaternary fold
|
||||
syntax region redifRegionClusterProvider start=/^Provider-Name:/ skip=/^Provider-\%(Name-English\|Homepage\|Postal\|Location\|Email\|Phone\|Fax\|Institution\):/ end=/^\S\{-}:/me=s-1 contained contains=redifWrongLine,redifContainerFieldsProvider fold
|
||||
syntax region redifRegionClusterPublisher start=/^Publisher-Name:/ skip=/^Publisher-\%(Name-English\|Homepage\|Postal\|Location\|Email\|Phone\|Fax\|Institution\):/ end=/^\S\{-}:/me=s-1 contained contains=redifWrongLine,redifContainerFieldsPublisher fold
|
||||
syntax region redifRegionClusterAuthor start=/^Author-Name:/ skip=/^Author-\%(Name\%(-First\|-Last\)\|Homepage\|Email\|Fax\|Postal\|Phone\|Person\|Workplace-Name\):/ end=/^\S\{-}:/me=s-1 contained contains=redifWrongLine,redifRegionClusterAuthorWorkplace,redifContainerFieldsAuthor fold
|
||||
syntax region redifRegionClusterEditor start=/^Editor-Name:/ skip=/^Editor-\%(Name\%(-First\|-Last\)\|Homepage\|Email\|Fax\|Postal\|Phone\|Person\|Workplace-Name\):/ end=/^\S\{-}:/me=s-1 contained contains=redifWrongLine,redifRegionClusterEditorWorkplace,redifContainerFieldsEditor fold
|
||||
syntax region redifRegionClusterFile start=/^File-URL:/ skip=/^File-\%(Format\|Function\|Size\|Restriction\):/ end=/^\S\{-}:/me=s-1 contained contains=redifWrongLine,redifContainerFieldsFile fold
|
||||
|
||||
" Defines the 12 possible clusters and what they can contain
|
||||
syntax region redifRegionClusterAuthorWorkplace start=/^Author-Workplace-Name:/ skip=/^Author-Workplace-\%(Name-English\|Homepage\|Postal\|Location\|Email\|Phone\|Fax\|Institution\):/ end=/^\c\S\{-1,}:/me=s-1 contained contains=redifFieldAuthorWorkplaceName,redifFieldAuthorWorkplaceHomepage,redifFieldAuthorWorkplaceNameEnglish,redifFieldAuthorWorkplacePostal,redifFieldAuthorWorkplaceLocation,redifFieldAuthorWorkplaceEmail,redifFieldAuthorWorkplacePhone,redifFieldAuthorWorkplaceFax,redifFieldAuthorWorkplaceInstitution
|
||||
syntax region redifRegionClusterEditorWorkplace start=/^Editor-Workplace-Name:/ skip=/^Editor-Workplace-\%(Name-English\|Homepage\|Postal\|Location\|Email\|Phone\|Fax\|Institution\):/ end=/^\c\S\{-1,}:/me=s-1 contained contains=redifFieldEditorWorkplaceName,redifFieldEditorWorkplaceHomepage,redifFieldEditorWorkplaceNameEnglish,redifFieldEditorWorkplacePostal,redifFieldEditorWorkplaceLocation,redifFieldEditorWorkplaceEmail,redifFieldEditorWorkplacePhone,redifFieldEditorWorkplaceFax,redifFieldEditorWorkplaceInstitution
|
||||
syntax region redifRegionClusterWorkplace start=/^Workplace-Name:/ skip=/^Workplace-\%(Name-English\|Homepage\|Postal\|Location\|Email\|Phone\|Fax\|Institution\):/ end=/^\c\S\{-1,}:/me=s-1 contained contains=redifFieldWorkplaceName,redifFieldWorkplaceHomepage,redifFieldWorkplaceNameEnglish,redifFieldWorkplacePostal,redifFieldWorkplaceLocation,redifFieldWorkplaceEmail,redifFieldWorkplacePhone,redifFieldWorkplaceFax,redifFieldWorkplaceInstitution
|
||||
syntax region redifRegionClusterPrimary start=/^Primary-Name:/ skip=/^Primary-\%(Name-English\|Homepage\|Postal\|Location\|Email\|Phone\|Fax\|Institution\):/ end=/^\c\S\{-1,}:/me=s-1 contained contains=redifFieldPrimaryName,redifFieldPrimaryHomepage,redifFieldPrimaryNameEnglish,redifFieldPrimaryPostal,redifFieldPrimaryLocation,redifFieldPrimaryEmail,redifFieldPrimaryPhone,redifFieldPrimaryFax,redifFieldPrimaryInstitution
|
||||
syntax region redifRegionClusterSecondary start=/^Secondary-Name:/ skip=/^Secondary-\%(Name-English\|Homepage\|Postal\|Location\|Email\|Phone\|Fax\|Institution\):/ end=/^\c\S\{-1,}:/me=s-1 contained contains=redifFieldSecondaryName,redifFieldSecondaryHomepage,redifFieldSecondaryNameEnglish,redifFieldSecondaryPostal,redifFieldSecondaryLocation,redifFieldSecondaryEmail,redifFieldSecondaryPhone,redifFieldSecondaryFax,redifFieldSecondaryInstitution
|
||||
syntax region redifRegionClusterTertiary start=/^Tertiary-Name:/ skip=/^Tertiary-\%(Name-English\|Homepage\|Postal\|Location\|Email\|Phone\|Fax\|Institution\):/ end=/^\c\S\{-1,}:/me=s-1 contained contains=redifFieldTertiaryName,redifFieldTertiaryHomepage,redifFieldTertiaryNameEnglish,redifFieldTertiaryPostal,redifFieldTertiaryLocation,redifFieldTertiaryEmail,redifFieldTertiaryPhone,redifFieldTertiaryFax,redifFieldTertiaryInstitution
|
||||
syntax region redifRegionClusterQuaternary start=/^Quaternary-Name:/ skip=/^Quaternary-\%(Name-English\|Homepage\|Postal\|Location\|Email\|Phone\|Fax\|Institution\):/ end=/^\c\S\{-1,}:/me=s-1 contained contains=redifFieldQuaternaryName,redifFieldQuaternaryHomepage,redifFieldQuaternaryNameEnglish,redifFieldQuaternaryPostal,redifFieldQuaternaryLocation,redifFieldQuaternaryEmail,redifFieldQuaternaryPhone,redifFieldQuaternaryFax,redifFieldQuaternaryInstitution
|
||||
syntax region redifRegionClusterProvider start=/^Provider-Name:/ skip=/^Provider-\%(Name-English\|Homepage\|Postal\|Location\|Email\|Phone\|Fax\|Institution\):/ end=/^\c\S\{-1,}:/me=s-1 contained contains=redifFieldProviderName,redifFieldProviderHomepage,redifFieldProviderNameEnglish,redifFieldProviderPostal,redifFieldProviderLocation,redifFieldProviderEmail,redifFieldProviderPhone,redifFieldProviderFax,redifFieldProviderInstitution
|
||||
syntax region redifRegionClusterPublisher start=/^Publisher-Name:/ skip=/^Publisher-\%(Name-English\|Homepage\|Postal\|Location\|Email\|Phone\|Fax\|Institution\):/ end=/^\c\S\{-1,}:/me=s-1 contained contains=redifFieldPublisherName,redifFieldPublisherHomepage,redifFieldPublisherNameEnglish,redifFieldPublisherPostal,redifFieldPublisherLocation,redifFieldPublisherEmail,redifFieldPublisherPhone,redifFieldPublisherFax,redifFieldPublisherInstitution
|
||||
syntax region redifRegionClusterAuthor start=/^Author-Name:/ skip=/^Author-\%(Name\%(-First\|-Last\)\|Homepage\|Email\|Fax\|Postal\|Phone\|Person\|Workplace-Name\):/ end=/^\c\S\{-1,}:/me=s-1 contained contains=redifRegionClusterAuthorWorkplace,redifFieldAuthorName,redifFieldAuthorNameFirst,redifFieldAuthorNameLast,redifFieldAuthorHomepage,redifFieldAuthorEmail,redifFieldAuthorFax,redifFieldAuthorPostal,redifFieldAuthorPhone,redifFieldAuthorPerson
|
||||
syntax region redifRegionClusterEditor start=/^Editor-Name:/ skip=/^Editor-\%(Name\%(-First\|-Last\)\|Homepage\|Email\|Fax\|Postal\|Phone\|Person\|Workplace-Name\):/ end=/^\c\S\{-1,}:/me=s-1 contained contains=redifRegionClusterEditorWorkplace,redifFieldEditorName,redifFieldEditorNameFirst,redifFieldEditorNameLast,redifFieldEditorHomepage,redifFieldEditorEmail,redifFieldEditorFax,redifFieldEditorPostal,redifFieldEditorPhone,redifFieldEditorPerson
|
||||
syntax region redifRegionClusterFile start=/^File-URL:/ skip=/^File-\%(Format\|Function\|Size\|Restriction\):/ end=/^\c\S\{-1,}:/me=s-1 contained contains=redifFieldFileURL,redifFieldFileFormat,redifFieldFileFunction,redifFieldFileSize,redifFieldFileRestriction
|
||||
" The foldable containers of the clusters.
|
||||
syntax region redifContainerFieldsWorkplace start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldWorkplaceName,redifFieldWorkplaceHomepage,redifFieldWorkplaceNameEnglish,redifFieldWorkplacePostal,redifFieldWorkplaceLocation,redifFieldWorkplaceEmail,redifFieldWorkplacePhone,redifFieldWorkplaceFax,redifFieldWorkplaceInstitution,redifWrongLine contained transparent fold
|
||||
syntax region redifContainerFieldsPrimary start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldPrimaryName,redifFieldPrimaryHomepage,redifFieldPrimaryNameEnglish,redifFieldPrimaryPostal,redifFieldPrimaryLocation,redifFieldPrimaryEmail,redifFieldPrimaryPhone,redifFieldPrimaryFax,redifFieldPrimaryInstitution,redifWrongLine contained transparent fold
|
||||
syntax region redifContainerFieldsSecondary start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldSecondaryName,redifFieldSecondaryHomepage,redifFieldSecondaryNameEnglish,redifFieldSecondaryPostal,redifFieldSecondaryLocation,redifFieldSecondaryEmail,redifFieldSecondaryPhone,redifFieldSecondaryFax,redifFieldSecondaryInstitution,redifWrongLine contained transparent fold
|
||||
syntax region redifContainerFieldsTertiary start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldTertiaryName,redifFieldTertiaryHomepage,redifFieldTertiaryNameEnglish,redifFieldTertiaryPostal,redifFieldTertiaryLocation,redifFieldTertiaryEmail,redifFieldTertiaryPhone,redifFieldTertiaryFax,redifFieldTertiaryInstitution,redifWrongLine contained transparent fold
|
||||
syntax region redifContainerFieldsQuaternary start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldQuaternaryName,redifFieldQuaternaryHomepage,redifFieldQuaternaryNameEnglish,redifFieldQuaternaryPostal,redifFieldQuaternaryLocation,redifFieldQuaternaryEmail,redifFieldQuaternaryPhone,redifFieldQuaternaryFax,redifFieldQuaternaryInstitution,redifWrongLine contained transparent fold
|
||||
syntax region redifContainerFieldsProvider start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldProviderName,redifFieldProviderHomepage,redifFieldProviderNameEnglish,redifFieldProviderPostal,redifFieldProviderLocation,redifFieldProviderEmail,redifFieldProviderPhone,redifFieldProviderFax,redifFieldProviderInstitution,redifWrongLine contained transparent fold
|
||||
syntax region redifContainerFieldsPublisher start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldPublisherName,redifFieldPublisherHomepage,redifFieldPublisherNameEnglish,redifFieldPublisherPostal,redifFieldPublisherLocation,redifFieldPublisherEmail,redifFieldPublisherPhone,redifFieldPublisherFax,redifFieldPublisherInstitution,redifWrongLine contained transparent fold
|
||||
syntax region redifContainerFieldsAuthor start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldAuthorName,redifFieldAuthorNameFirst,redifFieldAuthorNameLast,redifFieldAuthorHomepage,redifFieldAuthorEmail,redifFieldAuthorFax,redifFieldAuthorPostal,redifFieldAuthorPhone,redifFieldAuthorPerson,redifWrongLine contained transparent fold
|
||||
syntax region redifContainerFieldsEditor start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldEditorName,redifFieldEditorNameFirst,redifFieldEditorNameLast,redifFieldEditorHomepage,redifFieldEditorEmail,redifFieldEditorFax,redifFieldEditorPostal,redifFieldEditorPhone,redifFieldEditorPerson,redifWrongLine contained transparent fold
|
||||
syntax region redifContainerFieldsFile start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldFileURL,redifFieldFileFormat,redifFieldFileFunction,redifFieldFileSize,redifFieldFileRestriction,redifWrongLine contained transparent fold
|
||||
|
||||
" A field not in the cluster ends the cluster, so no need to define wrong
|
||||
" fields, because they will be handled by the containing UnknownField region
|
||||
" immediately when exiting the cluster.
|
||||
" The two clusters in cluster (must be presented after to have priority over
|
||||
" fields containers)
|
||||
syntax region redifRegionClusterAuthorWorkplace start=/^Author-Workplace-Name:/ skip=/^Author-Workplace-\%(Name-English\|Homepage\|Postal\|Location\|Email\|Phone\|Fax\|Institution\):/ end=/^\S\{-}:/me=s-1 contained contains=redifWrongLine,redifContainerFieldsAuthorWorkplace fold
|
||||
syntax region redifRegionClusterEditorWorkplace start=/^Editor-Workplace-Name:/ skip=/^Editor-Workplace-\%(Name-English\|Homepage\|Postal\|Location\|Email\|Phone\|Fax\|Institution\):/ end=/^\S\{-}:/me=s-1 contained contains=redifWrongLine,redifContainerFieldsEditorWorkplace fold
|
||||
|
||||
" Their foldable fields containers
|
||||
syntax region redifContainerFieldsAuthorWorkplace start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldAuthorWorkplaceName,redifFieldAuthorWorkplaceHomepage,redifFieldAuthorWorkplaceNameEnglish,redifFieldAuthorWorkplacePostal,redifFieldAuthorWorkplaceLocation,redifFieldAuthorWorkplaceEmail,redifFieldAuthorWorkplacePhone,redifFieldAuthorWorkplaceFax,redifFieldAuthorWorkplaceInstitution,redifWrongLine contained transparent fold
|
||||
syntax region redifContainerFieldsEditorWorkplace start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldEditorWorkplaceName,redifFieldEditorWorkplaceHomepage,redifFieldEditorWorkplaceNameEnglish,redifFieldEditorWorkplacePostal,redifFieldEditorWorkplaceLocation,redifFieldEditorWorkplaceEmail,redifFieldEditorWorkplacePhone,redifFieldEditorWorkplaceFax,redifFieldEditorWorkplaceInstitution,redifWrongLine contained transparent fold
|
||||
|
||||
" All the possible fields
|
||||
" Note: The "Handle" field is handled a little bit differently, because it
|
||||
" does not have the same meaning depending on the Template-Type.
|
||||
" /redifFieldHandleOf....
|
||||
" Note: The "Handle" field is handled a little bit differently, because it
|
||||
" does not have the same meaning depending on the Template-Type. See:
|
||||
" /redifFieldHandleOf....
|
||||
syntax match redifFieldAbstract /^Abstract:/ skipwhite skipempty nextgroup=redifArgumentAbstract contained
|
||||
syntax match redifFieldArticleHandle /^Article-Handle:/ skipwhite skipempty nextgroup=redifArgumentArticleHandle contained
|
||||
syntax match redifFieldAuthorArticle /^Author-Article:/ skipwhite skipempty nextgroup=redifArgumentAuthorArticle contained
|
||||
@ -211,15 +227,6 @@ syntax match redifFieldProviderPostal /^Provider-Postal:/ skipwhite skipempty ne
|
||||
syntax match redifFieldPublicationDate /^Publication-Date:/ skipwhite skipempty nextgroup=redifArgumentPublicationDate contained
|
||||
syntax match redifFieldPublicationStatus /^Publication-Status:/ skipwhite skipempty nextgroup=redifArgumentPublicationStatus contained
|
||||
syntax match redifFieldPublicationType /^Publication-Type:/ skipwhite skipempty nextgroup=redifArgumentPublicationType contained
|
||||
syntax match redifFieldPublisherEmail /^Publisher-Email:/ skipwhite skipempty nextgroup=redifArgumentPublisherEmail contained
|
||||
syntax match redifFieldPublisherFax /^Publisher-Fax:/ skipwhite skipempty nextgroup=redifArgumentPublisherFax contained
|
||||
syntax match redifFieldPublisherHomepage /^Publisher-Homepage:/ skipwhite skipempty nextgroup=redifArgumentPublisherHomepage contained
|
||||
syntax match redifFieldPublisherInstitution /^Publisher-Institution:/ skipwhite skipempty nextgroup=redifArgumentPublisherInstitution contained
|
||||
syntax match redifFieldPublisherLocation /^Publisher-Location:/ skipwhite skipempty nextgroup=redifArgumentPublisherLocation contained
|
||||
syntax match redifFieldPublisherName /^Publisher-Name:/ skipwhite skipempty nextgroup=redifArgumentPublisherName contained
|
||||
syntax match redifFieldPublisherNameEnglish /^Publisher-Name-English:/ skipwhite skipempty nextgroup=redifArgumentPublisherNameEnglish contained
|
||||
syntax match redifFieldPublisherPhone /^Publisher-Phone:/ skipwhite skipempty nextgroup=redifArgumentPublisherPhone contained
|
||||
syntax match redifFieldPublisherPostal /^Publisher-Postal:/ skipwhite skipempty nextgroup=redifArgumentPublisherPostal contained
|
||||
syntax match redifFieldQuaternaryEmail /^Quaternary-Email:/ skipwhite skipempty nextgroup=redifArgumentQuaternaryEmail contained
|
||||
syntax match redifFieldQuaternaryFax /^Quaternary-Fax:/ skipwhite skipempty nextgroup=redifArgumentQuaternaryFax contained
|
||||
syntax match redifFieldQuaternaryHomepage /^Quaternary-Homepage:/ skipwhite skipempty nextgroup=redifArgumentQuaternaryHomepage contained
|
||||
@ -404,15 +411,6 @@ highlight def link redifFieldProviderPostal redifField
|
||||
highlight def link redifFieldPublicationDate redifField
|
||||
highlight def link redifFieldPublicationStatus redifField
|
||||
highlight def link redifFieldPublicationType redifField
|
||||
highlight def link redifFieldPublisherEmail redifField
|
||||
highlight def link redifFieldPublisherFax redifField
|
||||
highlight def link redifFieldPublisherHomepage redifField
|
||||
highlight def link redifFieldPublisherInstitution redifField
|
||||
highlight def link redifFieldPublisherLocation redifField
|
||||
highlight def link redifFieldPublisherName redifField
|
||||
highlight def link redifFieldPublisherNameEnglish redifField
|
||||
highlight def link redifFieldPublisherPhone redifField
|
||||
highlight def link redifFieldPublisherPostal redifField
|
||||
highlight def link redifFieldQuaternaryEmail redifField
|
||||
highlight def link redifFieldQuaternaryFax redifField
|
||||
highlight def link redifFieldQuaternaryHomepage redifField
|
||||
@ -469,129 +467,156 @@ highlight def link redifFieldWorkplacePhone redifField
|
||||
highlight def link redifFieldWorkplacePostal redifField
|
||||
highlight def link redifFieldYear redifField
|
||||
|
||||
" Deprecated
|
||||
" same as Provider-*
|
||||
" nextgroup=redifArgumentProvider*
|
||||
syntax match redifFieldPublisherEmail /^Publisher-Email:/ skipwhite skipempty nextgroup=redifArgumentProviderEmail contained
|
||||
syntax match redifFieldPublisherFax /^Publisher-Fax:/ skipwhite skipempty nextgroup=redifArgumentProviderFax contained
|
||||
syntax match redifFieldPublisherHomepage /^Publisher-Homepage:/ skipwhite skipempty nextgroup=redifArgumentProviderHomepage contained
|
||||
syntax match redifFieldPublisherInstitution /^Publisher-Institution:/ skipwhite skipempty nextgroup=redifArgumentProviderInstitution contained
|
||||
syntax match redifFieldPublisherLocation /^Publisher-Location:/ skipwhite skipempty nextgroup=redifArgumentProviderLocation contained
|
||||
syntax match redifFieldPublisherName /^Publisher-Name:/ skipwhite skipempty nextgroup=redifArgumentProviderName contained
|
||||
syntax match redifFieldPublisherNameEnglish /^Publisher-Name-English:/ skipwhite skipempty nextgroup=redifArgumentProviderNameEnglish contained
|
||||
syntax match redifFieldPublisherPhone /^Publisher-Phone:/ skipwhite skipempty nextgroup=redifArgumentProviderPhone contained
|
||||
syntax match redifFieldPublisherPostal /^Publisher-Postal:/ skipwhite skipempty nextgroup=redifArgumentProviderPostal contained
|
||||
|
||||
highlight def link redifFieldPublisherEmail redifFieldDeprecated
|
||||
highlight def link redifFieldPublisherFax redifFieldDeprecated
|
||||
highlight def link redifFieldPublisherHomepage redifFieldDeprecated
|
||||
highlight def link redifFieldPublisherInstitution redifFieldDeprecated
|
||||
highlight def link redifFieldPublisherLocation redifFieldDeprecated
|
||||
highlight def link redifFieldPublisherName redifFieldDeprecated
|
||||
highlight def link redifFieldPublisherNameEnglish redifFieldDeprecated
|
||||
highlight def link redifFieldPublisherPhone redifFieldDeprecated
|
||||
highlight def link redifFieldPublisherPostal redifFieldDeprecated
|
||||
|
||||
" Standard arguments
|
||||
" Contains all the remaining line if it is not a new field
|
||||
" /\%(^\S\{-}:\)\@!\S.*/
|
||||
" Note: Those arguments are not highlighted so far. They are here for
|
||||
" future extensions.
|
||||
" Note: Those matches do not extend further the end of the line. They are
|
||||
" unfit for arguments that may span several lines like Title, Abstract,
|
||||
" Postal. They are well-fit for arguments that must not span more than one
|
||||
" line by definition, such as URLs, Email addresses, etc.
|
||||
" By default, they contain all the argument until another field is started:
|
||||
" start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1
|
||||
" For arguments that must not span more than one line, use a match:
|
||||
" /\%(^\S\{-}:\)\@!\S.*/
|
||||
" AND ADD "display"
|
||||
" This is faster.
|
||||
"
|
||||
" Those arguments are not highlighted so far. They are here for future
|
||||
" extensions.
|
||||
" TODO Find more RegEx for these arguments
|
||||
" TODO Fax, Phone
|
||||
" TODO URL, Homepage
|
||||
" TODO Keywords
|
||||
" TODO Classification-JEL
|
||||
" TODO Short-Id, Author-Person, Editor-Person
|
||||
"syntax match redifArgumentAuthorFax /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentAuthorHomepage /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentAuthorName /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentAuthorNameFirst /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentAuthorNameLast /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentAuthorPerson /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentAuthorPhone /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentAuthorPostal /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentAuthorWorkplaceFax /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentAuthorWorkplaceHomepage /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentAuthorWorkplaceLocation /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentAuthorWorkplaceName /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentAuthorWorkplaceNameEnglish /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentAuthorWorkplacePhone /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentAuthorWorkplacePostal /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentEditorFax /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentEditorHomepage /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentEditorName /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentEditorNameFirst /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentEditorNameLast /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentEditorPerson /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentEditorPhone /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentEditorPostal /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentEditorWorkplaceFax /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentEditorWorkplaceHomepage /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentEditorWorkplaceLocation /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentEditorWorkplaceName /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentEditorWorkplaceNameEnglish /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentEditorWorkplacePhone /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentEditorWorkplacePostal /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentFax /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentFileFunction /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentFileURL /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentHomepage /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentIssue /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentJournal /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentMaintainerFax /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentMaintainerName /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentMaintainerPhone /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentNameFirst /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentNameFull /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentNameLast /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentNameMiddle /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentNamePrefix /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentNameSuffix /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentName /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentOrderHomepage /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentOrderPostal /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentOrderURL /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentPhone /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentPostal /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentPrice /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentPrimaryFax /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentPrimaryHomepage /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentPrimaryLocation /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentPrimaryName /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentPrimaryNameEnglish /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentPrimaryPhone /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentPrimaryPostal /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentProviderFax /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentProviderHomepage /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentProviderLocation /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentProviderName /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentProviderNameEnglish /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentProviderPhone /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentProviderPostal /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentPublisherFax /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentPublisherHomepage /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentPublisherLocation /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentPublisherName /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentPublisherNameEnglish /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentPublisherPhone /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentPublisherPostal /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentQuaternaryFax /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentQuaternaryHomepage /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentQuaternaryLocation /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentQuaternaryName /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentQuaternaryNameEnglish /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentQuaternaryPhone /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentQuaternaryPostal /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentRequires /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentSecondaryFax /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentSecondaryHomepage /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentSecondaryLocation /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentSecondaryName /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentSecondaryNameEnglish /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentSecondaryPhone /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentSecondaryPostal /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentSeries /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentSize /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentShortId /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentTertiaryFax /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentTertiaryHomepage /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentTertiaryLocation /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentTertiaryName /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentTertiaryNameEnglish /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentTertiaryPhone /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentTertiaryPostal /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentURL /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentVersion /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentWorkplaceFax /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentWorkplaceHomepage /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentWorkplaceLocation /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentWorkplaceName /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentWorkplaceNameEnglish /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentWorkplaceOrganization /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentWorkplacePhone /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"syntax match redifArgumentWorkplacePostal /\%(^\S\{-}:\)\@!\S.*/ contained display
|
||||
"
|
||||
" Arguments that may span several lines:
|
||||
syntax region redifArgumentAuthorWorkplaceLocation start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentAuthorWorkplacePostal start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentEditorPostal start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentEditorWorkplacePostal start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentFileFunction start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentIssue start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentJournal start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentOrderPostal start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentPostal start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentPrice start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentPrimaryLocation start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentPrimaryPostal start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentProviderLocation start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentProviderPostal start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentQuaternaryLocation start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentQuaternaryPostal start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentRequires start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentSecondaryLocation start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentSecondaryPostal start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentSize start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentTertiaryLocation start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentTertiaryPostal start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentVersion start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentWorkplaceLocation start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentWorkplacePhone start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentWorkplacePostal start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
|
||||
" Arguments that may not span several lines:
|
||||
" If you are sure that these arguments cannot span several lines, change
|
||||
" them to a match:
|
||||
" /\%(^\S\{-}:\)\@!\S.*/
|
||||
" AND ADD "display" after "contained"
|
||||
" You can use this command on each line that you want to change:
|
||||
" :s+\Vregion \(\w\+\) start=/\\%(^\\S\\{-}:\\)\\@!\\S/ end=/^\\S\\{-}:/me=s-1 contained+match \1 /\\%(^\\S\\{-}:\\)\\@!\\S.*/ contained display
|
||||
syntax region redifArgumentAuthorFax start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentAuthorHomepage start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentAuthorName start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentAuthorNameFirst start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentAuthorNameLast start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentAuthorPerson start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentAuthorPhone start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentAuthorPostal start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentAuthorWorkplaceFax start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentAuthorWorkplaceHomepage start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentAuthorWorkplaceName start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentAuthorWorkplaceNameEnglish start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentAuthorWorkplacePhone start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentEditorFax start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentEditorHomepage start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentEditorName start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentEditorNameFirst start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentEditorNameLast start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentEditorPerson start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentEditorPhone start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentEditorWorkplaceFax start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentEditorWorkplaceHomepage start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentEditorWorkplaceLocation start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentEditorWorkplaceName start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentEditorWorkplaceNameEnglish start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentEditorWorkplacePhone start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentFax start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentFileURL start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentHomepage start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentMaintainerFax start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentMaintainerName start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentMaintainerPhone start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentNameFirst start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentNameFull start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentNameLast start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentNameMiddle start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentNamePrefix start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentNameSuffix start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentName start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentOrderHomepage start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentOrderURL start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentPhone start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentPrimaryFax start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentPrimaryHomepage start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentPrimaryName start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentPrimaryNameEnglish start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentPrimaryPhone start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentProviderFax start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentProviderHomepage start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentProviderName start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentProviderNameEnglish start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentProviderPhone start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentQuaternaryFax start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentQuaternaryHomepage start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentQuaternaryName start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentQuaternaryNameEnglish start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentQuaternaryPhone start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentSecondaryFax start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentSecondaryHomepage start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentSecondaryName start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentSecondaryNameEnglish start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentSecondaryPhone start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentSeries start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentShortId start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentTertiaryFax start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentTertiaryHomepage start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentTertiaryName start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentTertiaryNameEnglish start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentTertiaryPhone start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentURL start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentWorkplaceFax start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentWorkplaceHomepage start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentWorkplaceName start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentWorkplaceNameEnglish start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
syntax region redifArgumentWorkplaceOrganization start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained
|
||||
|
||||
" Special arguments
|
||||
" Those arguments require special values
|
||||
@ -604,12 +629,14 @@ highlight def link redifFieldYear redifField
|
||||
"
|
||||
" Template-Type
|
||||
syntax match redifArgumentTemplateType /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectTemplateType contained display
|
||||
syntax match redifCorrectTemplateType /ReDIF-\%(Paper\|Article\|Chapter\|Book\|Software\|Archive\|Series\|Institution\|Person\)/ nextgroup=redifTemplateVersionNumber contained display
|
||||
syntax match redifTemplateVersionNumber / \d\+\.\d\+/ contained display
|
||||
syntax match redifCorrectTemplateType /ReDIF-\%(Paper\|Article\|Chapter\|Book\|Software\|Archive\|Series\|Institution\|Person\)/ nextgroup=redifTemplateVersionNumberContainer contained display
|
||||
syntax match redifTemplateVersionNumberContainer /.\+/ contains=redifTemplateVersionNumber contained display
|
||||
syntax match redifTemplateVersionNumber / \d\+\.\d\+/ nextgroup=redifWrongLineEnding contained display
|
||||
|
||||
highlight def link redifArgumentTemplateType redifError
|
||||
highlight def link redifCorrectTemplateType Constant
|
||||
highlight def link redifTemplateVersionNumber Number
|
||||
highlight def link redifTemplateVersionNumberContainer redifError
|
||||
|
||||
" Handles:
|
||||
"
|
||||
@ -629,7 +656,7 @@ syntax match redifArgumentBookHandle /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrec
|
||||
syntax match redifArgumentChapterHandle /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfWork contained display
|
||||
syntax match redifArgumentPaperHandle /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfWork contained display
|
||||
syntax match redifArgumentSoftwareHandle /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfWork contained display
|
||||
syntax match redifCorrectHandleOfWork /RePEc:\a\a\a:\%(_\@!\w\)\{6}:\S\+/ contains=redifForbiddenCharactersInHandle,redifBestPracticeInHandle contained display
|
||||
syntax match redifCorrectHandleOfWork /RePEc:\a\a\a:\%(_\@!\w\)\{6}:\S\+/ contains=redifForbiddenCharactersInHandle,redifBestPracticeInHandle nextgroup=redifWrongLineEnding contained display
|
||||
" TODO Are those characters really forbidden???
|
||||
syntax match redifForbiddenCharactersInHandle /[\/*?"<>|]/ contained display
|
||||
syntax match redifBestPracticeInHandle /\<\%([vi]:[1-9]\d*\|y:[1-9]\d\{3}\|p:[1-9]\d*-[1-9]\d*\|i:\%(jan\|feb\|mar\|apr\|may\|jun\|jul\|aug\|sep\|oct\|nov\|dec\|spr\|sum\|aut\|win\|spe\|Q[1-4]\|\d\d-\d\d\)\|Q:[1-4]\)\>/ contained display
|
||||
@ -656,7 +683,7 @@ highlight def link redifBestPracticeInHandle redifSpecial
|
||||
syntax match redifArgumentHandleOfSeries /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfSeries contained display
|
||||
syntax match redifArgumentFollowup /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfSeries contained display
|
||||
syntax match redifArgumentPredecessor /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfSeries contained display
|
||||
syntax match redifCorrectHandleOfSeries /RePEc:\a\a\a:\%(_\@!\w\)\{6}/ contained display
|
||||
syntax match redifCorrectHandleOfSeries /RePEc:\a\a\a:\%(_\@!\w\)\{6}/ nextgroup=redifWrongLineEnding contained display
|
||||
|
||||
highlight def link redifArgumentHandleOfSeries redifError
|
||||
highlight def link redifArgumentFollowup redifError
|
||||
@ -664,13 +691,13 @@ highlight def link redifArgumentPredecessor redifError
|
||||
|
||||
" Handles of Archives:
|
||||
syntax match redifArgumentHandleOfArchive /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfArchive contained display
|
||||
syntax match redifCorrectHandleOfArchive /RePEc:\a\a\a/ contained display
|
||||
syntax match redifCorrectHandleOfArchive /RePEc:\a\a\a/ nextgroup=redifWrongLineEnding contained display
|
||||
|
||||
highlight def link redifArgumentHandleOfArchive redifError
|
||||
|
||||
" Handles of Person:
|
||||
syntax match redifArgumentHandleOfPerson /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfPerson contained display
|
||||
syntax match redifCorrectHandleOfPerson /\%(\%(:\@!\S\)\{-}:\)\{2}[1-9]\d\{3}\%(-02\%(-[12]\d\|-0[1-9]\)\|-\%(0[469]\|11\)\%(-30\|-[12]\d\|-0[1-9]\)\|-\%(0[13578]\|1[02]\)\%(-3[01]\|-[12]\d\|-0[1-9]\)\):\S\+/ contained display
|
||||
syntax match redifCorrectHandleOfPerson /\%(\%(:\@!\S\)\{-}:\)\{2}[1-9]\d\{3}\%(-02\%(-[12]\d\|-0[1-9]\)\|-\%(0[469]\|11\)\%(-30\|-[12]\d\|-0[1-9]\)\|-\%(0[13578]\|1[02]\)\%(-3[01]\|-[12]\d\|-0[1-9]\)\):\S\+/ nextgroup=redifWrongLineEnding contained display
|
||||
|
||||
highlight def link redifArgumentHandleOfPerson redifError
|
||||
|
||||
@ -691,7 +718,7 @@ syntax match redifArgumentTertiaryDefunct /\%(^\S\{-}:\)\@!\S.*/ contains=redifC
|
||||
" TODO Are digits authorized? Apparently not.
|
||||
" Country codes:
|
||||
" http://www.iso.org/iso/country_codes/iso_3166_code_lists/country_names_and_code_elements.htm
|
||||
syntax match redifCorrectHandleOfInstitution /RePEc:\a\a\a:\a\{5}\(ea\|af\|ax\|al\|dz\|as\|ad\|ao\|ai\|aq\|ag\|ar\|am\|aw\|au\|at\|az\|bs\|bh\|bd\|bb\|by\|be\|bz\|bj\|bm\|bt\|bo\|bq\|ba\|bw\|bv\|br\|io\|bn\|bg\|bf\|bi\|kh\|cm\|ca\|cv\|ky\|cf\|td\|cl\|cn\|cx\|cc\|co\|km\|cg\|cd\|ck\|cr\|ci\|hr\|cu\|cw\|cy\|cz\|dk\|dj\|dm\|do\|ec\|eg\|sv\|gq\|er\|ee\|et\|fk\|fo\|fj\|fi\|fr\|gf\|pf\|tf\|ga\|gm\|ge\|de\|gh\|gi\|gr\|gl\|gd\|gp\|gu\|gt\|gg\|gn\|gw\|gy\|ht\|hm\|va\|hn\|hk\|hu\|is\|in\|id\|ir\|iq\|ie\|im\|il\|it\|jm\|jp\|je\|jo\|kz\|ke\|ki\|kp\|kr\|kw\|kg\|la\|lv\|lb\|ls\|lr\|ly\|li\|lt\|lu\|mo\|mk\|mg\|mw\|my\|mv\|ml\|mt\|mh\|mq\|mr\|mu\|yt\|mx\|fm\|md\|mc\|mn\|me\|ms\|ma\|mz\|mm\|na\|nr\|np\|nl\|nc\|nz\|ni\|ne\|ng\|nu\|nf\|mp\|no\|om\|pk\|pw\|ps\|pa\|pg\|py\|pe\|ph\|pn\|pl\|pt\|pr\|qa\|re\|ro\|ru\|rw\|bl\|sh\|kn\|lc\|mf\|pm\|vc\|ws\|sm\|st\|sa\|sn\|rs\|sc\|sl\|sg\|sx\|sk\|si\|sb\|so\|za\|gs\|ss\|es\|lk\|sd\|sr\|sj\|sz\|se\|ch\|sy\|tw\|tj\|tz\|th\|tl\|tg\|tk\|to\|tt\|tn\|tr\|tm\|tc\|tv\|ug\|ua\|ae\|gb\|us\|um\|uy\|uz\|vu\|ve\|vn\|vg\|vi\|wf\|eh\|ye\|zm\|zw\)/ contained display
|
||||
syntax match redifCorrectHandleOfInstitution /RePEc:\a\a\a:\a\{5}\(ea\|af\|ax\|al\|dz\|as\|ad\|ao\|ai\|aq\|ag\|ar\|am\|aw\|au\|at\|az\|bs\|bh\|bd\|bb\|by\|be\|bz\|bj\|bm\|bt\|bo\|bq\|ba\|bw\|bv\|br\|io\|bn\|bg\|bf\|bi\|kh\|cm\|ca\|cv\|ky\|cf\|td\|cl\|cn\|cx\|cc\|co\|km\|cg\|cd\|ck\|cr\|ci\|hr\|cu\|cw\|cy\|cz\|dk\|dj\|dm\|do\|ec\|eg\|sv\|gq\|er\|ee\|et\|fk\|fo\|fj\|fi\|fr\|gf\|pf\|tf\|ga\|gm\|ge\|de\|gh\|gi\|gr\|gl\|gd\|gp\|gu\|gt\|gg\|gn\|gw\|gy\|ht\|hm\|va\|hn\|hk\|hu\|is\|in\|id\|ir\|iq\|ie\|im\|il\|it\|jm\|jp\|je\|jo\|kz\|ke\|ki\|kp\|kr\|kw\|kg\|la\|lv\|lb\|ls\|lr\|ly\|li\|lt\|lu\|mo\|mk\|mg\|mw\|my\|mv\|ml\|mt\|mh\|mq\|mr\|mu\|yt\|mx\|fm\|md\|mc\|mn\|me\|ms\|ma\|mz\|mm\|na\|nr\|np\|nl\|nc\|nz\|ni\|ne\|ng\|nu\|nf\|mp\|no\|om\|pk\|pw\|ps\|pa\|pg\|py\|pe\|ph\|pn\|pl\|pt\|pr\|qa\|re\|ro\|ru\|rw\|bl\|sh\|kn\|lc\|mf\|pm\|vc\|ws\|sm\|st\|sa\|sn\|rs\|sc\|sl\|sg\|sx\|sk\|si\|sb\|so\|za\|gs\|ss\|es\|lk\|sd\|sr\|sj\|sz\|se\|ch\|sy\|tw\|tj\|tz\|th\|tl\|tg\|tk\|to\|tt\|tn\|tr\|tm\|tc\|tv\|ug\|ua\|ae\|gb\|us\|um\|uy\|uz\|vu\|ve\|vn\|vg\|vi\|wf\|eh\|ye\|zm\|zw\)/ nextgroup=redifWrongLineEnding contained display
|
||||
|
||||
highlight def link redifArgumentHandleOfInstitution redifError
|
||||
highlight def link redifArgumentPrimaryDefunct redifError
|
||||
@ -714,7 +741,7 @@ syntax match redifArgumentQuaternaryEmail /\%(^\S\{-}:\)\@!\S.*/ contains=redifC
|
||||
syntax match redifArgumentSecondaryEmail /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectEmail contained display
|
||||
syntax match redifArgumentTertiaryEmail /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectEmail contained display
|
||||
syntax match redifArgumentWorkplaceEmail /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectEmail contained display
|
||||
syntax match redifCorrectEmail /\%(@\@!\S\)\+@\%(@\@!\S\)\+/ contained display
|
||||
syntax match redifCorrectEmail /\%(@\@!\S\)\+@\%(@\@!\S\)\+/ nextgroup=redifWrongLineEnding contained display
|
||||
|
||||
highlight def link redifArgumentAuthorEmail redifError
|
||||
highlight def link redifArgumentAuthorWorkplaceEmail redifError
|
||||
@ -735,7 +762,7 @@ highlight def link redifArgumentWorkplaceEmail redifError
|
||||
" Language
|
||||
" Source: https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes
|
||||
syntax match redifArgumentLanguage /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectLanguage contained display
|
||||
syntax match redifCorrectLanguage /\<\(aa\|ab\|af\|ak\|als\|am\|an\|ang\|ar\|arc\|as\|ast\|av\|ay\|az\|ba\|bar\|bat-smg\|bcl\|be\|be-x-old\|bg\|bh\|bi\|bm\|bn\|bo\|bpy\|br\|bs\|bug\|bxr\|ca\|ce\|ceb\|ch\|cho\|chr\|chy\|co\|cr\|cs\|csb\|cu\|cv\|cy\|da\|de\|diq\|dsb\|dv\|dz\|ee\|el\|en\|eo\|es\|et\|eu\|ext\|fa\|ff\|fi\|fiu-vro\|fj\|fo\|fr\|frp\|fur\|fy\|ga\|gd\|gil\|gl\|gn\|got\|gu\|gv\|ha\|haw\|he\|hi\|ho\|hr\|ht\|hu\|hy\|hz\|ia\|id\|ie\|ig\|ii\|ik\|ilo\|io\|is\|it\|iu\|ja\|jbo\|jv\|ka\|kg\|ki\|kj\|kk\|kl\|km\|kn\|khw\|ko\|kr\|ks\|ksh\|ku\|kv\|kw\|ky\|la\|lad\|lan\|lb\|lg\|li\|lij\|lmo\|ln\|lo\|lt\|lv\|map-bms\|mg\|mh\|mi\|mk\|ml\|mn\|mo\|mr\|ms\|mt\|mus\|my\|na\|nah\|nap\|nd\|nds\|nds-nl\|ne\|new\|ng\|nl\|nn\|no\|nr\|nso\|nrm\|nv\|ny\|oc\|oj\|om\|or\|os\|pa\|pag\|pam\|pap\|pdc\|pi\|pih\|pl\|pms\|ps\|pt\|qu\|rm\|rmy\|rn\|ro\|roa-rup\|ru\|rw\|sa\|sc\|scn\|sco\|sd\|se\|sg\|sh\|si\|simple\|sk\|sl\|sm\|sn\|so\|sq\|sr\|ss\|st\|su\|sv\|sw\|ta\|te\|tet\|tg\|th\|ti\|tk\|tl\|tlh\|tn\|to\|tpi\|tr\|ts\|tt\|tum\|tw\|ty\|udm\|ug\|uk\|ur\|uz\|ve\|vi\|vec\|vls\|vo\|wa\|war\|wo\|xal\|xh\|yi\|yo\|za\|zh\|zh-min-nan\|zh-yue\|zu\)\>/ contained display
|
||||
syntax match redifCorrectLanguage /\<\(aa\|ab\|af\|ak\|als\|am\|an\|ang\|ar\|arc\|as\|ast\|av\|ay\|az\|ba\|bar\|bat-smg\|bcl\|be\|be-x-old\|bg\|bh\|bi\|bm\|bn\|bo\|bpy\|br\|bs\|bug\|bxr\|ca\|ce\|ceb\|ch\|cho\|chr\|chy\|co\|cr\|cs\|csb\|cu\|cv\|cy\|da\|de\|diq\|dsb\|dv\|dz\|ee\|el\|en\|eo\|es\|et\|eu\|ext\|fa\|ff\|fi\|fiu-vro\|fj\|fo\|fr\|frp\|fur\|fy\|ga\|gd\|gil\|gl\|gn\|got\|gu\|gv\|ha\|haw\|he\|hi\|ho\|hr\|ht\|hu\|hy\|hz\|ia\|id\|ie\|ig\|ii\|ik\|ilo\|io\|is\|it\|iu\|ja\|jbo\|jv\|ka\|kg\|ki\|kj\|kk\|kl\|km\|kn\|khw\|ko\|kr\|ks\|ksh\|ku\|kv\|kw\|ky\|la\|lad\|lan\|lb\|lg\|li\|lij\|lmo\|ln\|lo\|lt\|lv\|map-bms\|mg\|mh\|mi\|mk\|ml\|mn\|mo\|mr\|ms\|mt\|mus\|my\|na\|nah\|nap\|nd\|nds\|nds-nl\|ne\|new\|ng\|nl\|nn\|no\|nr\|nso\|nrm\|nv\|ny\|oc\|oj\|om\|or\|os\|pa\|pag\|pam\|pap\|pdc\|pi\|pih\|pl\|pms\|ps\|pt\|qu\|rm\|rmy\|rn\|ro\|roa-rup\|ru\|rw\|sa\|sc\|scn\|sco\|sd\|se\|sg\|sh\|si\|simple\|sk\|sl\|sm\|sn\|so\|sq\|sr\|ss\|st\|su\|sv\|sw\|ta\|te\|tet\|tg\|th\|ti\|tk\|tl\|tlh\|tn\|to\|tpi\|tr\|ts\|tt\|tum\|tw\|ty\|udm\|ug\|uk\|ur\|uz\|ve\|vi\|vec\|vls\|vo\|wa\|war\|wo\|xal\|xh\|yi\|yo\|za\|zh\|zh-min-nan\|zh-yue\|zu\)\>/ nextgroup=redifWrongLineEnding contained display
|
||||
|
||||
highlight def link redifArgumentLanguage redifError
|
||||
highlight def link redifCorrectLanguage redifSpecial
|
||||
@ -743,22 +770,22 @@ highlight def link redifCorrectLanguage redifSpecial
|
||||
" Length
|
||||
" Based on the example in the documentation. But apparently any field is
|
||||
" possible
|
||||
syntax match redifArgumentLength /\%(^\S\{-}:\)\@!\S.*/ contains=redifGoodLength contained display
|
||||
syntax region redifArgumentLength start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contains=redifGoodLength contained
|
||||
syntax match redifGoodLength /1 page\|[1-9]\d*\%( pages\)\=/ contained display
|
||||
|
||||
highlight def link redifGoodLength redifSpecial
|
||||
|
||||
" Publication-Type
|
||||
syntax match redifArgumentPublicationType /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectPublicationType contained display
|
||||
syntax match redifCorrectPublicationType /\<\(journal article\|book\|book chapter\|working paper\|conference paper\|report\|other\)\>/ contained display
|
||||
syntax match redifCorrectPublicationType /\<\(journal article\|book\|book chapter\|working paper\|conference paper\|report\|other\)\>/ nextgroup=redifWrongLineEnding contained display
|
||||
|
||||
highlight def link redifArgumentPublicationType redifError
|
||||
highlight def link redifCorrectPublicationType redifSpecial
|
||||
|
||||
" Publication-Status
|
||||
syntax match redifArgumentPublicationStatus /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectPublicationStatus contained display
|
||||
syntax match redifCorrectPublicationStatus /\<\%(published\|forthcoming\)\>.*/ contains=redifSpecialPublicationStatus contained display
|
||||
syntax match redifSpecialPublicationStatus /published\|forthcoming/ contained display
|
||||
syntax region redifArgumentPublicationStatus start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contains=redifSpecialPublicationStatus contained
|
||||
syntax match redifSpecialPublicationStatus /published\|forthcoming/ nextgroup=redifCorrectPublicationStatus contained display
|
||||
syntax region redifCorrectPublicationStatus start=/./ end=/^\S\{-}:/me=s-1 contained
|
||||
|
||||
highlight def link redifArgumentPublicationStatus redifError
|
||||
highlight def link redifSpecialPublicationStatus redifSpecial
|
||||
@ -766,7 +793,7 @@ highlight def link redifSpecialPublicationStatus redifSpecial
|
||||
" Month
|
||||
" TODO Are numbers also allowed?
|
||||
syntax match redifArgumentMonth /\%(^\S\{-}:\)\@!\S.*/ contains=redifGoodMonth contained display
|
||||
syntax match redifGoodMonth /\<\(Jan\%(uary\)\=\|Feb\%(ruary\)\=\|Mar\%(ch\)\=\|Apr\%(il\)\=\|May\|June\=\|July\=\|Aug\%(ust\)\=\|Sep\%(tember\)\=\|Oct\%(ober\)\=\|Nov\%(ember\)\=\|Dec\%(ember\)\=\)\>/ contained display
|
||||
syntax match redifGoodMonth /\<\(Jan\%(uary\)\=\|Feb\%(ruary\)\=\|Mar\%(ch\)\=\|Apr\%(il\)\=\|May\|June\=\|July\=\|Aug\%(ust\)\=\|Sep\%(tember\)\=\|Oct\%(ober\)\=\|Nov\%(ember\)\=\|Dec\%(ember\)\=\)\>/ nextgroup=redifWrongLineEnding contained display
|
||||
|
||||
highlight def link redifGoodMonth redifSpecial
|
||||
|
||||
@ -774,46 +801,46 @@ highlight def link redifGoodMonth redifSpecial
|
||||
syntax match redifArgumentNumber /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectInteger contained display
|
||||
syntax match redifArgumentVolume /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectInteger contained display
|
||||
syntax match redifArgumentChapter /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectInteger contained display
|
||||
syntax match redifCorrectInteger /[1-9]\d*/ contained display
|
||||
syntax match redifCorrectInteger /[1-9]\d*/ nextgroup=redifWrongLineEnding contained display
|
||||
|
||||
highlight def link redifArgumentVolume redifError
|
||||
highlight def link redifArgumentChapter redifError
|
||||
|
||||
" Year
|
||||
syntax match redifArgumentYear /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectYear contained display
|
||||
syntax match redifCorrectYear /[1-9]\d\{3}/ contained display
|
||||
syntax match redifCorrectYear /[1-9]\d\{3}/ nextgroup=redifWrongLineEnding contained display
|
||||
|
||||
highlight def link redifArgumentYear redifError
|
||||
|
||||
" Edition
|
||||
" Based on the example in the documentation.
|
||||
syntax match redifArgumentEdition /\%(^\S\{-}:\)\@!\S.*/ contains=redifGoodEdition contained display
|
||||
syntax match redifGoodEdition /1st\|2nd\|3rd\|[4-9]th\|[1-9]\d*\%(1st\|2nd\|3rd\|[4-9]th\)\|[1-9]\d*/ contained display
|
||||
syntax match redifGoodEdition /1st\|2nd\|3rd\|[4-9]th\|[1-9]\d*\%(1st\|2nd\|3rd\|[4-9]th\)\|[1-9]\d*/ nextgroup=redifWrongLineEnding contained display
|
||||
|
||||
highlight def link redifGoodEdition redifSpecial
|
||||
|
||||
" ISBN
|
||||
syntax match redifArgumentISBN /\%(^\S\{-}:\)\@!\S.*/ contains=redifGoodISBN contained display
|
||||
syntax match redifGoodISBN /\d[0-9-]\{8,15}\d/ contained display
|
||||
syntax match redifGoodISBN /\d[0-9-]\{8,15}\d/ nextgroup=redifWrongLineEnding contained display
|
||||
|
||||
highlight def link redifGoodISBN redifSpecial
|
||||
|
||||
" ISSN
|
||||
syntax match redifArgumentISSN /\%(^\S\{-}:\)\@!\S.*/ contains=redifGoodISSN contained display
|
||||
syntax match redifGoodISSN /\d\{4}-\d\{3}[0-9X]/ contained display
|
||||
syntax match redifGoodISSN /\d\{4}-\d\{3}[0-9X]/ nextgroup=redifWrongLineEnding contained display
|
||||
|
||||
highlight def link redifGoodISSN redifSpecial
|
||||
|
||||
" File-Size
|
||||
" Based on the example in the documentation.
|
||||
syntax match redifArgumentFileSize /\%(^\S\{-}:\)\@!\S.*/ contains=redifGoodSize contained display
|
||||
syntax region redifArgumentFileSize start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contains=redifGoodSize contained
|
||||
syntax match redifGoodSize /kb\|bytes/ contained display
|
||||
|
||||
highlight def link redifGoodSize redifSpecial
|
||||
|
||||
" Type
|
||||
syntax match redifArgumentType /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectType contained display
|
||||
syntax match redifCorrectType /ReDIF-Paper\|ReDIF-Software\|ReDIF-Article\|ReDIF-Chapter\|ReDIF-Book/ contained display
|
||||
syntax match redifCorrectType /ReDIF-Paper\|ReDIF-Software\|ReDIF-Article\|ReDIF-Chapter\|ReDIF-Book/ nextgroup=redifWrongLineEnding contained display
|
||||
|
||||
highlight def link redifArgumentType redifError
|
||||
highlight def link redifCorrectType redifSpecial
|
||||
@ -825,7 +852,7 @@ syntax match redifArgumentLastLoginDate /\%(^\S\{-}:\)\@!\S.*/ contains=redifCor
|
||||
syntax match redifArgumentPublicationDate /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectDate contained display
|
||||
syntax match redifArgumentRegisteredDate /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectDate contained display
|
||||
syntax match redifArgumentRevisionDate /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectDate contained display
|
||||
syntax match redifCorrectDate /[1-9]\d\{3}\%(-02\%(-[12]\d\|-0[1-9]\)\=\|-\%(0[469]\|11\)\%(-30\|-[12]\d\|-0[1-9]\)\=\|-\%(0[13578]\|1[02]\)\%(-3[01]\|-[12]\d\|-0[1-9]\)\=\)\=/ contained display
|
||||
syntax match redifCorrectDate /[1-9]\d\{3}\%(-02\%(-[12]\d\|-0[1-9]\)\=\|-\%(0[469]\|11\)\%(-30\|-[12]\d\|-0[1-9]\)\=\|-\%(0[13578]\|1[02]\)\%(-3[01]\|-[12]\d\|-0[1-9]\)\=\)\=/ nextgroup=redifWrongLineEnding contained display
|
||||
|
||||
highlight def link redifArgumentCreationDate redifError
|
||||
highlight def link redifArgumentLastLoginDate redifError
|
||||
@ -835,7 +862,7 @@ highlight def link redifArgumentRevisionDate redifError
|
||||
|
||||
" Classification-JEL
|
||||
syntax match redifArgumentClassificationJEL /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectJEL contained display
|
||||
syntax match redifCorrectJEL /\<\u\d\{,2}\%([,; \t]\s*\)\=/ contains=redifSpecialJEL contained display
|
||||
syntax match redifCorrectJEL /\<\u\d\{,2}\%([,; \t]\s*\)\=/ contains=redifSpecialJEL nextgroup=redifWrongLineEnding contained display
|
||||
syntax match redifSpecialJEL /\<\u\d\{,2}/ contained display
|
||||
|
||||
highlight def link redifArgumentClassificationJEL redifError
|
||||
@ -843,7 +870,7 @@ highlight def link redifSpecialJEL redifSpecial
|
||||
|
||||
" Pages
|
||||
syntax match redifArgumentPages /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectPages contained display
|
||||
syntax match redifCorrectPages /[1-9]\d*-[1-9]\d*/ contained display
|
||||
syntax match redifCorrectPages /[1-9]\d*-[1-9]\d*/ nextgroup=redifWrongLineEnding contained display
|
||||
|
||||
highlight def link redifArgumentPages redifError
|
||||
|
||||
@ -855,7 +882,7 @@ highlight def link redifArgumentNameASCII redifError
|
||||
|
||||
" Programming-Language
|
||||
syntax match redifArgumentProgrammingLanguage /\%(^\S\{-}:\)\@!\S.*/ contains=redifGoodProgrammingLanguage contained display
|
||||
syntax match redifGoodProgrammingLanguage /\<c++\|\<\%(c\|dos executable\|executable\|fortran\|gauss\|gretl\|java\|mathematica\|matlab\|octave\|ox\|perl\|python\|rats\|r\|shazam\|s-plus\|stata\|tsp international\)\>/ contained display
|
||||
syntax match redifGoodProgrammingLanguage /\<c++\|\<\%(c\|dos executable\|executable\|fortran\|gauss\|gretl\|java\|mathematica\|matlab\|octave\|ox\|perl\|python\|rats\|r\|shazam\|s-plus\|stata\|tsp international\)\>/ nextgroup=redifWrongLineEnding contained display
|
||||
|
||||
highlight def link redifGoodProgrammingLanguage redifSpecial
|
||||
|
||||
@ -864,29 +891,82 @@ highlight def link redifGoodProgrammingLanguage redifSpecial
|
||||
" ftp://ftp.isi.edu/in-notes/iana/assignments/media-types/media-types
|
||||
" These are based on the examples in the documentation.
|
||||
syntax match redifArgumentFileFormat /\%(^\S\{-}:\)\@!\S.*/ contains=redifGoodFormat contained display
|
||||
syntax match redifGoodFormat /application\/pdf\|application\/postscript\|text\/html\|text\/plain/ contained display
|
||||
syntax match redifGoodFormat "\a\+/[[:alpha:]+-]\+" nextgroup=redifWrongLineEnding contains=redifSpecialFormat contained display
|
||||
syntax match redifSpecialFormat "application/atom+xml\|application/ecmascript\|application/EDI-X12\|application/EDIFACT\|application/json\|application/javascript\|application/octet-stream\|application/ogg\|application/pdf\|application/postscript\|application/rdf+xml\|application/rss+xml\|application/soap+xml\|application/font-woff\|application/xhtml+xml\|application/xml\|application/xml-dtd\|application/xop+xml\|application/zip\|application/gzip\|audio/basic\|audio/L24\|audio/mp4\|audio/mpeg\|audio/ogg\|audio/vorbis\|audio/vnd.rn-realaudio\|audio/vnd.wave\|audio/webm\|image/gif\|image/jpeg\|image/pjpeg\|image/png\|image/svg+xml\|image/tiff\|image/vnd.microsoft.icon\|message/http\|message/imdn+xml\|message/partial\|message/rfc822\|model/example\|model/iges\|model/mesh\|model/vrml\|model/x3d+binary\|model/x3d+vrml\|model/x3d+xml\|multipart/mixed\|multipart/alternative\|multipart/related\|multipart/form-data\|multipart/signed\|multipart/encrypted\|text/cmd\|text/css\|text/csv\|text/html\|text/javascript\|text/plain\|text/vcard\|text/xml\|video/mpeg\|video/mp4\|video/ogg\|video/quicktime\|video/webm\|video/x-matroska\|video/x-ms-wmv\|video/x-flv" contained display
|
||||
|
||||
highlight def link redifGoodFormat redifSpecial
|
||||
highlight def link redifSpecialFormat redifSpecial
|
||||
highlight def link redifArgumentFileFormat redifError
|
||||
|
||||
" Spell-checked arguments
|
||||
" Keywords
|
||||
" Spell checked
|
||||
syntax match redifArgumentKeywords /\%(^\S\{-}:\)\@!\S.*/ contains=@Spell,redifKeywordsSemicolon contained
|
||||
syntax match redifKeywordsSemicolon /;/ contained
|
||||
|
||||
highlight def link redifKeywordsSemicolon redifSpecial
|
||||
|
||||
" Other spell-checked arguments
|
||||
" Very useful when copy-pasting abstracts that may contain hyphens or
|
||||
" ligatures.
|
||||
syntax region redifArgumentAbstract start=/\%(^\S\{-}:\)\@!\S.*/ end=/^\S\{-}:/me=s-1 contains=@Spell contained
|
||||
syntax region redifArgumentAvailability start=/\%(^\S\{-}:\)\@!\S.*/ end=/^\S\{-}:/me=s-1 contains=@Spell contained
|
||||
syntax region redifArgumentBookTitle start=/\%(^\S\{-}:\)\@!\S.*/ end=/^\S\{-}:/me=s-1 contains=@Spell contained
|
||||
syntax region redifArgumentDescription start=/\%(^\S\{-}:\)\@!\S.*/ end=/^\S\{-}:/me=s-1 contains=@Spell contained
|
||||
syntax region redifArgumentFileRestriction start=/\%(^\S\{-}:\)\@!\S.*/ end=/^\S\{-}:/me=s-1 contains=@Spell contained
|
||||
syntax region redifArgumentKeywords start=/\%(^\S\{-}:\)\@!\S.*/ end=/^\S\{-}:/me=s-1 contains=@Spell contained
|
||||
syntax region redifArgumentNote start=/\%(^\S\{-}:\)\@!\S.*/ end=/^\S\{-}:/me=s-1 contains=@Spell contained
|
||||
syntax region redifArgumentNotification start=/\%(^\S\{-}:\)\@!\S.*/ end=/^\S\{-}:/me=s-1 contains=@Spell contained
|
||||
syntax region redifArgumentRestriction start=/\%(^\S\{-}:\)\@!\S.*/ end=/^\S\{-}:/me=s-1 contains=@Spell contained
|
||||
syntax region redifArgumentTitle start=/\%(^\S\{-}:\)\@!\S.*/ end=/^\S\{-}:/me=s-1 contains=@Spell contained
|
||||
syntax region redifArgumentAbstract start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contains=@Spell contained
|
||||
syntax region redifArgumentAvailability start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contains=@Spell contained
|
||||
syntax region redifArgumentBookTitle start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contains=@Spell contained
|
||||
syntax region redifArgumentDescription start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contains=@Spell contained
|
||||
syntax region redifArgumentFileRestriction start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contains=@Spell contained
|
||||
syntax region redifArgumentNote start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contains=@Spell contained
|
||||
syntax region redifArgumentNotification start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contains=@Spell contained
|
||||
syntax region redifArgumentRestriction start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contains=@Spell contained
|
||||
syntax region redifArgumentTitle start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contains=@Spell contained
|
||||
|
||||
" Wrong line ending
|
||||
syntax match redifWrongLineEnding /.\+/ contained display
|
||||
|
||||
highlight def link redifWrongLineEnding redifError
|
||||
|
||||
" Final highlight
|
||||
highlight def link redifComment Comment
|
||||
highlight def link redifError Error
|
||||
highlight def link redifField Identifier
|
||||
highlight def link redifFieldDeprecated Identifier
|
||||
highlight def link redifSpecial Special
|
||||
" For deprecated fields:
|
||||
highlight redifFieldDeprecated term=undercurl cterm=undercurl gui=undercurl guisp=DarkGrey
|
||||
|
||||
" Sync: The template-type (ReDIF-Paper, ReDIF-Archive, etc.) influences which
|
||||
" fields can follow. Thus sync must search backwards for it.
|
||||
"
|
||||
" I would like to simply ask VIM to search backward for the first occurence of
|
||||
" /^Template-Type:/, but it does not seem to be possible, so I have to start
|
||||
" from the beginning of the file... This might slow down a lot for files that
|
||||
" contain a lot of Template-Type statements.
|
||||
syntax sync fromstart
|
||||
|
||||
" The problem with syntax sync match (tried below), it is that, for example,
|
||||
" it cannot realize when it is inside a Author-Name cluster, which is inside a
|
||||
" Template-Type template...
|
||||
"
|
||||
" TODO Is this linecont pattern really useful? It seems to work anyway...
|
||||
"syntax sync linecont /^\(Template-Type:\)\=\s*$/
|
||||
" TODO This sync is surprising... It seems to work on several lines even
|
||||
" though I replaced \_s* by \s*, even without the linecont pattern...
|
||||
"syntax sync match redifSyncForTemplatePaper groupthere redifRegionTemplatePaper /^Template-Type:\s*ReDIF-Paper \d\+\.\d\+/
|
||||
"syntax sync match redifSyncForTemplateArticle groupthere redifRegionTemplateArticle /^Template-Type:\s*ReDIF-Article \d\+\.\d\+/
|
||||
"syntax sync match redifSyncForTemplateChapter groupthere redifRegionTemplateChapter /^Template-Type:\s*ReDIF-Chapter \d\+\.\d\+/
|
||||
"syntax sync match redifSyncForTemplateBook groupthere redifRegionTemplateBook /^Template-Type:\s*ReDIF-Book \d\+\.\d\+/
|
||||
"syntax sync match redifSyncForTemplateSoftware groupthere redifRegionTemplateSoftware /^Template-Type:\s*ReDIF-Software \d\+\.\d\+/
|
||||
"syntax sync match redifSyncForTemplateArchive groupthere redifRegionTemplateArchive /^Template-Type:\s*ReDIF-Archive \d\+\.\d\+/
|
||||
"syntax sync match redifSyncForTemplateSeries groupthere redifRegionTemplateSeries /^Template-Type:\s*ReDIF-Series \d\+\.\d\+/
|
||||
"syntax sync match redifSyncForTemplateInstitution groupthere redifRegionTemplateInstitution /^Template-Type:\s*ReDIF-Institution \d\+\.\d\+/
|
||||
"syntax sync match redifSyncForTemplatePerson groupthere redifRegionTemplatePerson /^Template-Type:\s*ReDIF-Person \d\+\.\d\+/
|
||||
|
||||
" I do not really know how sync linebreaks works, but it helps when making
|
||||
" changes on the argument when this argument is not on the same line than its
|
||||
" field. I just assume that people won't leave more than one line of
|
||||
" whitespace between fields and arguments (which is already very unlikely)
|
||||
" hence the value of 2.
|
||||
syntax sync linebreaks=2
|
||||
|
||||
" Since folding is defined by the syntax, set foldmethod to syntax.
|
||||
set foldmethod=syntax
|
||||
|
||||
" Set "b:current_syntax" to the name of the syntax at the end:
|
||||
let b:current_syntax="redif"
|
||||
|
Loading…
x
Reference in New Issue
Block a user