2006-08-26 04:46:29 -05:00
|
|
|
<?xml version="1.0" encoding="UTF-8"?>
|
2007-06-18 00:03:03 -05:00
|
|
|
<!--
|
|
|
|
|
2011-01-05 22:45:36 -08:00
|
|
|
This file is part of GtkSourceView
|
|
|
|
|
2007-06-18 00:03:03 -05:00
|
|
|
Author: Andrew Johnson <acjgenius@earthlink.net>
|
|
|
|
Copyright (C) 2004 Andrew Johnson <acjgenius@earthlink.net>
|
|
|
|
Copyright (C) 2005 Thierry Moisan <thierryn@videotron.ca>
|
|
|
|
|
|
|
|
This library is free software; you can redistribute it and/or modify
|
|
|
|
it under the terms of the GNU General Public License as published by
|
|
|
|
the Free Software Foundation; either version 2 of the License, or
|
|
|
|
(at your option) any later version.
|
|
|
|
|
|
|
|
This program is distributed in the hope that it will be useful,
|
|
|
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
GNU General Public License for more details.
|
|
|
|
|
|
|
|
You should have received a copy of the GNU General Public License
|
|
|
|
along with this program; if not, write to the Free Software
|
|
|
|
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
|
|
|
|
|
|
-->
|
2006-12-16 10:58:34 -06:00
|
|
|
<language id="pascal" _name="Pascal" version="2.0" _section="Sources">
|
|
|
|
<metadata>
|
|
|
|
<property name="mimetypes">text/x-pascal</property>
|
|
|
|
<property name="globs">*.p;*.pas</property>
|
|
|
|
<property name="line-comment-start">//</property>
|
|
|
|
</metadata>
|
|
|
|
|
|
|
|
<styles>
|
|
|
|
<style id="comment" _name="Comment" map-to="def:comment"/>
|
|
|
|
<style id="string" _name="String" map-to="def:string"/>
|
|
|
|
<style id="keyword" _name="Keyword" map-to="def:keyword"/>
|
|
|
|
<style id="decimal" _name="Decimal" map-to="def:decimal"/>
|
2007-09-09 14:21:19 -05:00
|
|
|
<style id="type" _name="Data Type" map-to="def:type"/>
|
2006-12-16 10:58:34 -06:00
|
|
|
<style id="preprocessor" _name="Preprocessor" map-to="def:preprocessor"/>
|
|
|
|
</styles>
|
|
|
|
|
2007-11-15 22:49:52 -06:00
|
|
|
<default-regex-options case-sensitive="false"/>
|
|
|
|
|
2006-12-16 10:58:34 -06:00
|
|
|
<definitions>
|
2007-05-06 08:01:49 -05:00
|
|
|
|
2011-01-05 22:45:36 -08:00
|
|
|
<context id="string" style-ref="string" class="string" class-disabled="no-spell-check">
|
2006-12-16 10:58:34 -06:00
|
|
|
<start>[uUrR]?'</start>
|
|
|
|
<end>'</end>
|
|
|
|
</context>
|
2007-05-06 08:01:49 -05:00
|
|
|
|
2011-01-05 22:45:36 -08:00
|
|
|
<context id="line-comment" style-ref="comment" end-at-line-end="true" class="comment" class-disabled="no-spell-check">
|
2007-06-20 23:37:33 -05:00
|
|
|
<start>//</start>
|
2007-05-06 08:01:49 -05:00
|
|
|
<include>
|
|
|
|
<context ref="def:in-comment"/>
|
|
|
|
</include>
|
2006-12-16 10:58:34 -06:00
|
|
|
</context>
|
2007-05-06 08:01:49 -05:00
|
|
|
|
2011-01-05 22:45:36 -08:00
|
|
|
<context id="block-comment-1" style-ref="comment" class="comment" class-disabled="no-spell-check">
|
2006-12-16 10:58:34 -06:00
|
|
|
<start>\(\*</start>
|
|
|
|
<end>\*\)</end>
|
2007-05-06 08:01:49 -05:00
|
|
|
<include>
|
|
|
|
<context ref="def:in-comment"/>
|
|
|
|
</include>
|
2006-12-16 10:58:34 -06:00
|
|
|
</context>
|
2007-05-06 08:01:49 -05:00
|
|
|
|
2011-01-05 22:45:36 -08:00
|
|
|
<context id="block-comment-2" style-ref="comment" class="comment" class-disabled="no-spell-check">
|
2007-11-26 00:38:51 -06:00
|
|
|
<start>\{</start>
|
2006-12-16 10:58:34 -06:00
|
|
|
<end>\}</end>
|
2007-05-06 08:01:49 -05:00
|
|
|
<include>
|
|
|
|
<context ref="def:in-comment"/>
|
|
|
|
</include>
|
2006-12-16 10:58:34 -06:00
|
|
|
</context>
|
2007-05-06 08:01:49 -05:00
|
|
|
|
2006-12-16 10:58:34 -06:00
|
|
|
<context id="preprocessor-defines" style-ref="preprocessor" end-at-line-end="true">
|
|
|
|
<start>\{\$</start>
|
|
|
|
<end>\}</end>
|
|
|
|
</context>
|
2007-05-06 08:01:49 -05:00
|
|
|
|
2006-12-16 10:58:34 -06:00
|
|
|
<context id="general-format" style-ref="keyword">
|
|
|
|
<keyword>Program</keyword>
|
|
|
|
<keyword>Library</keyword>
|
|
|
|
<keyword>Unit</keyword>
|
|
|
|
<keyword>Uses</keyword>
|
|
|
|
<keyword>Interface</keyword>
|
|
|
|
<keyword>Implementation</keyword>
|
|
|
|
<keyword>Initialization</keyword>
|
|
|
|
<keyword>Finalization</keyword>
|
|
|
|
<keyword>Begin</keyword>
|
|
|
|
<keyword>End</keyword>
|
|
|
|
<keyword>Var</keyword>
|
|
|
|
<keyword>Const</keyword>
|
|
|
|
</context>
|
2007-05-06 08:01:49 -05:00
|
|
|
|
2006-12-16 10:58:34 -06:00
|
|
|
<context id="functions-and-function-modifiers" style-ref="keyword">
|
|
|
|
<keyword>Function</keyword>
|
|
|
|
<keyword>Procedure</keyword>
|
|
|
|
<keyword>Overload</keyword>
|
|
|
|
<keyword>cdecl</keyword>
|
|
|
|
</context>
|
2007-05-06 08:01:49 -05:00
|
|
|
|
2006-12-16 10:58:34 -06:00
|
|
|
<context id="boolean-bitwise-operators" style-ref="keyword">
|
|
|
|
<keyword>if</keyword>
|
|
|
|
<keyword>then</keyword>
|
|
|
|
<keyword>else</keyword>
|
|
|
|
<keyword>is</keyword>
|
|
|
|
<keyword>and</keyword>
|
2009-01-04 13:45:36 -06:00
|
|
|
<keyword>and_then</keyword>
|
2006-12-16 10:58:34 -06:00
|
|
|
<keyword>not</keyword>
|
|
|
|
<keyword>or</keyword>
|
2009-01-04 13:45:36 -06:00
|
|
|
<keyword>or_else</keyword>
|
2006-12-16 10:58:34 -06:00
|
|
|
<keyword>xor</keyword>
|
|
|
|
<keyword>shr</keyword>
|
|
|
|
<keyword>shl</keyword>
|
2009-01-04 13:45:36 -06:00
|
|
|
<keyword>otherwise</keyword>
|
2006-12-16 10:58:34 -06:00
|
|
|
</context>
|
2007-05-06 08:01:49 -05:00
|
|
|
|
2006-12-16 10:58:34 -06:00
|
|
|
<context id="math-operators" style-ref="keyword">
|
|
|
|
<keyword>div</keyword>
|
|
|
|
<keyword>mod</keyword>
|
|
|
|
</context>
|
2007-05-06 08:01:49 -05:00
|
|
|
|
2006-12-16 10:58:34 -06:00
|
|
|
<context id="loop-flow-and-exceptions-keywords" style-ref="keyword">
|
|
|
|
<keyword>while</keyword>
|
|
|
|
<keyword>do</keyword>
|
|
|
|
<keyword>for</keyword>
|
|
|
|
<keyword>to</keyword>
|
|
|
|
<keyword>case</keyword>
|
|
|
|
<keyword>of</keyword>
|
|
|
|
<keyword>repeat</keyword>
|
|
|
|
<keyword>until</keyword>
|
|
|
|
<keyword>break</keyword>
|
|
|
|
<keyword>continue</keyword>
|
|
|
|
<keyword>try</keyword>
|
|
|
|
<keyword>except</keyword>
|
|
|
|
<keyword>finally</keyword>
|
|
|
|
<keyword>raise</keyword>
|
2009-01-04 13:45:36 -06:00
|
|
|
<keyword>downto</keyword>
|
|
|
|
<keyword>in</keyword>
|
2006-12-16 10:58:34 -06:00
|
|
|
</context>
|
2007-05-06 08:01:49 -05:00
|
|
|
|
2006-12-16 10:58:34 -06:00
|
|
|
<context id="type-class-and-object-keywords" style-ref="keyword">
|
|
|
|
<keyword>Type</keyword>
|
|
|
|
<keyword>Packed</keyword>
|
|
|
|
<keyword>Array</keyword>
|
|
|
|
<keyword>Record</keyword>
|
|
|
|
<keyword>Object</keyword>
|
|
|
|
<keyword>Class</keyword>
|
|
|
|
<keyword>Interface</keyword>
|
|
|
|
<keyword>Public</keyword>
|
|
|
|
<keyword>Private</keyword>
|
|
|
|
<keyword>Protected</keyword>
|
|
|
|
<keyword>Constructor</keyword>
|
|
|
|
<keyword>Destructor</keyword>
|
|
|
|
<keyword>Virtual</keyword>
|
|
|
|
<keyword>Abstract</keyword>
|
|
|
|
<keyword>Override</keyword>
|
|
|
|
<keyword>Property</keyword>
|
2007-11-15 22:49:52 -06:00
|
|
|
<keyword>ReadLn</keyword>
|
2006-12-16 10:58:34 -06:00
|
|
|
<keyword>Read</keyword>
|
2007-11-15 22:49:52 -06:00
|
|
|
<keyword>WriteLn</keyword>
|
2006-12-16 10:58:34 -06:00
|
|
|
<keyword>Write</keyword>
|
|
|
|
<keyword>default</keyword>
|
|
|
|
<keyword>With</keyword>
|
|
|
|
<keyword>As</keyword>
|
|
|
|
<keyword>self</keyword>
|
|
|
|
<keyword>Inherited</keyword>
|
2009-01-04 13:45:36 -06:00
|
|
|
<keyword>Forward</keyword>
|
|
|
|
<keyword>Implements</keyword>
|
|
|
|
<keyword>varargs</keyword>
|
|
|
|
<keyword>far</keyword>
|
|
|
|
<keyword>near</keyword>
|
|
|
|
<keyword>absolute</keyword>
|
|
|
|
<keyword>all</keyword>
|
|
|
|
<keyword>asm</keyword>
|
|
|
|
<keyword>attribute</keyword>
|
|
|
|
<keyword>bindable</keyword>
|
|
|
|
<keyword>export</keyword>
|
|
|
|
<keyword>exports</keyword>
|
|
|
|
<keyword>external</keyword>
|
|
|
|
<keyword>file</keyword>
|
|
|
|
<keyword>goto</keyword>
|
|
|
|
<keyword>import</keyword>
|
|
|
|
<keyword>interrupt</keyword>
|
|
|
|
<keyword>published</keyword>
|
|
|
|
<keyword>qualified</keyword>
|
|
|
|
<keyword>resident</keyword>
|
|
|
|
<keyword>restricted</keyword>
|
|
|
|
<keyword>segment</keyword>
|
|
|
|
<keyword>set</keyword>
|
|
|
|
<keyword>value</keyword>
|
2006-12-16 10:58:34 -06:00
|
|
|
</context>
|
2007-05-06 08:01:49 -05:00
|
|
|
|
2007-09-09 14:21:19 -05:00
|
|
|
<context id="builtin-types" style-ref="type">
|
2006-12-16 10:58:34 -06:00
|
|
|
<keyword>Char</keyword>
|
|
|
|
<keyword>String</keyword>
|
|
|
|
<keyword>Integer</keyword>
|
|
|
|
<keyword>Real</keyword>
|
|
|
|
<keyword>Boolean</keyword>
|
|
|
|
<keyword>Pointer</keyword>
|
2013-12-06 17:03:17 -08:00
|
|
|
<keyword>Byte</keyword>
|
|
|
|
<keyword>LongInt</keyword>
|
2006-12-16 10:58:34 -06:00
|
|
|
</context>
|
2007-05-06 08:01:49 -05:00
|
|
|
|
2006-12-16 10:58:34 -06:00
|
|
|
<context id="builtin-functions" style-ref="keyword">
|
|
|
|
<keyword>chr</keyword>
|
|
|
|
<keyword>ord</keyword>
|
|
|
|
<keyword>succ</keyword>
|
|
|
|
<keyword>pred</keyword>
|
|
|
|
<keyword>abs</keyword>
|
|
|
|
<keyword>round</keyword>
|
|
|
|
<keyword>trunc</keyword>
|
|
|
|
<keyword>sqr</keyword>
|
|
|
|
<keyword>sqrt</keyword>
|
|
|
|
<keyword>arctan</keyword>
|
|
|
|
<keyword>cos</keyword>
|
|
|
|
<keyword>sin</keyword>
|
|
|
|
<keyword>exp</keyword>
|
|
|
|
<keyword>ln</keyword>
|
|
|
|
<keyword>odd</keyword>
|
|
|
|
<keyword>eof</keyword>
|
|
|
|
<keyword>eoln</keyword>
|
2009-01-04 13:45:36 -06:00
|
|
|
<keyword>pow</keyword>
|
2006-12-16 10:58:34 -06:00
|
|
|
</context>
|
2007-05-06 08:01:49 -05:00
|
|
|
|
2006-12-16 10:58:34 -06:00
|
|
|
<context id="builtin-values" style-ref="keyword">
|
|
|
|
<keyword>nil</keyword>
|
|
|
|
<keyword>False</keyword>
|
|
|
|
<keyword>True</keyword>
|
|
|
|
</context>
|
2007-05-06 08:01:49 -05:00
|
|
|
|
|
|
|
<context id="number" style-ref="decimal">
|
|
|
|
<match extended="true">
|
|
|
|
(?<![\w\.])
|
|
|
|
(([0-9]+)|([0-9]+\.[0-9]+([Ee][-]?[0-9]+)?))
|
|
|
|
(?![\w\.])
|
|
|
|
</match>
|
|
|
|
</context>
|
|
|
|
|
|
|
|
<context id="hex-number" style-ref="decimal">
|
|
|
|
<match extended="true">
|
|
|
|
(?<![\w\.])
|
|
|
|
\$[0-9a-fA-F]*
|
|
|
|
(?![\w\.])
|
|
|
|
</match>
|
|
|
|
</context>
|
|
|
|
|
2011-01-05 22:45:36 -08:00
|
|
|
<context id="pascal" class="no-spell-check">
|
2006-12-16 10:58:34 -06:00
|
|
|
<include>
|
|
|
|
<context ref="string"/>
|
|
|
|
<context ref="line-comment"/>
|
2007-11-26 00:38:51 -06:00
|
|
|
<context ref="preprocessor-defines"/>
|
2006-12-16 10:58:34 -06:00
|
|
|
<context ref="block-comment-1"/>
|
|
|
|
<context ref="block-comment-2"/>
|
|
|
|
<context ref="general-format"/>
|
|
|
|
<context ref="functions-and-function-modifiers"/>
|
|
|
|
<context ref="boolean-bitwise-operators"/>
|
|
|
|
<context ref="math-operators"/>
|
|
|
|
<context ref="loop-flow-and-exceptions-keywords"/>
|
|
|
|
<context ref="type-class-and-object-keywords"/>
|
|
|
|
<context ref="builtin-types"/>
|
|
|
|
<context ref="builtin-functions"/>
|
|
|
|
<context ref="builtin-values"/>
|
2007-05-06 08:01:49 -05:00
|
|
|
<context ref="number"/>
|
|
|
|
<context ref="hex-number"/>
|
2006-12-16 10:58:34 -06:00
|
|
|
</include>
|
|
|
|
</context>
|
2007-05-06 08:01:49 -05:00
|
|
|
|
2006-12-16 10:58:34 -06:00
|
|
|
</definitions>
|
2006-08-26 04:46:29 -05:00
|
|
|
</language>
|