[gtksourceview] Add BennuGD lang file.
- From: Ignacio Casal Quinteiro <icq src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtksourceview] Add BennuGD lang file.
- Date: Mon, 21 Jun 2010 09:01:57 +0000 (UTC)
commit ffee07ac37c92c33ce7588fb0beff8483b161588
Author: Joseba GarcÃa Etxebarria <joseba gar gmail com>
Date: Mon Jun 21 10:59:44 2010 +0200
Add BennuGD lang file.
data/language-specs/Makefile.am | 1 +
data/language-specs/bennugd.lang | 1 +
data/language-specs/testfiles.sh | 31 +++++++++++++++++++++++++++++++
3 files changed, 33 insertions(+), 0 deletions(-)
---
diff --git a/data/language-specs/Makefile.am b/data/language-specs/Makefile.am
index 64709a2..dbc2c48 100644
--- a/data/language-specs/Makefile.am
+++ b/data/language-specs/Makefile.am
@@ -4,6 +4,7 @@ LANGUAGES = \
ada.lang \
asp.lang \
awk.lang \
+ bennugd.lang \
bibtex.lang \
boo.lang \
changelog.lang \
diff --git a/data/language-specs/bennugd.lang b/data/language-specs/bennugd.lang
new file mode 100644
index 0000000..b4b9456
--- /dev/null
+++ b/data/language-specs/bennugd.lang
@@ -0,0 +1 @@
+<?xml version="1.0" encoding="UTF-8"?><!-- Authors: Oscar Torrent Artero, Joseba GarcÃa Etxebarria Copyright (C) 2009 Oscar Torrent Artero <q2dg yahoo es> Copyright (C) 2010 Joseba GarcÃa Etxebarria <joseba gar gmail com> GtkSourceView is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version. GtkSourceView 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 Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA--><language id="bennugd" _name="BennuGD" ve
rsion="2.0" _section="Sources"> <metadata> <property name="globs">*.prg</property> <property name="line-comment-start">//</property> <property name="block-comment-start">/*</property> <property name="block-comment-end">*/</property> </metadata> <styles> <style id="comment" _name="Comment" map-to="def:comment"/> <style id="error" _name="Error" map-to="def:error"/> <style id="preprocessor" _name="Preprocessor" map-to="def:preprocessor"/> <style id="identifier" _name="Identifier" map-to="def:identifier"/> <style id="operator" _name="Operator" map-to="def:operator"/> <style id="keywords" _name="Keyword" map-to="def:keyword"/> <style id="types" _name="Data Type" map-to="def:type"/> <style id="escaped-character" _name="Escaped Character" map-to="def:special-char"/> <st
yle id="floating-point" _name="Floating point number" map-to="def:floating-point"/> <style id="decimal" _name="Decimal number" map-to="def:decimal"/> <style id="hexadecimal" _name="Hexadecimal number" map-to="def:base-n-integer"/> <style id="boolean" _name="Boolean value" map-to="def:boolean"/> <style id="string" _name="String" map-to="def:string"/> <style id="char" _name="Character" map-to="def:character"/> </styles> <default-regex-options case-sensitive="false" /> <definitions> <define-regex id="symbolchar">[-!+\\|=:&><]</define-regex> <define-regex id="escaped-character" extended="true"> \\( # leading backslash [\\\"\'nrbtfav\?] | # escaped character [0-7]{1,3} | # one, two, or three octal digits x[0-9A-Fa-f]+ # 'x' followed by hex digits ) </define-regex> <!-
-Comments --> <context id="comment" style-ref="comment" end-at-line-end="true" class-disabled="no-spell-check"> <start>//</start> <include> <context ref="def:in-line-comment"/> </include> </context> <context id="comment-multiline" style-ref="comment" class-disabled="no-spell-check"> <start>/\*</start> <end>\*/</end> <include> <context ref="def:in-comment"/> </include> </context> <context id="close-comment-outside-comment" style-ref="error"> <match>\*/(?!\*)</match> </context> <!--Preprocessor --> <define-regex id="preproc-start">^\s*#\s*</define-regex> <context id="preprocessor" style-ref="preprocessor" end-at-line-end="true"> <start extended="true"> \%{preproc-start} (define|if(n?def)?|else|elsif|endif) \b </start> <include> <context ref="def:line-continue" ignore-style="true"/> <context ref="string" ignore-style="t
rue"/> <context ref="comment"/> <context ref="comment-multiline"/> </include> </context> <!-- Different data-types --> <context id="escaped-character" style-ref="escaped-character"> <match>\%{escaped-character}</match> </context> <context id="string" style-ref="string" end-at-line-end="true"> <start>L?"</start> <end>"</end> <include> <context ref="escaped-character"/> <context ref="def:line-continue"/> </include> </context> <context id="char" style-ref="char"> <match>L?'(\%{escaped-character}|.)'</match> </context> <context id="boolean" style-ref="boolean"> <keyword>false</keyword> <keyword>true</keyword> </context> <context id="float" style-ref="floating-point"> <match extended="true"> (?<![\w\.]) ([0-9]+[Ee][+-]?[0-9]+ | ([0-9]*\.[0-9]+ | [0-9]+\.[0-9]*)([Ee][+-]?[0-9]+)?) (?![\w\.])
</match> </context> <context id="decimal-number" style-ref="decimal"> <match extended="true"> (?<![\w\.]) [+-]?([1-9][0-9]*|0) (?![\w\.]) </match> </context> <context id="hexadecimal-number" style-ref="hexadecimal"> <match extended="true"> (?<![\w\.]) [+-]?0x[0-9a-fA-F]+ (?![\w\.]) </match> </context> <!--Keywords --> <context id="keywords" style-ref="keywords"> <keyword>begin</keyword> <keyword>break</keyword> <keyword>call</keyword> <keyword>case</keyword> <keyword>clone</keyword> <keyword>const</keyword> <keyword>continue</keyword> <keyword>debug</keyword> <keyword>declare</keyword> <keyword>default</keyword> <keyword>dup</keyword> <keyword>elif</keyword> <keyword>else</keyword> <keyword>elseif</keyword> <keyword>elsif</keyword> <keyword>
end</keyword> <keyword>error</keyword> <keyword>exit</keyword> <keyword>for</keyword> <keyword>frame</keyword> <keyword>from</keyword> <keyword>function</keyword> <keyword>global</keyword> <keyword>goto</keyword> <keyword>if</keyword> <keyword>import</keyword> <keyword>include</keyword> <keyword>jmp</keyword> <keyword>local</keyword> <keyword>loop</keyword> <keyword>mod</keyword> <keyword>mouse</keyword> <keyword>next</keyword> <keyword>offset</keyword> <keyword>on</keyword> <keyword>onerror</keyword> <keyword>onexit</keyword> <keyword>private</keyword> <keyword>process</keyword> <keyword>program</keyword> <keyword>public</keyword> <keyword>repeat</keyword> <keyword>resume</keyword> <keyword>return</keyword> <keyword>sizeof</keyword> <keyword>step</keyword> <keyword>switc
h</keyword> <keyword>to</keyword> <keyword>until</keyword> <keyword>while</keyword> </context> <context id="globals" style-ref="keywords"> <keyword>argc</keyword> <keyword>argv</keyword> <keyword>os_id</keyword> </context> <context id="locals" style-ref="keywords"> <keyword>bigbro</keyword> <keyword>father</keyword> <keyword>frame_percent</keyword> <keyword>id</keyword> <keyword>process_type</keyword> <keyword>reserved</keyword> <keyword>reserved.frame_percent</keyword> <keyword>reserved.process_type</keyword> <keyword>reserved.saved_priority</keyword> <keyword>reserved.saved_status</keyword> <keyword>reserved.status</keyword> <keyword>saved_priority</keyword> <keyword>saved_status</keyword> <keyword>smallbro</keyword> <keyword>status</keyword> <keyword>son</keyword> </context> <context id="operators" style-ref="op
erator" extend-parent="false"> <prefix>(?<!\%{symbolchar})</prefix> <suffix>(?!\%{symbolchar})</suffix> <keyword>==</keyword> <keyword>!=</keyword> <keyword>!</keyword> <keyword><</keyword> <keyword>></keyword> <keyword><=</keyword> <keyword>>=</keyword> <keyword>&&</keyword> <keyword>&</keyword> <keyword>=</keyword> <keyword>||</keyword> <keyword>|</keyword> <keyword>^^</keyword> <keyword>^</keyword> </context> <context id="types" style-ref="types"> <keyword>byte</keyword> <keyword>char</keyword> <keyword>dword</keyword> <keyword>float</keyword> <keyword>int</keyword> <keyword>pointer</keyword> <keyword>short</keyword> <keyword>signed</keyword> <keyword>string</keyword> <keyword>struct</keyword> <keyword>type</keyword> <keyword>unsigned</keyword> <keyword>word<
/keyword> </context> <context id="commonmacros" style-ref="preprocessor"> <keyword>COMPILER_VERSION</keyword> <keyword>__DATE__</keyword> <keyword>__FILE__</keyword> <keyword>__LINE__</keyword> <keyword>max_byte</keyword> <keyword>max_dword</keyword> <keyword>max_int</keyword> <keyword>max_sbyte</keyword> <keyword>max_short</keyword> <keyword>max_word</keyword> <keyword>min_byte</keyword> <keyword>min_dword</keyword> <keyword>min_int</keyword> <keyword>min_sbyte</keyword> <keyword>min_short</keyword> <keyword>min_word</keyword> <keyword>null</keyword> <keyword>os_beos</keyword> <keyword>os_bsd</keyword> <keyword>os_dc</keyword> <keyword>os_gp32</keyword> <keyword>os_linux</keyword> <keyword>os_macos</keyword> <keyword>os_win32</keyword> <keyword>status_dead</keyword> <keyword>status_frozen</keyword> <keyw
ord>status_killed</keyword> <keyword>status_running</keyword> <keyword>status_sleeping</keyword> <keyword>status_waiting</keyword> <keyword>__TIME__ </keyword> <keyword>__VERSION__</keyword> </context> <context id="bennugd" class="no-spell-check"> <include> <context ref="comment"/> <context ref="comment-multiline"/> <context ref="close-comment-outside-comment"/> <context ref="preprocessor"/> <context ref="string"/> <context ref="char"/> <context ref="boolean"/> <context ref="float"/> <context ref="decimal-number"/> <context ref="hexadecimal-number"/> <context ref="keywords"/> <context ref="globals"/> <context ref="locals"/> <context ref="operators"/> <context ref="types"/> <context ref="commonmacros"/> </include> </context> </definitions></language>
\ No newline at end of file
diff --git a/data/language-specs/testfiles.sh b/data/language-specs/testfiles.sh
index 3c91713..7aa4367 100755
--- a/data/language-specs/testfiles.sh
+++ b/data/language-specs/testfiles.sh
@@ -15,6 +15,37 @@
dir="testdir"
mkdir -p $dir/
+cat > $dir/file.prg << EOFEOF
+import "mod_say"
+import "mod_rand"
+import "mod_screen"
+import "mod_video"
+import "mod_map"
+import "mod_key"
+
+// Bouncing box example
+process main()
+private
+ int vx=5, vy=5;
+
+begin
+ set_mode(640, 480, 16, MODE_WINDOW);
+ graph = map_new(20, 20, 16);
+ map_clear(0, graph, rgb(255, 0, 0));
+ x = 320; y = 240;
+ while(! key(_esc))
+ if(x > 630 || x < 10)
+ vx = -vx;
+ end;
+ if(y > 470 || y < 10)
+ vy = -vy;
+ end;
+ x += vx; y += vy; // Move the box
+ frame;
+ end;
+end;
+EOFEOF
+
cat > $dir/file.ooc << EOFEOF
import structs/[ArrayList, LinkedList], io/FileReader
include stdarg, memory, string
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]