annotate runtime/syntax/bst.vim @ 27936:07aea9530e05 v8.2.4493

patch 8.2.4493: options test fails in the GUI Commit: https://github.com/vim/vim/commit/b9c510859360595c046b8b7c1d6828125525e967 Author: Bram Moolenaar <Bram@vim.org> Date: Wed Mar 2 20:12:03 2022 +0000 patch 8.2.4493: options test fails in the GUI Problem: Options test fails in the GUI. Solution: Do not save and restore 'term'.
author Bram Moolenaar <Bram@vim.org>
date Wed, 02 Mar 2022 21:15:03 +0100
parents 46763b01cd9a
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
846
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
1 " Vim syntax file
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
2 " Language: BibTeX Bibliography Style
1125
96cd8222a819 updated for version 7.1a
vimboss
parents: 846
diff changeset
3 " Maintainer: Tim Pope <vimNOSPAM@tpope.info>
846
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
4 " Filenames: *.bst
2034
7bc41231fbc7 Update runtime files.
Bram Moolenaar <bram@zimbu.org>
parents: 1125
diff changeset
5 " $Id: bst.vim,v 1.2 2007/05/05 18:24:42 vimboss Exp $
846
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
6
10048
43efa4f5a8ea commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents: 2034
diff changeset
7 " quit when a syntax file was already loaded
43efa4f5a8ea commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents: 2034
diff changeset
8 if exists("b:current_syntax")
846
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
9 finish
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
10 endif
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
11
10048
43efa4f5a8ea commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents: 2034
diff changeset
12 setlocal iskeyword=48-57,#,$,',.,A-Z,a-z
846
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
13
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
14 syn case ignore
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
15
1125
96cd8222a819 updated for version 7.1a
vimboss
parents: 846
diff changeset
16 syn match bstString +"[^"]*\%("\|$\)+ contains=bstField,bstType,bstError
96cd8222a819 updated for version 7.1a
vimboss
parents: 846
diff changeset
17 " Highlight the last character of an unclosed string, but only when the cursor
96cd8222a819 updated for version 7.1a
vimboss
parents: 846
diff changeset
18 " is not beyond it (i.e., it is still being edited). Imperfect.
96cd8222a819 updated for version 7.1a
vimboss
parents: 846
diff changeset
19 syn match bstError '[^"]\%#\@!$' contained
96cd8222a819 updated for version 7.1a
vimboss
parents: 846
diff changeset
20
846
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
21 syn match bstNumber "#-\=\d\+\>"
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
22 syn keyword bstNumber entry.max$ global.max$
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
23 syn match bstComment "%.*"
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
24
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
25 syn keyword bstCommand ENTRY FUNCTION INTEGERS MACRO STRINGS
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
26 syn keyword bstCommand READ EXECUTE ITERATE REVERSE SORT
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
27 syn match bstBuiltIn "\s[-<>=+*]\|\s:="
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
28 syn keyword bstBuiltIn add.period$
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
29 syn keyword bstBuiltIn call.type$ change.case$ chr.to.int$ cite$
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
30 syn keyword bstBuiltIn duplicate$ empty$ format.name$
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
31 syn keyword bstBuiltIn if$ int.to.chr$ int.to.str$
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
32 syn keyword bstBuiltIn missing$
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
33 syn keyword bstBuiltIn newline$ num.names$
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
34 syn keyword bstBuiltIn pop$ preamble$ purify$ quote$
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
35 syn keyword bstBuiltIn skip$ stack$ substring$ swap$
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
36 syn keyword bstBuiltIn text.length$ text.prefix$ top$ type$
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
37 syn keyword bstBuiltIn warning$ while$ width$ write$
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
38 syn match bstIdentifier "'\k*"
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
39 syn keyword bstType article book booklet conference
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
40 syn keyword bstType inbook incollection inproceedings
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
41 syn keyword bstType manual mastersthesis misc
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
42 syn keyword bstType phdthesis proceedings
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
43 syn keyword bstType techreport unpublished
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
44 syn keyword bstField abbr address annote author
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
45 syn keyword bstField booktitle chapter crossref comment
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
46 syn keyword bstField edition editor
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
47 syn keyword bstField howpublished institution journal key month
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
48 syn keyword bstField note number
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
49 syn keyword bstField organization
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
50 syn keyword bstField pages publisher
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
51 syn keyword bstField school series
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
52 syn keyword bstField title type
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
53 syn keyword bstField volume year
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
54
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
55 " Define the default highlighting.
10048
43efa4f5a8ea commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents: 2034
diff changeset
56 " Only when an item doesn't have highlighting yet
846
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
57
10051
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
58 hi def link bstComment Comment
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
59 hi def link bstString String
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
60 hi def link bstCommand PreProc
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
61 hi def link bstBuiltIn Statement
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
62 hi def link bstField Special
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
63 hi def link bstNumber Number
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
64 hi def link bstType Type
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
65 hi def link bstIdentifier Identifier
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
66 hi def link bstError Error
846
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
67
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
68 let b:current_syntax = "bst"
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
69
db44f7b81373 updated for version 7.0f03
vimboss
parents:
diff changeset
70 " vim:set ft=vim sts=4 sw=4: