github-linguist 6.4.1 → 7.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/bin/{linguist → github-linguist} +0 -0
- data/grammars/source.abap.json +35 -6
- data/grammars/source.apl.json +4 -8
- data/grammars/source.ballerina.json +82 -3
- data/grammars/source.bdf.json +419 -0
- data/grammars/source.c++.json +25 -3
- data/grammars/source.c.json +6 -3
- data/grammars/source.chapel.json +3 -3
- data/grammars/source.coq.json +2 -2
- data/grammars/source.cs.json +83 -73
- data/grammars/source.csound.json +1 -1
- data/grammars/source.dart.json +1 -1
- data/grammars/source.elixir.json +112 -137
- data/grammars/source.emacs.lisp.json +179 -4
- data/grammars/source.figctrl.json +252 -0
- data/grammars/source.figfont.json +121 -0
- data/grammars/source.fontdir.json +99 -0
- data/grammars/source.fstar.json +439 -0
- data/grammars/source.hx.json +27 -9
- data/grammars/source.j.json +260 -0
- data/grammars/source.julia.json +24 -12
- data/grammars/source.lisp.json +3 -3
- data/grammars/source.mupad.json +1 -1
- data/grammars/source.pony.json +3 -3
- data/grammars/source.powershell.json +2 -2
- data/grammars/source.protobuf.json +87 -5
- data/grammars/source.purescript.json +5 -2
- data/grammars/source.python.json +17 -12
- data/grammars/source.rascal.json +0 -1
- data/grammars/source.reg.json +159 -0
- data/grammars/source.slice.json +2755 -0
- data/grammars/source.solidity.json +2 -2
- data/grammars/source.ts.json +225 -132
- data/grammars/source.tsx.json +235 -142
- data/grammars/source.viml.json +4 -4
- data/grammars/source.xlfd.json +462 -0
- data/grammars/source.yasnippet.json +387 -0
- data/grammars/text.elixir.json +17 -5
- data/grammars/text.html.basic.json +622 -2264
- data/grammars/text.html.elixir.json +10 -1
- data/grammars/text.html.php.blade.json +7 -3
- data/grammars/version +1 -0
- data/lib/linguist.rb +2 -0
- data/lib/linguist/VERSION +1 -1
- data/lib/linguist/generated.rb +14 -1
- data/lib/linguist/heuristics.rb +77 -468
- data/lib/linguist/heuristics.yml +404 -0
- data/lib/linguist/languages.json +1 -1
- data/lib/linguist/languages.yml +86 -6
- data/lib/linguist/samples.json +2624 -483
- data/lib/linguist/strategy/xml.rb +30 -0
- metadata +20 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 584eb9d0d0a078140d1001002374e1141a90e101
|
4
|
+
data.tar.gz: 02b41680b8c2d86bc0faae5028e30d26ac46a77e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 17109a8476e11a55cd22559e65780238c52ec38d79aeae97453c40326151005d8eeff0408226ada32c3fa31f306d2db4fb02923f3a95b794210d3199cc7bebaa
|
7
|
+
data.tar.gz: cc4e26c0c9049efef9ac062dbf4c73b4a8734b722416d61dcc8de148e689caed93ac419fbdbe45ce35da723c6ea7d28795612207ea2f2a0177856f122a4cd794
|
File without changes
|
data/grammars/source.abap.json
CHANGED
@@ -20,6 +20,21 @@
|
|
20
20
|
}
|
21
21
|
}
|
22
22
|
},
|
23
|
+
{
|
24
|
+
"name": "comment.line.pragma.abap",
|
25
|
+
"match": "(?\u003c![^\\s])##.*?(?=([\\.:,\\s]))"
|
26
|
+
},
|
27
|
+
{
|
28
|
+
"name": "string.interpolated.abap",
|
29
|
+
"begin": "(?\u003c!\\\\)\\|(.*?)",
|
30
|
+
"end": "(?\u003c!\\\\)\\|",
|
31
|
+
"patterns": [
|
32
|
+
{
|
33
|
+
"name": "constant.character.escape.abap",
|
34
|
+
"match": "\\\\\\|"
|
35
|
+
}
|
36
|
+
]
|
37
|
+
},
|
23
38
|
{
|
24
39
|
"name": "string.quoted.single.abap",
|
25
40
|
"begin": "'",
|
@@ -72,16 +87,19 @@
|
|
72
87
|
},
|
73
88
|
{
|
74
89
|
"include": "#abaptypes"
|
90
|
+
},
|
91
|
+
{
|
92
|
+
"include": "#system_fields"
|
75
93
|
}
|
76
94
|
],
|
77
95
|
"repository": {
|
78
96
|
"abap_constants": {
|
79
97
|
"name": "constant.language.abap",
|
80
|
-
"match": "(?ix)\\s(initial|null|space|abap_true|abap_false)\\s"
|
98
|
+
"match": "(?ix)\\s(initial|null|space|abap_true|abap_false|table_line)\\s"
|
81
99
|
},
|
82
100
|
"abaptypes": {
|
83
101
|
"name": "support.type.abap",
|
84
|
-
"match": "(?ix)\\s(string|xstring|any|clike|csequence|numeric|xsequence|c|n|i|p|f|d|t|x)(?=\\s
|
102
|
+
"match": "(?ix)\\s(abap_bool|string|xstring|any|clike|csequence|numeric|xsequence|c|n|i|p|f|d|t|x)(?=\\s|\\.|,)"
|
85
103
|
},
|
86
104
|
"arithmetic_operator": {
|
87
105
|
"name": "keyword.operator.arithmetic.abap",
|
@@ -93,14 +111,14 @@
|
|
93
111
|
},
|
94
112
|
"control_keywords": {
|
95
113
|
"name": "keyword.control.flow.abap",
|
96
|
-
"match": "(?ix)(^|\\s)(\n\t at|case|catch|continue|do|elseif|else|endat|endcase|enddo|endif|\n\t endloop|endon|if|loop|on|raise|try\n\t
|
114
|
+
"match": "(?ix)(^|\\s)(\n\t at|case|catch|continue|do|elseif|else|endat|endcase|enddo|endif|\n\t endloop|endon|if|loop|on|raise|try\n\t\t\t )(?=\\s|\\.|:)"
|
97
115
|
},
|
98
116
|
"generic_names": {
|
99
117
|
"match": "[A-Za-z_][A-Za-z0-9_]*"
|
100
118
|
},
|
101
119
|
"hyphenated_keywords": {
|
102
120
|
"name": "keyword.control.hyphenated.abap",
|
103
|
-
"match": "(?ix)(^|\\s)(add-corresponding|\n\t authority-check|\n\t break-point|\n\t class-data|\n\t class-method|\n\t class-methods|\n\t divide-corresponding|\n\t display-mode|\n\t editor-call|\n\t end-of-definition|\n\t end-of-page|\n\t end-of-selection|\n\t field-groups|\n\t field-symbols|\n\t function-pool|\n\t left-justified|\n\t line-count|\n\t line-size|\n\t message-id|\n\t move-corresponding|\n\t multiply-corresponding|\n\t new-line|\n\t new-page|\n\t new-section|\n no-gap|\n no-sign|\n no-zero|\n\t print-control|\n\t read-only|\n\t right-justified|\n\t rp-provide-from-last|\n\t select-options|\n\t selection-screen|\n\t start-of-selection|\n\t subtract-corresponding|\n\t syntax-check|\n\t syntax-trace|\n\t system-call|\n\t top-of-page|\n\t type-pool|\n\t type-pools\n\t
|
121
|
+
"match": "(?ix)(^|\\s)(add-corresponding|\n\t authority-check|\n\t break-point|\n\t class-data|\n\t class-method|\n\t class-methods|\n\t divide-corresponding|\n\t display-mode|\n\t editor-call|\n\t end-of-definition|\n\t end-of-page|\n\t end-of-selection|\n\t field-groups|\n\t field-symbols|\n\t function-pool|\n\t left-justified|\n\t line-count|\n\t line-size|\n\t message-id|\n\t move-corresponding|\n\t multiply-corresponding|\n\t new-line|\n\t new-page|\n\t new-section|\n no-gap|\n no-sign|\n no-zero|\n\t print-control|\n\t read-only|\n\t right-justified|\n\t rp-provide-from-last|\n\t select-options|\n\t selection-screen|\n\t start-of-selection|\n\t subtract-corresponding|\n\t syntax-check|\n\t syntax-trace|\n\t system-call|\n\t top-of-page|\n\t type-pool|\n\t type-pools\n\t\t\t )(?=\\s|\\.|:)"
|
104
122
|
},
|
105
123
|
"keywords": {
|
106
124
|
"patterns": [
|
@@ -115,16 +133,23 @@
|
|
115
133
|
},
|
116
134
|
{
|
117
135
|
"include": "#short_keywords"
|
136
|
+
},
|
137
|
+
{
|
138
|
+
"include": "#keywords_followed_by_braces"
|
118
139
|
}
|
119
140
|
]
|
120
141
|
},
|
142
|
+
"keywords_followed_by_braces": {
|
143
|
+
"name": "keyword.control.simple.abap",
|
144
|
+
"match": "(?ix)\\s*(data|value|field-symbol)(?=\\()"
|
145
|
+
},
|
121
146
|
"logical_operator": {
|
122
147
|
"name": "keyword.operator.arithmetic.abap",
|
123
148
|
"match": "(?i)\\s(is|not|or|and)\\s"
|
124
149
|
},
|
125
150
|
"main_keywords": {
|
126
151
|
"name": "keyword.control.simple.abap",
|
127
|
-
"match": "(?ix)(^|\\s)(\n\t alias|aliases|append|ascending|assert|assign|assigning|\n\t back|begin|binary|bound|byte|\n\t call|changing|check|clear|close|cnt|collect|commit|character|\n\t corresponding|communication|component|compute|concatenate|condense|constants|\n\t controls|convert|create|currency|\n\t data|descending|default|define|definition|deferred|delete|describe|detail|divide|\n\t deleting|\n\t end|endexec|endfunction|\n\t endinterface|endmodule|\n\t endprovide|endselect|endtry|endwhile|event|events|exec|exit|export|\n\t exporting|extract|exception|exceptions|\n\t fetch|fields|format|free|from|function|find|\n\t generate|\n\t hide|\n\t import|importing|index|infotypes|initial|initialization|\n\t interface|interfaces|input|insert|implementation|into|\n\t leave|like|line|load|local|length|left|leading|\n\t method|message|methods|modify|module|move|multiply|match|\n\t object|obligatory|overlay|optional|others|occurrences|occurs|offset|\n\t pack|parameters|perform|position|private|program|protected|provide|public|\n\t radiobutton|raising|ranges|receive|receiving|redefinition|reference|refresh|regex|reject|results|\n\t replace|report|reserve|restore|return|returning|rollback|read|\n\t scan|scroll|search|select|separated|shift|single|skip|sort|sorted|split|standard|
|
152
|
+
"match": "(?ix)(^|\\s)(\n\t abstract|alias|aliases|append|appending|ascending|assert|assign|assigning|\n\t back|begin|binary|bound|byte|\n\t call|cast|changing|check|clear|close|cnt|collect|commit|character|\n\t corresponding|communication|component|compute|concatenate|condense|constants|\n\t controls|convert|create|currency|\n\t data|descending|default|define|definition|deferred|delete|describe|detail|divide|\n\t deleting|\n\t end|endexec|endfunction|ending|\n\t endinterface|endmodule|\n\t endprovide|endselect|endtry|endwhile|event|events|exec|exit|export|\n\t exporting|extract|exception|exceptions|\n\t first|fetch|fields|format|free|from|function|find|for|\n\t generate|\n\t hide|\n\t import|importing|index|infotypes|initial|initialization|\n\t interface|interfaces|input|insert|implementation|into|\n\t\t\tkey|\n\t leave|like|line|load|local|length|left|leading|lower|\n\t method|message|methods|modify|module|move|multiply|match|\n\t occurrence|object|obligatory|overlay|optional|others|occurrences|occurs|offset|\n\t pack|parameters|perform|position|private|program|protected|provide|public|\n\t radiobutton|raising|ranges|receive|receiving|redefinition|reference|refresh|regex|reject|results|\n\t replace|report|reserve|restore|return|returning|rollback|read|\n\t scan|screen|scroll|search|select|separated|shift|single|skip|sort|sorted|split|standard|starting|\n\t statics|step|stop|structure|submatches|submit|subtract|summary|suppress|section|\n\t tables|table|testing|then|times|titlebar|transfer|transformation|translate|transporting|types|type|\n\t unassign|uline|unpack|update|using|\n\t value|\n\t when|while|window|write|where|with|work\n\t\t\t )(?=\\s|\\.|:)"
|
128
153
|
},
|
129
154
|
"math_operators": {
|
130
155
|
"name": "keyword.operator.math.abap",
|
@@ -158,11 +183,15 @@
|
|
158
183
|
},
|
159
184
|
"short_keywords": {
|
160
185
|
"name": "keyword.control.short.abap",
|
161
|
-
"match": "(?i)\\s(add|all|in|get|of|put|ref|set|sum|to)(?=\\s|\\.|:)"
|
186
|
+
"match": "(?i)\\s(add|all|as|by|in|get|no|of|put|ref|set|sum|to)(?=\\s|\\.|:)"
|
162
187
|
},
|
163
188
|
"string_operators": {
|
164
189
|
"name": "keyword.operator.string.abap",
|
165
190
|
"match": "(?ix)\\s(strlen|xstrlen|charlen|lines|numofchar|dbmaxlen)\\("
|
191
|
+
},
|
192
|
+
"system_fields": {
|
193
|
+
"name": "variable.language.abap",
|
194
|
+
"match": "(?ix)\\b(sy-)(abcde|batch|binpt|calld|callr|colno|cpage|cprog|cucol|curow|datar|datlo|datum|dayst|dbcnt|dbnam|dbsysc|dyngr|dynnr|fdayw|fdpos|host|index|langu|ldbpg|lilli|linct|linno|linsz|lisel|listi|loopc|lsind|macol|mandt|marow|modno|msgid|msgno|msgty|msgv[1-4]|opsysc|pagno|pfkey|repid|saprl|scols|slset|spono|srows|staco|staro|stepl|subrc|sysid|tabix|tcode|tfill|timlo|title|tleng|tvar[0-9]|tzone|ucomm|uline|uname|uzeit|vline|wtitl|zonlo)(?=\\.|\\s)"
|
166
195
|
}
|
167
196
|
}
|
168
197
|
}
|
data/grammars/source.apl.json
CHANGED
@@ -331,15 +331,11 @@
|
|
331
331
|
},
|
332
332
|
"13": {
|
333
333
|
"name": "entity.function.name.apl",
|
334
|
-
"
|
335
|
-
|
336
|
-
"
|
337
|
-
{
|
338
|
-
"include": "#embolden"
|
339
|
-
}
|
340
|
-
]
|
334
|
+
"patterns": [
|
335
|
+
{
|
336
|
+
"include": "#embolden"
|
341
337
|
}
|
342
|
-
|
338
|
+
]
|
343
339
|
},
|
344
340
|
"14": {
|
345
341
|
"name": "entity.function.axis.apl"
|
@@ -14,6 +14,9 @@
|
|
14
14
|
{
|
15
15
|
"include": "#documentationDef"
|
16
16
|
},
|
17
|
+
{
|
18
|
+
"include": "#mdDocumentation"
|
19
|
+
},
|
17
20
|
{
|
18
21
|
"include": "#typeDef"
|
19
22
|
},
|
@@ -552,7 +555,7 @@
|
|
552
555
|
},
|
553
556
|
{
|
554
557
|
"name": "keyword.other.ballerina",
|
555
|
-
"match": "\\b(import|version|public|private|attach|as|native|documentation|lock|new|record|limit|ascending|descending|check|start|done|untaint|onretry|oncommit|onabort|scope|compensate|compensation|primarykey)\\b"
|
558
|
+
"match": "\\b(import|version|public|private|attach|as|native|documentation|lock|new|record|limit|ascending|descending|check|start|done|untaint|onretry|oncommit|onabort|scope|compensate|compensation|primarykey|channel|abstract)\\b"
|
556
559
|
},
|
557
560
|
{
|
558
561
|
"name": "keyword.other.siddhi.ballerina",
|
@@ -568,7 +571,7 @@
|
|
568
571
|
},
|
569
572
|
{
|
570
573
|
"name": "keyword.operator.ballerina",
|
571
|
-
"match": "(!|%|\\+|\\-|~=|==|=|!=|\u003c|\u003e|\u0026\u0026
|
574
|
+
"match": "(!|%|\\+|\\-|~=|==|=|!=|\u003c|\u003e|\u0026\u0026|\\|\\||\\?:|\\.\\.\\.)"
|
572
575
|
},
|
573
576
|
{
|
574
577
|
"include": "#types"
|
@@ -672,11 +675,87 @@
|
|
672
675
|
}
|
673
676
|
]
|
674
677
|
},
|
678
|
+
"mdDocumentation": {
|
679
|
+
"patterns": [
|
680
|
+
{
|
681
|
+
"include": "#mdDocumentationReturnParamDescription"
|
682
|
+
},
|
683
|
+
{
|
684
|
+
"include": "#mdDocumentationParamDescription"
|
685
|
+
},
|
686
|
+
{
|
687
|
+
"name": "comment.mddocs.ballerina",
|
688
|
+
"match": "#.*"
|
689
|
+
}
|
690
|
+
]
|
691
|
+
},
|
692
|
+
"mdDocumentationParamDescription": {
|
693
|
+
"patterns": [
|
694
|
+
{
|
695
|
+
"begin": "(#)(?: ?)(\\+)(?: *)((?:[a-zA-Z_][a-zA-Z0-9_]*)|(?:\\^\"([^|\"\\\\\\f\\n\\r\\t]|\\\\\\\\[btnfr]|\\\\[|\"\\\\/])+\"))?(?: *)(-)?(.*)",
|
696
|
+
"end": "(?=[^#\\r\\n]|(?:# ?\\+))",
|
697
|
+
"patterns": [
|
698
|
+
{
|
699
|
+
"name": "comment.mddocs.paramdesc.ballerina",
|
700
|
+
"match": "#.*"
|
701
|
+
}
|
702
|
+
],
|
703
|
+
"beginCaptures": {
|
704
|
+
"1": {
|
705
|
+
"name": "comment.mddocs.ballerina"
|
706
|
+
},
|
707
|
+
"2": {
|
708
|
+
"name": "keyword.ballerina"
|
709
|
+
},
|
710
|
+
"3": {
|
711
|
+
"name": "variable.parameter.ballerina"
|
712
|
+
},
|
713
|
+
"5": {
|
714
|
+
"name": "keyword.ballerina"
|
715
|
+
},
|
716
|
+
"6": {
|
717
|
+
"name": "comment.mddocs.paramdesc.ballerina"
|
718
|
+
}
|
719
|
+
}
|
720
|
+
}
|
721
|
+
]
|
722
|
+
},
|
723
|
+
"mdDocumentationReturnParamDescription": {
|
724
|
+
"patterns": [
|
725
|
+
{
|
726
|
+
"begin": "(#)(?: ?)(\\+)(?: *)(return)(?: *)(-)?(.*)",
|
727
|
+
"end": "(?=[^#\\r\\n]|(?:# ?\\+))",
|
728
|
+
"patterns": [
|
729
|
+
{
|
730
|
+
"name": "comment.mddocs.returnparamdesc.ballerina",
|
731
|
+
"match": "#.*"
|
732
|
+
}
|
733
|
+
],
|
734
|
+
"beginCaptures": {
|
735
|
+
"1": {
|
736
|
+
"name": "comment.mddocs.ballerina"
|
737
|
+
},
|
738
|
+
"2": {
|
739
|
+
"name": "keyword.ballerina"
|
740
|
+
},
|
741
|
+
"3": {
|
742
|
+
"name": "keyword.ballerina"
|
743
|
+
},
|
744
|
+
"4": {
|
745
|
+
"name": "keyword.ballerina"
|
746
|
+
},
|
747
|
+
"5": {
|
748
|
+
"name": "comment.mddocs.returnparamdesc.ballerina"
|
749
|
+
}
|
750
|
+
}
|
751
|
+
}
|
752
|
+
]
|
753
|
+
},
|
675
754
|
"numbers": {
|
676
755
|
"patterns": [
|
677
756
|
{
|
678
757
|
"name": "constant.numeric.decimal.ballerina",
|
679
|
-
"match": "\\b0[xX][\\da-f]+\\b|\\b\\d
|
758
|
+
"match": "\\b0[xX][\\da-f]+\\b|\\b\\d+(?:\\.(?:\\d+|$))?"
|
680
759
|
}
|
681
760
|
]
|
682
761
|
},
|
@@ -0,0 +1,419 @@
|
|
1
|
+
{
|
2
|
+
"name": "Glyph Bitmap Distribution Format",
|
3
|
+
"scopeName": "source.bdf",
|
4
|
+
"patterns": [
|
5
|
+
{
|
6
|
+
"include": "#main"
|
7
|
+
}
|
8
|
+
],
|
9
|
+
"repository": {
|
10
|
+
"eof": {
|
11
|
+
"match": "^(ENDFONT)\\s*$",
|
12
|
+
"captures": {
|
13
|
+
"1": {
|
14
|
+
"name": "keyword.control.end.file.bdf"
|
15
|
+
}
|
16
|
+
}
|
17
|
+
},
|
18
|
+
"globalInfo": {
|
19
|
+
"name": "meta.global-info.bdf",
|
20
|
+
"begin": "^(STARTFONT)\\s+([-+]?\\d+(?:\\.\\d+)?)?\\s*$",
|
21
|
+
"end": "^(?=CHARS\\b|ENDFONT\\b)",
|
22
|
+
"patterns": [
|
23
|
+
{
|
24
|
+
"contentName": "comment.line.bdf",
|
25
|
+
"begin": "^COMMENT(?=\\s|$)",
|
26
|
+
"end": "$",
|
27
|
+
"beginCaptures": {
|
28
|
+
"0": {
|
29
|
+
"name": "keyword.operator.start-comment.bdf"
|
30
|
+
}
|
31
|
+
}
|
32
|
+
},
|
33
|
+
{
|
34
|
+
"name": "meta.content-version.bdf",
|
35
|
+
"begin": "^CONTENTVERSION(?=\\s|$)",
|
36
|
+
"end": "$",
|
37
|
+
"patterns": [
|
38
|
+
{
|
39
|
+
"include": "#paramInteger"
|
40
|
+
}
|
41
|
+
],
|
42
|
+
"beginCaptures": {
|
43
|
+
"0": {
|
44
|
+
"name": "keyword.operator.content-version.bdf"
|
45
|
+
}
|
46
|
+
}
|
47
|
+
},
|
48
|
+
{
|
49
|
+
"name": "meta.font-name.bdf",
|
50
|
+
"begin": "^FONT(?=\\s|$)",
|
51
|
+
"end": "$",
|
52
|
+
"patterns": [
|
53
|
+
{
|
54
|
+
"include": "source.xlfd#name"
|
55
|
+
},
|
56
|
+
{
|
57
|
+
"match": "\\G\\s+(?![-+])(\\S+.*)(?=\\s*$)",
|
58
|
+
"captures": {
|
59
|
+
"1": {
|
60
|
+
"name": "entity.name.identifier.bdf"
|
61
|
+
}
|
62
|
+
}
|
63
|
+
}
|
64
|
+
],
|
65
|
+
"beginCaptures": {
|
66
|
+
"0": {
|
67
|
+
"name": "keyword.operator.font-name.bdf"
|
68
|
+
}
|
69
|
+
}
|
70
|
+
},
|
71
|
+
{
|
72
|
+
"name": "meta.font-size.bdf",
|
73
|
+
"begin": "^SIZE(?=\\s|$)",
|
74
|
+
"end": "$",
|
75
|
+
"patterns": [
|
76
|
+
{
|
77
|
+
"include": "#paramNumbers"
|
78
|
+
}
|
79
|
+
],
|
80
|
+
"beginCaptures": {
|
81
|
+
"0": {
|
82
|
+
"name": "keyword.operator.font-size.bdf"
|
83
|
+
}
|
84
|
+
}
|
85
|
+
},
|
86
|
+
{
|
87
|
+
"name": "meta.bounding-box.bdf",
|
88
|
+
"begin": "^FONTBOUNDINGBOX(?=\\s|$)",
|
89
|
+
"end": "$",
|
90
|
+
"patterns": [
|
91
|
+
{
|
92
|
+
"include": "#paramIntegers"
|
93
|
+
}
|
94
|
+
],
|
95
|
+
"beginCaptures": {
|
96
|
+
"0": {
|
97
|
+
"name": "keyword.operator.bounding-box.bdf"
|
98
|
+
}
|
99
|
+
}
|
100
|
+
},
|
101
|
+
{
|
102
|
+
"name": "meta.metrics-set.bdf",
|
103
|
+
"begin": "^METRICSSET(?=\\s|$)",
|
104
|
+
"end": "$",
|
105
|
+
"patterns": [
|
106
|
+
{
|
107
|
+
"name": "invalid.illegal.unknown-type.bdf",
|
108
|
+
"match": "[3-9]+"
|
109
|
+
},
|
110
|
+
{
|
111
|
+
"include": "#paramInteger"
|
112
|
+
}
|
113
|
+
],
|
114
|
+
"beginCaptures": {
|
115
|
+
"0": {
|
116
|
+
"name": "keyword.operator.metrics-set.bdf"
|
117
|
+
}
|
118
|
+
}
|
119
|
+
},
|
120
|
+
{
|
121
|
+
"name": "meta.properties-list.bdf",
|
122
|
+
"begin": "^(STARTPROPERTIES)(?:\\s+(\\d+))?\\s*$",
|
123
|
+
"end": "^(ENDPROPERTIES)\\s*$|^(?=CHARS\\b|ENDFONT\\b)",
|
124
|
+
"patterns": [
|
125
|
+
{
|
126
|
+
"name": "meta.property.bdf",
|
127
|
+
"match": "^(\\S+)(?:\\s+(\\S.*))?(?=\\s*$)",
|
128
|
+
"captures": {
|
129
|
+
"1": {
|
130
|
+
"name": "variable.assignment.property.name.bdf"
|
131
|
+
},
|
132
|
+
"2": {
|
133
|
+
"patterns": [
|
134
|
+
{
|
135
|
+
"include": "#integer"
|
136
|
+
},
|
137
|
+
{
|
138
|
+
"include": "#quotedString"
|
139
|
+
}
|
140
|
+
]
|
141
|
+
}
|
142
|
+
}
|
143
|
+
}
|
144
|
+
],
|
145
|
+
"beginCaptures": {
|
146
|
+
"1": {
|
147
|
+
"name": "keyword.control.start.properties.bdf"
|
148
|
+
},
|
149
|
+
"2": {
|
150
|
+
"patterns": [
|
151
|
+
{
|
152
|
+
"include": "#integer"
|
153
|
+
}
|
154
|
+
]
|
155
|
+
}
|
156
|
+
},
|
157
|
+
"endCaptures": {
|
158
|
+
"1": {
|
159
|
+
"name": "keyword.control.end.properties.bdf"
|
160
|
+
}
|
161
|
+
}
|
162
|
+
},
|
163
|
+
{
|
164
|
+
"include": "#metrics"
|
165
|
+
}
|
166
|
+
],
|
167
|
+
"beginCaptures": {
|
168
|
+
"1": {
|
169
|
+
"name": "keyword.control.start.file.bdf"
|
170
|
+
},
|
171
|
+
"2": {
|
172
|
+
"name": "constant.numeric.float.decimal.version-number.bdf"
|
173
|
+
}
|
174
|
+
}
|
175
|
+
},
|
176
|
+
"glyphs": {
|
177
|
+
"name": "meta.glyphs-list.bdf",
|
178
|
+
"begin": "^(CHARS)(?:\\s+(\\d+))?\\s*$",
|
179
|
+
"end": "^(?=ENDFONT\\b)",
|
180
|
+
"patterns": [
|
181
|
+
{
|
182
|
+
"name": "meta.glyph.bdf",
|
183
|
+
"begin": "^(STARTCHAR)(?:\\s+(\\S.*))?(?=\\s*$)",
|
184
|
+
"end": "^(ENDCHAR)\\s*$",
|
185
|
+
"patterns": [
|
186
|
+
{
|
187
|
+
"name": "meta.glyph-encoding.bdf",
|
188
|
+
"begin": "^ENCODING(?=\\s|$)",
|
189
|
+
"end": "$",
|
190
|
+
"patterns": [
|
191
|
+
{
|
192
|
+
"include": "#paramNumbers"
|
193
|
+
}
|
194
|
+
],
|
195
|
+
"beginCaptures": {
|
196
|
+
"0": {
|
197
|
+
"name": "keyword.operator.glyph-encoding.bdf"
|
198
|
+
}
|
199
|
+
}
|
200
|
+
},
|
201
|
+
{
|
202
|
+
"name": "meta.bounding-box.bdf",
|
203
|
+
"begin": "^BBX(?=\\s|$)",
|
204
|
+
"end": "$",
|
205
|
+
"patterns": [
|
206
|
+
{
|
207
|
+
"include": "#paramNumbers"
|
208
|
+
}
|
209
|
+
],
|
210
|
+
"beginCaptures": {
|
211
|
+
"0": {
|
212
|
+
"name": "keyword.operator.bounding-box.bdf"
|
213
|
+
}
|
214
|
+
}
|
215
|
+
},
|
216
|
+
{
|
217
|
+
"name": "meta.bitmap.bdf",
|
218
|
+
"begin": "^(BITMAP)\\s*$",
|
219
|
+
"end": "^(?=ENDCHAR\\b|ENDFONT\\b)",
|
220
|
+
"patterns": [
|
221
|
+
{
|
222
|
+
"name": "constant.numeric.hexadecimal.hex.byte.bdf",
|
223
|
+
"match": "^[0-9A-Fa-f]+(?=\\s*$)"
|
224
|
+
}
|
225
|
+
],
|
226
|
+
"beginCaptures": {
|
227
|
+
"1": {
|
228
|
+
"name": "keyword.operator.bitmap.bdf"
|
229
|
+
}
|
230
|
+
}
|
231
|
+
},
|
232
|
+
{
|
233
|
+
"include": "#metrics"
|
234
|
+
}
|
235
|
+
],
|
236
|
+
"beginCaptures": {
|
237
|
+
"1": {
|
238
|
+
"name": "keyword.control.start.glyph.bdf"
|
239
|
+
},
|
240
|
+
"2": {
|
241
|
+
"name": "string.unquoted.glyph-name.bdf"
|
242
|
+
}
|
243
|
+
},
|
244
|
+
"endCaptures": {
|
245
|
+
"1": {
|
246
|
+
"name": "keyword.control.end.glyph.bdf"
|
247
|
+
}
|
248
|
+
}
|
249
|
+
}
|
250
|
+
],
|
251
|
+
"beginCaptures": {
|
252
|
+
"1": {
|
253
|
+
"name": "keyword.control.start.glyphs.bdf"
|
254
|
+
},
|
255
|
+
"2": {
|
256
|
+
"name": "constant.numeric.decimal.integer.bdf"
|
257
|
+
}
|
258
|
+
}
|
259
|
+
},
|
260
|
+
"integer": {
|
261
|
+
"patterns": [
|
262
|
+
{
|
263
|
+
"name": "constant.numeric.integer.octal.bdf",
|
264
|
+
"match": "(?\u003c!\\w)[-+]?(?=0)\\d+"
|
265
|
+
},
|
266
|
+
{
|
267
|
+
"name": "constant.numeric.integer.decimal.bdf",
|
268
|
+
"match": "(?\u003c!\\w)[-+]?\\d+"
|
269
|
+
}
|
270
|
+
]
|
271
|
+
},
|
272
|
+
"main": {
|
273
|
+
"patterns": [
|
274
|
+
{
|
275
|
+
"include": "#globalInfo"
|
276
|
+
},
|
277
|
+
{
|
278
|
+
"include": "#glyphs"
|
279
|
+
},
|
280
|
+
{
|
281
|
+
"include": "#eof"
|
282
|
+
}
|
283
|
+
]
|
284
|
+
},
|
285
|
+
"metrics": {
|
286
|
+
"name": "meta.font-metric.${1:/downcase}.bdf",
|
287
|
+
"begin": "^([SD]WIDTH1?|VVECTOR)(?=\\s|$)",
|
288
|
+
"end": "$",
|
289
|
+
"patterns": [
|
290
|
+
{
|
291
|
+
"include": "#paramNumbers"
|
292
|
+
}
|
293
|
+
],
|
294
|
+
"beginCaptures": {
|
295
|
+
"0": {
|
296
|
+
"name": "keyword.operator.font-metric.bdf"
|
297
|
+
}
|
298
|
+
}
|
299
|
+
},
|
300
|
+
"numbers": {
|
301
|
+
"patterns": [
|
302
|
+
{
|
303
|
+
"include": "#real"
|
304
|
+
},
|
305
|
+
{
|
306
|
+
"include": "#integer"
|
307
|
+
}
|
308
|
+
]
|
309
|
+
},
|
310
|
+
"paramInteger": {
|
311
|
+
"patterns": [
|
312
|
+
{
|
313
|
+
"match": "\\G\\s+([-+]?[0-9]+)\\s*$",
|
314
|
+
"captures": {
|
315
|
+
"1": {
|
316
|
+
"patterns": [
|
317
|
+
{
|
318
|
+
"include": "#integer"
|
319
|
+
}
|
320
|
+
]
|
321
|
+
}
|
322
|
+
}
|
323
|
+
},
|
324
|
+
{
|
325
|
+
"include": "#paramInvalid"
|
326
|
+
}
|
327
|
+
]
|
328
|
+
},
|
329
|
+
"paramIntegers": {
|
330
|
+
"patterns": [
|
331
|
+
{
|
332
|
+
"include": "#integer"
|
333
|
+
},
|
334
|
+
{
|
335
|
+
"name": "invalid.illegal.syntax.type.bdf",
|
336
|
+
"match": "(?![-+0-9.])\\S+"
|
337
|
+
}
|
338
|
+
]
|
339
|
+
},
|
340
|
+
"paramInvalid": {
|
341
|
+
"match": "\\G\\s+(\\S+.+)\\s*$",
|
342
|
+
"captures": {
|
343
|
+
"1": {
|
344
|
+
"name": "invalid.illegal.syntax.type.bdf"
|
345
|
+
}
|
346
|
+
}
|
347
|
+
},
|
348
|
+
"paramNumber": {
|
349
|
+
"patterns": [
|
350
|
+
{
|
351
|
+
"match": "\\G\\s+([-+]?(?:\\d*\\.\\d+|\\d+))\\s*$",
|
352
|
+
"captures": {
|
353
|
+
"1": {
|
354
|
+
"patterns": [
|
355
|
+
{
|
356
|
+
"include": "#real"
|
357
|
+
},
|
358
|
+
{
|
359
|
+
"include": "#integer"
|
360
|
+
}
|
361
|
+
]
|
362
|
+
}
|
363
|
+
}
|
364
|
+
},
|
365
|
+
{
|
366
|
+
"include": "#paramInvalid"
|
367
|
+
}
|
368
|
+
]
|
369
|
+
},
|
370
|
+
"paramNumbers": {
|
371
|
+
"patterns": [
|
372
|
+
{
|
373
|
+
"include": "#real"
|
374
|
+
},
|
375
|
+
{
|
376
|
+
"include": "#integer"
|
377
|
+
},
|
378
|
+
{
|
379
|
+
"name": "invalid.illegal.syntax.type.bdf",
|
380
|
+
"match": "(?![-+0-9.])\\S+"
|
381
|
+
}
|
382
|
+
]
|
383
|
+
},
|
384
|
+
"paramString": {
|
385
|
+
"name": "variable.assignment.bdf",
|
386
|
+
"match": "\\G\\s+(\\S.*)\\s*$",
|
387
|
+
"captures": {
|
388
|
+
"1": {
|
389
|
+
"name": "string.unquoted.bdf"
|
390
|
+
}
|
391
|
+
}
|
392
|
+
},
|
393
|
+
"quotedString": {
|
394
|
+
"name": "string.quoted.double.bdf",
|
395
|
+
"begin": "\"",
|
396
|
+
"end": "\"(?!\")|(?=$)",
|
397
|
+
"patterns": [
|
398
|
+
{
|
399
|
+
"name": "constant.character.escape.quote.bdf",
|
400
|
+
"match": "\"\""
|
401
|
+
}
|
402
|
+
],
|
403
|
+
"beginCaptures": {
|
404
|
+
"0": {
|
405
|
+
"name": "punctuation.definition.string.begin.bdf"
|
406
|
+
}
|
407
|
+
},
|
408
|
+
"endCaptures": {
|
409
|
+
"0": {
|
410
|
+
"name": "punctuation.definition.string.end.bdf"
|
411
|
+
}
|
412
|
+
}
|
413
|
+
},
|
414
|
+
"real": {
|
415
|
+
"name": "constant.numeric.float.bdf",
|
416
|
+
"match": "(?\u003c!\\w)[-+]?\\d*\\.\\d+"
|
417
|
+
}
|
418
|
+
}
|
419
|
+
}
|