Mercurial > vim
annotate runtime/syntax/rcs.vim @ 28739:40b087823dc7 v8.2.4894
patch 8.2.4894: MS-Windows: not using italics
Commit: https://github.com/vim/vim/commit/5a7b6dc23cd16450b5773849520d513de56bccbf
Author: LemonBoy <thatlemon@gmail.com>
Date: Fri May 6 18:38:41 2022 +0100
patch 8.2.4894: MS-Windows: not using italics
Problem: MS-Windows: not using italics.
Solution: Use italics. Simplify the code. (closes https://github.com/vim/vim/issues/10359)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Fri, 06 May 2022 19:45:02 +0200 |
parents | 46763b01cd9a |
children |
rev | line source |
---|---|
7 | 1 " Vim syntax file |
810 | 2 " Language: RCS file |
3356 | 3 " Maintainer: Dmitry Vasiliev <dima at hlabs dot org> |
4 " URL: https://github.com/hdima/vim-scripts/blob/master/syntax/rcs.vim | |
5 " Last Change: 2012-02-11 | |
810 | 6 " Filenames: *,v |
3356 | 7 " Version: 1.12 |
810 | 8 |
7 | 9 " Options: |
810 | 10 " rcs_folding = 1 For folding strings |
7 | 11 |
10048
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
3356
diff
changeset
|
12 " quit when a syntax file was already loaded. |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
3356
diff
changeset
|
13 if exists("b:current_syntax") |
7 | 14 finish |
15 endif | |
16 | |
17 " RCS file must end with a newline. | |
810 | 18 syn match rcsEOFError ".\%$" containedin=ALL |
7 | 19 |
20 " Keywords. | |
810 | 21 syn keyword rcsKeyword head branch access symbols locks strict |
22 syn keyword rcsKeyword comment expand date author state branches | |
23 syn keyword rcsKeyword next desc log | |
24 syn keyword rcsKeyword text nextgroup=rcsTextStr skipwhite skipempty | |
7 | 25 |
26 " Revision numbers and dates. | |
810 | 27 syn match rcsNumber "\<[0-9.]\+\>" display |
7 | 28 |
29 " Strings. | |
30 if exists("rcs_folding") && has("folding") | |
31 " Folded strings. | |
810 | 32 syn region rcsString matchgroup=rcsString start="@" end="@" skip="@@" fold contains=rcsSpecial |
33 syn region rcsTextStr matchgroup=rcsTextStr start="@" end="@" skip="@@" fold contained contains=rcsSpecial,rcsDiffLines | |
7 | 34 else |
810 | 35 syn region rcsString matchgroup=rcsString start="@" end="@" skip="@@" contains=rcsSpecial |
36 syn region rcsTextStr matchgroup=rcsTextStr start="@" end="@" skip="@@" contained contains=rcsSpecial,rcsDiffLines | |
7 | 37 endif |
810 | 38 syn match rcsSpecial "@@" contained |
39 syn match rcsDiffLines "[da]\d\+ \d\+$" contained | |
7 | 40 |
41 " Synchronization. | |
42 syn sync clear | |
43 if exists("rcs_folding") && has("folding") | |
44 syn sync fromstart | |
45 else | |
46 " We have incorrect folding if following sync patterns is turned on. | |
810 | 47 syn sync match rcsSync grouphere rcsString "[0-9.]\+\(\s\|\n\)\+log\(\s\|\n\)\+@"me=e-1 |
48 syn sync match rcsSync grouphere rcsTextStr "@\(\s\|\n\)\+text\(\s\|\n\)\+@"me=e-1 | |
7 | 49 endif |
50 | |
51 " Define the default highlighting. | |
10048
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
3356
diff
changeset
|
52 " Only when an item doesn't have highlighting yet. |
7 | 53 |
10051
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
54 hi def link rcsKeyword Keyword |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
55 hi def link rcsNumber Identifier |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
56 hi def link rcsString String |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
57 hi def link rcsTextStr String |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
58 hi def link rcsSpecial Special |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
59 hi def link rcsDiffLines Special |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
60 hi def link rcsEOFError Error |
7 | 61 |
62 | |
63 let b:current_syntax = "rcs" |