[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [31131] trunk/blender/source/blender/ editors/space_text/text_draw.c: bugfix [#23211] "with" keyword in text editor not highlighted [Patch attatched

Campbell Barton ideasman42 at gmail.com
Sat Aug 7 04:13:41 CEST 2010


Revision: 31131
          http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=31131
Author:   campbellbarton
Date:     2010-08-07 04:13:39 +0200 (Sat, 07 Aug 2010)

Log Message:
-----------
bugfix [#23211] "with" keyword in text editor not highlighted [Patch attatched
by Justin Dailey (dail) with minor edit

Modified Paths:
--------------
    trunk/blender/source/blender/editors/space_text/text_draw.c

Modified: trunk/blender/source/blender/editors/space_text/text_draw.c
===================================================================
--- trunk/blender/source/blender/editors/space_text/text_draw.c	2010-08-07 01:58:26 UTC (rev 31130)
+++ trunk/blender/source/blender/editors/space_text/text_draw.c	2010-08-07 02:13:39 UTC (rev 31131)
@@ -174,12 +174,13 @@
 static int find_builtinfunc(char *string)
 {
 	int a, i;
-	char builtinfuncs[][11] = {"and", "as", "assert", "break", "class", "continue", "def",
+	char builtinfuncs[][9] = {"and", "as", "assert", "break", "class", "continue", "def",
 								"del", "elif", "else", "except", "exec", "finally",
 								"for", "from", "global", "if", "import", "in",
 								"is", "lambda", "not", "or", "pass", "print",
-								"raise", "return", "try", "while", "yield"};
-	for(a=0; a<30; a++) {
+								"raise", "return", "try", "while", "yield", "with"};
+
+	for(a=0; a < sizeof(builtinfuncs)/sizeof(builtinfuncs[0]); a++) {
 		i = 0;
 		while(1) {
 			/* If we hit the end of a keyword... (eg. "def") */





More information about the Bf-blender-cvs mailing list