Mercurial > vim
annotate runtime/syntax/gedcom.vim @ 14893:291656f731c9 v8.1.0458
patch 8.1.0458: ml_get error and crash when using "do"
commit https://github.com/vim/vim/commit/df77cef92ec034796723ffa3adb12e8b46daa98e
Author: Bram Moolenaar <Bram@vim.org>
Date: Sun Oct 7 17:46:42 2018 +0200
patch 8.1.0458: ml_get error and crash when using "do"
Problem: Ml_get error and crash when using "do".
Solution: Adjust cursor position also when diffupdate is not needed.
(Hirohito Higashi)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Sun, 07 Oct 2018 18:00:05 +0200 |
parents | 46763b01cd9a |
children |
rev | line source |
---|---|
7 | 1 " Vim syntax file |
2 " Language: Gedcom | |
3 " Maintainer: Paul Johnson (pjcj@transeda.com) | |
4 " Version 1.059 - 23rd December 1999 | |
5 | |
10048
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
7
diff
changeset
|
6 " quit when a syntax file was already loaded |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
7
diff
changeset
|
7 if exists("b:current_syntax") |
7 | 8 finish |
9 endif | |
10 | |
11 syntax case match | |
12 | |
13 syntax keyword gedcom_record ABBR ADDR ADOP ADR1 ADR2 AFN AGE AGNC ALIA ANCE | |
14 syntax keyword gedcom_record ANCI ANUL ASSO AUTH BAPL BAPM BARM BASM BIRT BLES | |
15 syntax keyword gedcom_record BLOB BURI CALN CAST CAUS CENS CHAN CHAR CHIL CHR | |
16 syntax keyword gedcom_record CHRA CITY CONC CONF CONL CONT COPR CORP CREM CTRY | |
17 syntax keyword gedcom_record DATA DEAT DESC DESI DEST DIV DIVF DSCR EDUC EMIG | |
18 syntax keyword gedcom_record ENDL ENGA EVEN FAM FAMC FAMF FAMS FCOM FILE FORM | |
19 syntax keyword gedcom_record GEDC GIVN GRAD HEAD HUSB IDNO IMMI INDI LANG MARB | |
20 syntax keyword gedcom_record MARC MARL MARR MARS MEDI NATI NATU NCHI NICK NMR | |
21 syntax keyword gedcom_record NOTE NPFX NSFX OBJE OCCU ORDI ORDN PAGE PEDI PHON | |
22 syntax keyword gedcom_record PLAC POST PROB PROP PUBL QUAY REFN RELA RELI REPO | |
23 syntax keyword gedcom_record RESI RESN RETI RFN RIN ROLE SEX SLGC SLGS SOUR | |
24 syntax keyword gedcom_record SPFX SSN STAE STAT SUBM SUBN SURN TEMP TEXT TIME | |
25 syntax keyword gedcom_record TITL TRLR TYPE VERS WIFE WILL | |
26 syntax keyword gedcom_record DATE nextgroup=gedcom_date | |
27 syntax keyword gedcom_record NAME nextgroup=gedcom_name | |
28 | |
29 syntax case ignore | |
30 | |
31 syntax region gedcom_id start="@" end="@" oneline contains=gedcom_ii, gedcom_in | |
32 syntax match gedcom_ii "\I\+" contained nextgroup=gedcom_in | |
33 syntax match gedcom_in "\d\+" contained | |
34 syntax region gedcom_name start="" end="$" skipwhite oneline contains=gedcom_cname, gedcom_surname contained | |
35 syntax match gedcom_cname "\i\+" contained | |
36 syntax match gedcom_surname "/\(\i\|\s\)*/" contained | |
37 syntax match gedcom_date "\d\{1,2}\s\+\(jan\|feb\|mar\|apr\|may\|jun\|jul\|aug\|sep\|oct\|nov\|dec\)\s\+\d\+" | |
38 syntax match gedcom_date ".*" contained | |
39 | |
40 " Define the default highlighting. | |
10048
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
7
diff
changeset
|
41 " Only when an item doesn't have highlighting yet |
7 | 42 |
10051
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
43 hi def link gedcom_record Statement |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
44 hi def link gedcom_id Comment |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
45 hi def link gedcom_ii PreProc |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
46 hi def link gedcom_in Type |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
47 hi def link gedcom_name PreProc |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
48 hi def link gedcom_cname Type |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
49 hi def link gedcom_surname Identifier |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
50 hi def link gedcom_date Constant |
7 | 51 |
52 | |
53 let b:current_syntax = "gedcom" |