annotate runtime/syntax/man.vim @ 18440:d6cb1e706fb7 v8.1.2214

patch 8.1.2214: too much is redrawn when 'cursorline' is set Commit: https://github.com/vim/vim/commit/11a58af66fa5c442f0a22c5d59beabf187ed4e89 Author: Bram Moolenaar <Bram@vim.org> Date: Thu Oct 24 22:32:31 2019 +0200 patch 8.1.2214: too much is redrawn when 'cursorline' is set Problem: Too much is redrawn when 'cursorline' is set. Solution: Don't do a complete redraw. (closes https://github.com/vim/vim/issues/5079)
author Bram Moolenaar <Bram@vim.org>
date Thu, 24 Oct 2019 22:45:04 +0200
parents 46763b01cd9a
children bd021eb62e73
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1 " Vim syntax file
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
2 " Language: Man page
2034
7bc41231fbc7 Update runtime files.
Bram Moolenaar <bram@zimbu.org>
parents: 1621
diff changeset
3 " Maintainer: SungHyun Nam <goweol@gmail.com>
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
4 " Previous Maintainer: Gautam H. Mudunuri <gmudunur@informatica.com>
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
5 " Version Info:
7272
17333ebd2bbd commit https://github.com/vim/vim/commit/d042dc825c9b97dacd84d4728f88300da4d5b6b9
Christian Brabandt <cb@256bit.org>
parents: 2034
diff changeset
6 " Last Change: 2015 Nov 24
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
8 " Additional highlighting by Johannes Tanzler <johannes.tanzler@aon.at>:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
9 " * manSubHeading
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
10 " * manSynopsis (only for sections 2 and 3)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
11
10048
43efa4f5a8ea commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents: 7272
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: 7272
diff changeset
13 if exists("b:current_syntax")
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
14 finish
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
15 endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
16
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
17 " Get the CTRL-H syntax to handle backspaced text
10048
43efa4f5a8ea commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents: 7272
diff changeset
18 runtime! syntax/ctrlh.vim
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
19
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
20 syn case ignore
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
21 syn match manReference "\f\+([1-9][a-z]\=)"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
22 syn match manTitle "^\f\+([0-9]\+[a-z]\=).*"
7272
17333ebd2bbd commit https://github.com/vim/vim/commit/d042dc825c9b97dacd84d4728f88300da4d5b6b9
Christian Brabandt <cb@256bit.org>
parents: 2034
diff changeset
23 syn match manSectionHeading "^[a-z][a-z -]*[a-z]$"
17333ebd2bbd commit https://github.com/vim/vim/commit/d042dc825c9b97dacd84d4728f88300da4d5b6b9
Christian Brabandt <cb@256bit.org>
parents: 2034
diff changeset
24 syn match manSubHeading "^\s\{3\}[a-z][a-z -]*[a-z]$"
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
25 syn match manOptionDesc "^\s*[+-][a-z0-9]\S*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
26 syn match manLongOptionDesc "^\s*--[a-z0-9-]\S*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
27 " syn match manHistory "^[a-z].*last change.*$"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
28
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
29 if getline(1) =~ '^[a-zA-Z_]\+([23])'
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
30 syntax include @cCode <sfile>:p:h/c.vim
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
31 syn match manCFuncDefinition display "\<\h\w*\>\s*("me=e-1 contained
1621
82b5078be2dd updated for version 7.2a
vimboss
parents: 7
diff changeset
32 syn region manSynopsis start="^SYNOPSIS"hs=s+8 end="^\u\+\s*$"me=e-12 keepend contains=manSectionHeading,@cCode,manCFuncDefinition
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
33 endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
34
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
35
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
36 " Define the default highlighting.
10048
43efa4f5a8ea commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents: 7272
diff changeset
37 " Only when an item doesn't have highlighting yet
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
38
10051
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
39 hi def link manTitle Title
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
40 hi def link manSectionHeading Statement
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
41 hi def link manOptionDesc Constant
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
42 hi def link manLongOptionDesc Constant
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
43 hi def link manReference PreProc
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
44 hi def link manSubHeading Function
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
45 hi def link manCFuncDefinition Function
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
46
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
47
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
48 let b:current_syntax = "man"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
49
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
50 " vim:ts=8 sts=2 sw=2: