File: lpsolve.lang

package info (click to toggle)
gretl 2022c-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 59,552 kB
  • sloc: ansic: 409,074; sh: 4,449; makefile: 3,222; cpp: 2,777; xml: 599; perl: 364
file content (69 lines) | stat: -rw-r--r-- 2,044 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
<?xml version="1.0" encoding="UTF-8"?>
<!--

 This file is for use with GtkSourceView

 Author: Allin Cottrell

-->
<language id="lpsolve" name="lpsolve" version="2.0" _section="Other">
  <metadata>
    <property name="mimetypes">text/x-lpsolve</property>
    <property name="globs">*.lp</property>
    <property name="line-comment-start">//</property>
  </metadata>

  <styles>
    <style id="comment" name="Comment" map-to="def:comment"/>
    <style id="keyword" name="Keyword" map-to="def:keyword"/>
    <style id="floating-point" name="Float" map-to="def:floating-point"/>
    <style id="integer-number" name="Integer" map-to="def:base-n-integer"/>
  </styles>

  <definitions>
    <context id="line-comment" style-ref="comment" end-at-line-end="true" class="comment" class-disabled="no-spell-check">
      <start>//</start>
      <include>
        <context ref="def:escape"/>
        <context ref="def:line-continue"/>
      </include>
    </context>
    <context id="block-comment" style-ref="comment">
      <start>/\*</start>
      <end>\*/</end>
      <include>
        <context ref="def:escape"/>
        <context ref="def:line-continue"/>
      </include>
    </context>
    <context id="floating-point" style-ref="floating-point">
      <match extended="true">
        (?&lt;![\w\.])
        ([0-9]+[Ee][-+]?[0-9]+|
         ([0-9]*\.[0-9]+|[0-9]+\.)([Ee][-+]?[0-9]+)?)
        [i]?
        (?![\w\.])
      </match>
    </context>
    <context id="integer-number" style-ref="integer-number">
      <match extended="true">
        (?&lt;![\w\.])
        ([1-9][0-9]*|0)[i]?
        (?![\w\.])
      </match>
    </context>
    <context id="keyword" style-ref="keyword">
      <keyword>max</keyword>
      <keyword>int</keyword>
    </context>
    <context id="lpsolve" class="no-spell-check">
      <include>
        <context ref="keyword"/>
	<context ref="floating-point"/>
	<context ref="integer-number"/>
	<context ref="block-comment"/>
	<context ref="line-comment"/>
      </include>
    </context>
  </definitions>
</language>