Mercurial > vim
annotate runtime/syntax/jgraph.vim @ 33480:f8dd278ab05f v9.0.1991
patch 9.0.1991: no cmdline completion for setting the font
Commit: https://github.com/vim/vim/commit/290b887e8cc2c0d3dfc7f315b2052472c7c589cc
Author: Yee Cheng Chin <ychin.git@gmail.com>
Date: Thu Oct 5 20:54:21 2023 +0200
patch 9.0.1991: no cmdline completion for setting the font
Problem: no cmdline completion for setting the font
Solution: enable it on Win32 and GTK builds
Add guifont cmdline completion (for Windows and GTK)
For Windows, auto-complete will only suggest monospace fonts as that's
the only types allowed. Will also suggest font options after the colon,
including suggesting the current font size for convenience, and misc
charset and quality options like `cANSI` and `qCLEARTYPE`.
For GTK, auto-complete will suggest only monospace fonts for `guifont`
but will include all fonts for `guifontwide`. The completion code
doesn't currently suggest the current font size, as the GTK guifont
format does not have a clear delimiter (':' for other platforms).
closes: #13264
Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: Yee Cheng Chin <ychin.git@gmail.com>
author | Christian Brabandt <cb@256bit.org> |
---|---|
date | Thu, 05 Oct 2023 21:00:07 +0200 |
parents | 46763b01cd9a |
children |
rev | line source |
---|---|
7 | 1 " Vim syntax file |
2 " Language: jgraph (graph plotting utility) | |
3 " Maintainer: Jonas Munsin jmunsin@iki.fi | |
4 " Last Change: 2003 May 04 | |
5 " this syntax file is not yet complete | |
6 | |
7 | |
10048
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
7
diff
changeset
|
8 " 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
|
9 if exists("b:current_syntax") |
7 | 10 finish |
11 endif | |
12 | |
13 syn case match | |
14 | |
15 " comments | |
16 syn region jgraphComment start="(\* " end=" \*)" | |
17 | |
18 syn keyword jgraphCmd newcurve newgraph marktype | |
19 syn keyword jgraphType xaxis yaxis | |
20 | |
21 syn keyword jgraphType circle box diamond triangle x cross ellipse | |
22 syn keyword jgraphType xbar ybar text postscript eps none general | |
23 | |
24 syn keyword jgraphType solid dotted dashed longdash dotdash dodotdash | |
25 syn keyword jgraphType dotdotdashdash pts | |
26 | |
27 "integer number, or floating point number without a dot. - or no - | |
28 syn match jgraphNumber "\<-\=\d\+\>" | |
29 "floating point number, with dot - or no - | |
30 syn match jgraphNumber "\<-\=\d\+\.\d*\>" | |
31 "floating point number, starting with a dot - or no - | |
32 syn match jgraphNumber "\-\=\.\d\+\>" | |
33 | |
34 | |
35 " Define the default highlighting. | |
10048
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
7
diff
changeset
|
36 " Only when an item doesn't have highlighting yet |
7 | 37 |
10051
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
38 hi def link jgraphComment Comment |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
39 hi def link jgraphCmd Identifier |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
40 hi def link jgraphType Type |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
41 hi def link jgraphNumber Number |
7 | 42 |
43 | |
44 | |
45 let b:current_syntax = "jgraph" |