diff -u -r -N scite-1.62-clean/scintilla/gtk/makefile scite-1.62/scintilla/gtk/makefile
--- scite-1.62-clean/scintilla/gtk/makefile	2004-10-15 19:41:26.000000000 -0400
+++ scite-1.62/scintilla/gtk/makefile	2005-03-17 23:15:43.033931515 -0500
@@ -63,13 +63,13 @@
 #++Autogenerated -- run src/LexGen.py to regenerate
 #**LEXOBJS=\\\n\(\*.o \)
 LEXOBJS=\
-LexAda.o LexAPDL.o LexAsm.o LexAsn1.o LexAU3.o LexAVE.o LexBaan.o LexBash.o \
-LexBullant.o LexCLW.o LexConf.o LexCPP.o LexCrontab.o LexCSS.o LexEiffel.o \
-LexErlang.o LexEScript.o LexForth.o LexFortran.o LexGui4Cli.o LexHTML.o \
-LexKix.o LexLisp.o LexLout.o LexLua.o LexMatlab.o LexMetapost.o LexMMIXAL.o \
-LexMPT.o LexMSSQL.o LexNsis.o LexOthers.o LexPascal.o LexPB.o LexPerl.o \
-LexPOV.o LexPS.o LexPython.o LexRuby.o LexScriptol.o LexSpecman.o LexSQL.o \
-LexTeX.o LexVB.o LexVerilog.o LexVHDL.o LexYAML.o
+LexAPDL.o LexAU3.o LexAVE.o LexAda.o LexAsm.o LexAsn1.o LexBaan.o LexBash.o \
+LexBullant.o LexCLW.o LexCPP.o LexCSS.o LexConf.o LexCrontab.o LexEScript.o \
+LexEiffel.o LexErlang.o LexForth.o LexFortran.o LexGui4Cli.o LexHTML.o \
+LexKix.o LexLisp.o LexLout.o LexLua.o LexMMIXAL.o LexMPT.o LexMSSQL.o \
+LexMatlab.o LexMetapost.o LexNsis.o LexOthers.o LexPB.o LexPOV.o LexPS.o \
+LexPascal.o LexPerl.o LexPython.o LexRuby.o LexSQL.o LexScriptol.o \
+LexSpecman.o LexTeX.o LexVB.o LexVHDL.o LexVerilog.o LexYAML.o LexRenpy.o
 #--Autogenerated -- end of automatically generated section
 
 all: $(COMPLIB)
diff -u -r -N scite-1.62-clean/scintilla/gtk/scintilla.mak scite-1.62/scintilla/gtk/scintilla.mak
--- scite-1.62-clean/scintilla/gtk/scintilla.mak	2004-10-15 19:41:26.000000000 -0400
+++ scite-1.62/scintilla/gtk/scintilla.mak	2005-03-17 23:15:43.061924917 -0500
@@ -139,23 +139,23 @@
 #++Autogenerated -- run src/LexGen.py to regenerate
 #**LEXOBJS=\\\n\(\t$(DIR_O)\\\*.obj \\\n\)
 LEXOBJS=\
-	$(DIR_O)\LexAda.obj \
 	$(DIR_O)\LexAPDL.obj \
-	$(DIR_O)\LexAsm.obj \
-	$(DIR_O)\LexAsn1.obj \
 	$(DIR_O)\LexAU3.obj \
 	$(DIR_O)\LexAVE.obj \
+	$(DIR_O)\LexAda.obj \
+	$(DIR_O)\LexAsm.obj \
+	$(DIR_O)\LexAsn1.obj \
 	$(DIR_O)\LexBaan.obj \
 	$(DIR_O)\LexBash.obj \
 	$(DIR_O)\LexBullant.obj \
 	$(DIR_O)\LexCLW.obj \
-	$(DIR_O)\LexConf.obj \
 	$(DIR_O)\LexCPP.obj \
-	$(DIR_O)\LexCrontab.obj \
 	$(DIR_O)\LexCSS.obj \
+	$(DIR_O)\LexConf.obj \
+	$(DIR_O)\LexCrontab.obj \
+	$(DIR_O)\LexEScript.obj \
 	$(DIR_O)\LexEiffel.obj \
 	$(DIR_O)\LexErlang.obj \
-	$(DIR_O)\LexEScript.obj \
 	$(DIR_O)\LexForth.obj \
 	$(DIR_O)\LexFortran.obj \
 	$(DIR_O)\LexGui4Cli.obj \
@@ -164,28 +164,29 @@
 	$(DIR_O)\LexLisp.obj \
 	$(DIR_O)\LexLout.obj \
 	$(DIR_O)\LexLua.obj \
-	$(DIR_O)\LexMatlab.obj \
-	$(DIR_O)\LexMetapost.obj \
 	$(DIR_O)\LexMMIXAL.obj \
 	$(DIR_O)\LexMPT.obj \
 	$(DIR_O)\LexMSSQL.obj \
+	$(DIR_O)\LexMatlab.obj \
+	$(DIR_O)\LexMetapost.obj \
 	$(DIR_O)\LexNsis.obj \
 	$(DIR_O)\LexOthers.obj \
-	$(DIR_O)\LexPascal.obj \
 	$(DIR_O)\LexPB.obj \
-	$(DIR_O)\LexPerl.obj \
 	$(DIR_O)\LexPOV.obj \
 	$(DIR_O)\LexPS.obj \
+	$(DIR_O)\LexPascal.obj \
+	$(DIR_O)\LexPerl.obj \
 	$(DIR_O)\LexPython.obj \
 	$(DIR_O)\LexRuby.obj \
+	$(DIR_O)\LexSQL.obj \
 	$(DIR_O)\LexScriptol.obj \
 	$(DIR_O)\LexSpecman.obj \
-	$(DIR_O)\LexSQL.obj \
 	$(DIR_O)\LexTeX.obj \
 	$(DIR_O)\LexVB.obj \
-	$(DIR_O)\LexVerilog.obj \
 	$(DIR_O)\LexVHDL.obj \
+	$(DIR_O)\LexVerilog.obj \
 	$(DIR_O)\LexYAML.obj \
+	$(DIR_O)\LexRenpy.obj \
 
 #--Autogenerated -- end of automatically generated section
 
@@ -302,18 +303,18 @@
 #++Autogenerated -- run src/LexGen.py to regenerate
 #**\n\($(DIR_O)\\\*.obj: ..\\src\\\*.cxx $(LEX_HEADERS)\n\n\)
 
-$(DIR_O)\LexAda.obj: ..\src\LexAda.cxx $(LEX_HEADERS)
-
 $(DIR_O)\LexAPDL.obj: ..\src\LexAPDL.cxx $(LEX_HEADERS)
 
-$(DIR_O)\LexAsm.obj: ..\src\LexAsm.cxx $(LEX_HEADERS)
-
-$(DIR_O)\LexAsn1.obj: ..\src\LexAsn1.cxx $(LEX_HEADERS)
-
 $(DIR_O)\LexAU3.obj: ..\src\LexAU3.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexAVE.obj: ..\src\LexAVE.cxx $(LEX_HEADERS)
 
+$(DIR_O)\LexAda.obj: ..\src\LexAda.cxx $(LEX_HEADERS)
+
+$(DIR_O)\LexAsm.obj: ..\src\LexAsm.cxx $(LEX_HEADERS)
+
+$(DIR_O)\LexAsn1.obj: ..\src\LexAsn1.cxx $(LEX_HEADERS)
+
 $(DIR_O)\LexBaan.obj: ..\src\LexBaan.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexBash.obj: ..\src\LexBash.cxx $(LEX_HEADERS)
@@ -322,20 +323,20 @@
 
 $(DIR_O)\LexCLW.obj: ..\src\LexCLW.cxx $(LEX_HEADERS)
 
-$(DIR_O)\LexConf.obj: ..\src\LexConf.cxx $(LEX_HEADERS)
-
 $(DIR_O)\LexCPP.obj: ..\src\LexCPP.cxx $(LEX_HEADERS)
 
+$(DIR_O)\LexCSS.obj: ..\src\LexCSS.cxx $(LEX_HEADERS)
+
+$(DIR_O)\LexConf.obj: ..\src\LexConf.cxx $(LEX_HEADERS)
+
 $(DIR_O)\LexCrontab.obj: ..\src\LexCrontab.cxx $(LEX_HEADERS)
 
-$(DIR_O)\LexCSS.obj: ..\src\LexCSS.cxx $(LEX_HEADERS)
+$(DIR_O)\LexEScript.obj: ..\src\LexEScript.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexEiffel.obj: ..\src\LexEiffel.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexErlang.obj: ..\src\LexErlang.cxx $(LEX_HEADERS)
 
-$(DIR_O)\LexEScript.obj: ..\src\LexEScript.cxx $(LEX_HEADERS)
-
 $(DIR_O)\LexForth.obj: ..\src\LexForth.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexFortran.obj: ..\src\LexFortran.cxx $(LEX_HEADERS)
@@ -352,50 +353,52 @@
 
 $(DIR_O)\LexLua.obj: ..\src\LexLua.cxx $(LEX_HEADERS)
 
-$(DIR_O)\LexMatlab.obj: ..\src\LexMatlab.cxx $(LEX_HEADERS)
-
-$(DIR_O)\LexMetapost.obj: ..\src\LexMetapost.cxx $(LEX_HEADERS)
-
 $(DIR_O)\LexMMIXAL.obj: ..\src\LexMMIXAL.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexMPT.obj: ..\src\LexMPT.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexMSSQL.obj: ..\src\LexMSSQL.cxx $(LEX_HEADERS)
 
+$(DIR_O)\LexMatlab.obj: ..\src\LexMatlab.cxx $(LEX_HEADERS)
+
+$(DIR_O)\LexMetapost.obj: ..\src\LexMetapost.cxx $(LEX_HEADERS)
+
 $(DIR_O)\LexNsis.obj: ..\src\LexNsis.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexOthers.obj: ..\src\LexOthers.cxx $(LEX_HEADERS)
 
-$(DIR_O)\LexPascal.obj: ..\src\LexPascal.cxx $(LEX_HEADERS)
-
 $(DIR_O)\LexPB.obj: ..\src\LexPB.cxx $(LEX_HEADERS)
 
-$(DIR_O)\LexPerl.obj: ..\src\LexPerl.cxx $(LEX_HEADERS)
-
 $(DIR_O)\LexPOV.obj: ..\src\LexPOV.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexPS.obj: ..\src\LexPS.cxx $(LEX_HEADERS)
 
+$(DIR_O)\LexPascal.obj: ..\src\LexPascal.cxx $(LEX_HEADERS)
+
+$(DIR_O)\LexPerl.obj: ..\src\LexPerl.cxx $(LEX_HEADERS)
+
 $(DIR_O)\LexPython.obj: ..\src\LexPython.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexRuby.obj: ..\src\LexRuby.cxx $(LEX_HEADERS)
 
+$(DIR_O)\LexSQL.obj: ..\src\LexSQL.cxx $(LEX_HEADERS)
+
 $(DIR_O)\LexScriptol.obj: ..\src\LexScriptol.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexSpecman.obj: ..\src\LexSpecman.cxx $(LEX_HEADERS)
 
-$(DIR_O)\LexSQL.obj: ..\src\LexSQL.cxx $(LEX_HEADERS)
-
 $(DIR_O)\LexTeX.obj: ..\src\LexTeX.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexVB.obj: ..\src\LexVB.cxx $(LEX_HEADERS)
 
-$(DIR_O)\LexVerilog.obj: ..\src\LexVerilog.cxx $(LEX_HEADERS)
-
 $(DIR_O)\LexVHDL.obj: ..\src\LexVHDL.cxx $(LEX_HEADERS)
 
+$(DIR_O)\LexVerilog.obj: ..\src\LexVerilog.cxx $(LEX_HEADERS)
+
 $(DIR_O)\LexYAML.obj: ..\src\LexYAML.cxx $(LEX_HEADERS)
 
+$(DIR_O)\LexRenpy.obj: ..\src\LexRenpy.cxx $(LEX_HEADERS)
+
 
 #--Autogenerated -- end of automatically generated section
 
diff -u -r -N scite-1.62-clean/scintilla/src/KeyWords.cxx scite-1.62/scintilla/src/KeyWords.cxx
--- scite-1.62-clean/scintilla/src/KeyWords.cxx	2004-10-31 02:12:52.000000000 -0500
+++ scite-1.62/scintilla/src/KeyWords.cxx	2005-03-17 23:28:26.892889344 -0500
@@ -1,199 +1,200 @@
-// Scintilla source code edit control
-/** @file KeyWords.cxx
- ** Colourise for particular languages.
- **/
-// Copyright 1998-2002 by Neil Hodgson <neilh@scintilla.org>
-// The License.txt file describes the conditions under which this software may be distributed.
-
-#include <stdlib.h>
-#include <string.h>
-#include <ctype.h>
-#include <stdio.h>
-#include <stdarg.h>
-
-#include "Platform.h"
-
-#include "PropSet.h"
-#include "Accessor.h"
-#include "KeyWords.h"
-#include "Scintilla.h"
-#include "SciLexer.h"
-
-const LexerModule *LexerModule::base = 0;
-int LexerModule::nextLanguage = SCLEX_AUTOMATIC+1;
-
-LexerModule::LexerModule(int language_, LexerFunction fnLexer_,
-	const char *languageName_, LexerFunction fnFolder_,
-	const char * const wordListDescriptions_[]) :
-	language(language_),
-	fnLexer(fnLexer_),
-	fnFolder(fnFolder_),
-	wordListDescriptions(wordListDescriptions_),
-	languageName(languageName_) {
-	next = base;
-	base = this;
-	if (language == SCLEX_AUTOMATIC) {
-		language = nextLanguage;
-		nextLanguage++;
-	}
-}
-
-int LexerModule::GetNumWordLists() const {
-	if (wordListDescriptions == NULL) {
-		return -1;
-	} else {
-		int numWordLists = 0;
-
-		while (wordListDescriptions[numWordLists]) {
-			++numWordLists;
-		}
-
-		return numWordLists;
-	}
-}
-
-const char * LexerModule::GetWordListDescription(int index) const {
-	static const char *emptyStr = "";
-
-	PLATFORM_ASSERT(index < GetNumWordLists());
-	if (index >= GetNumWordLists()) {
-		return emptyStr;
-	} else {
-		return wordListDescriptions[index];
- 	}
-}
-
-const LexerModule *LexerModule::Find(int language) {
-	const LexerModule *lm = base;
-	while (lm) {
-		if (lm->language == language) {
-			return lm;
-		}
-		lm = lm->next;
-	}
-	return 0;
-}
-
-const LexerModule *LexerModule::Find(const char *languageName) {
-	if (languageName) {
-		const LexerModule *lm = base;
-		while (lm) {
-			if (lm->languageName && 0 == strcmp(lm->languageName, languageName)) {
-				return lm;
-			}
-			lm = lm->next;
-		}
-	}
-	return 0;
-}
-
-void LexerModule::Lex(unsigned int startPos, int lengthDoc, int initStyle,
-	  WordList *keywordlists[], Accessor &styler) const {
-	if (fnLexer)
-		fnLexer(startPos, lengthDoc, initStyle, keywordlists, styler);
-}
-
-void LexerModule::Fold(unsigned int startPos, int lengthDoc, int initStyle,
-	  WordList *keywordlists[], Accessor &styler) const {
-	if (fnFolder) {
-		int lineCurrent = styler.GetLine(startPos);
-		// Move back one line in case deletion wrecked current line fold state
-		if (lineCurrent > 0) {
-			lineCurrent--;
-			int newStartPos = styler.LineStart(lineCurrent);
-			lengthDoc += startPos - newStartPos;
-			startPos = newStartPos;
-			initStyle = 0;
-			if (startPos > 0) {
-				initStyle = styler.StyleAt(startPos - 1);
-			}
-		}
-		fnFolder(startPos, lengthDoc, initStyle, keywordlists, styler);
-	}
-}
-
-// Alternative historical name for Scintilla_LinkLexers
-int wxForceScintillaLexers(void) {
-	return Scintilla_LinkLexers();
-}
-
-// To add or remove a lexer, add or remove its file and run LexGen.py.
-
-// Force a reference to all of the Scintilla lexers so that the linker will
-// not remove the code of the lexers.
-int Scintilla_LinkLexers() {
-	static int forcer = 0;
-
-// Shorten the code that declares a lexer and ensures it is linked in by calling a method.
-#define LINK_LEXER(lexer) extern LexerModule lexer; forcer += lexer.GetLanguage();
-
-//++Autogenerated -- run src/LexGen.py to regenerate
-//**\(\tLINK_LEXER(\*);\n\)
-	LINK_LEXER(lmAda);
-	LINK_LEXER(lmAPDL);
-	LINK_LEXER(lmAsm);
-	LINK_LEXER(lmAns1);
-	LINK_LEXER(lmAU3);
-	LINK_LEXER(lmAVE);
-	LINK_LEXER(lmBaan);
-	LINK_LEXER(lmBash);
-	LINK_LEXER(lmBullant);
-	LINK_LEXER(lmClw);
-	LINK_LEXER(lmClwNoCase);
-	LINK_LEXER(lmConf);
-	LINK_LEXER(lmCPP);
-	LINK_LEXER(lmCPPNoCase);
-	LINK_LEXER(lmTCL);
-	LINK_LEXER(lmNncrontab);
-	LINK_LEXER(lmCss);
-	LINK_LEXER(lmEiffel);
-	LINK_LEXER(lmEiffelkw);
-	LINK_LEXER(lmErlang);
-	LINK_LEXER(lmESCRIPT);
-	LINK_LEXER(lmForth);
-	LINK_LEXER(lmFortran);
-	LINK_LEXER(lmF77);
-	LINK_LEXER(lmGui4Cli);
-	LINK_LEXER(lmHTML);
-	LINK_LEXER(lmXML);
-	LINK_LEXER(lmASP);
-	LINK_LEXER(lmPHP);
-	LINK_LEXER(lmKix);
-	LINK_LEXER(lmLISP);
-	LINK_LEXER(lmLout);
-	LINK_LEXER(lmLua);
-	LINK_LEXER(lmMatlab);
-	LINK_LEXER(lmOctave);
-	LINK_LEXER(lmMETAPOST);
-	LINK_LEXER(lmMMIXAL);
-	LINK_LEXER(lmLot);
-	LINK_LEXER(lmMSSQL);
-	LINK_LEXER(lmNsis);
-	LINK_LEXER(lmBatch);
-	LINK_LEXER(lmDiff);
-	LINK_LEXER(lmProps);
-	LINK_LEXER(lmMake);
-	LINK_LEXER(lmErrorList);
-	LINK_LEXER(lmLatex);
-	LINK_LEXER(lmNull);
-	LINK_LEXER(lmPascal);
-	LINK_LEXER(lmPB);
-	LINK_LEXER(lmPerl);
-	LINK_LEXER(lmPOV);
-	LINK_LEXER(lmPS);
-	LINK_LEXER(lmPython);
-	LINK_LEXER(lmRuby);
-	LINK_LEXER(lmScriptol);
-	LINK_LEXER(lmSpecman);
-	LINK_LEXER(lmSQL);
-	LINK_LEXER(lmTeX);
-	LINK_LEXER(lmVB);
-	LINK_LEXER(lmVBScript);
-	LINK_LEXER(lmVerilog);
-	LINK_LEXER(lmVHDL);
-	LINK_LEXER(lmYAML);
-
-//--Autogenerated -- end of automatically generated section
-
-	return 1;
-}
+// Scintilla source code edit control
+/** @file KeyWords.cxx
+ ** Colourise for particular languages.
+ **/
+// Copyright 1998-2002 by Neil Hodgson <neilh@scintilla.org>
+// The License.txt file describes the conditions under which this software may be distributed.
+
+#include <stdlib.h>
+#include <string.h>
+#include <ctype.h>
+#include <stdio.h>
+#include <stdarg.h>
+
+#include "Platform.h"
+
+#include "PropSet.h"
+#include "Accessor.h"
+#include "KeyWords.h"
+#include "Scintilla.h"
+#include "SciLexer.h"
+
+const LexerModule *LexerModule::base = 0;
+int LexerModule::nextLanguage = SCLEX_AUTOMATIC+1;
+
+LexerModule::LexerModule(int language_, LexerFunction fnLexer_,
+	const char *languageName_, LexerFunction fnFolder_,
+	const char * const wordListDescriptions_[]) :
+	language(language_),
+	fnLexer(fnLexer_),
+	fnFolder(fnFolder_),
+	wordListDescriptions(wordListDescriptions_),
+	languageName(languageName_) {
+	next = base;
+	base = this;
+	if (language == SCLEX_AUTOMATIC) {
+		language = nextLanguage;
+		nextLanguage++;
+	}
+}
+
+int LexerModule::GetNumWordLists() const {
+	if (wordListDescriptions == NULL) {
+		return -1;
+	} else {
+		int numWordLists = 0;
+
+		while (wordListDescriptions[numWordLists]) {
+			++numWordLists;
+		}
+
+		return numWordLists;
+	}
+}
+
+const char * LexerModule::GetWordListDescription(int index) const {
+	static const char *emptyStr = "";
+
+	PLATFORM_ASSERT(index < GetNumWordLists());
+	if (index >= GetNumWordLists()) {
+		return emptyStr;
+	} else {
+		return wordListDescriptions[index];
+ 	}
+}
+
+const LexerModule *LexerModule::Find(int language) {
+	const LexerModule *lm = base;
+	while (lm) {
+		if (lm->language == language) {
+			return lm;
+		}
+		lm = lm->next;
+	}
+	return 0;
+}
+
+const LexerModule *LexerModule::Find(const char *languageName) {
+	if (languageName) {
+		const LexerModule *lm = base;
+		while (lm) {
+			if (lm->languageName && 0 == strcmp(lm->languageName, languageName)) {
+				return lm;
+			}
+			lm = lm->next;
+		}
+	}
+	return 0;
+}
+
+void LexerModule::Lex(unsigned int startPos, int lengthDoc, int initStyle,
+	  WordList *keywordlists[], Accessor &styler) const {
+	if (fnLexer)
+		fnLexer(startPos, lengthDoc, initStyle, keywordlists, styler);
+}
+
+void LexerModule::Fold(unsigned int startPos, int lengthDoc, int initStyle,
+	  WordList *keywordlists[], Accessor &styler) const {
+	if (fnFolder) {
+		int lineCurrent = styler.GetLine(startPos);
+		// Move back one line in case deletion wrecked current line fold state
+		if (lineCurrent > 0) {
+			lineCurrent--;
+			int newStartPos = styler.LineStart(lineCurrent);
+			lengthDoc += startPos - newStartPos;
+			startPos = newStartPos;
+			initStyle = 0;
+			if (startPos > 0) {
+				initStyle = styler.StyleAt(startPos - 1);
+			}
+		}
+		fnFolder(startPos, lengthDoc, initStyle, keywordlists, styler);
+	}
+}
+
+// Alternative historical name for Scintilla_LinkLexers
+int wxForceScintillaLexers(void) {
+	return Scintilla_LinkLexers();
+}
+
+// To add or remove a lexer, add or remove its file and run LexGen.py.
+
+// Force a reference to all of the Scintilla lexers so that the linker will
+// not remove the code of the lexers.
+int Scintilla_LinkLexers() {
+	static int forcer = 0;
+
+// Shorten the code that declares a lexer and ensures it is linked in by calling a method.
+#define LINK_LEXER(lexer) extern LexerModule lexer; forcer += lexer.GetLanguage();
+
+//++Autogenerated -- run src/LexGen.py to regenerate
+//**\(\tLINK_LEXER(\*);\n\)
+	LINK_LEXER(lmAPDL);
+	LINK_LEXER(lmAU3);
+	LINK_LEXER(lmAVE);
+	LINK_LEXER(lmAda);
+	LINK_LEXER(lmAsm);
+	LINK_LEXER(lmAns1);
+	LINK_LEXER(lmBaan);
+	LINK_LEXER(lmBash);
+	LINK_LEXER(lmBullant);
+	LINK_LEXER(lmClw);
+	LINK_LEXER(lmClwNoCase);
+	LINK_LEXER(lmCPP);
+	LINK_LEXER(lmCPPNoCase);
+	LINK_LEXER(lmTCL);
+	LINK_LEXER(lmCss);
+	LINK_LEXER(lmConf);
+	LINK_LEXER(lmNncrontab);
+	LINK_LEXER(lmESCRIPT);
+	LINK_LEXER(lmEiffel);
+	LINK_LEXER(lmEiffelkw);
+	LINK_LEXER(lmErlang);
+	LINK_LEXER(lmForth);
+	LINK_LEXER(lmFortran);
+	LINK_LEXER(lmF77);
+	LINK_LEXER(lmGui4Cli);
+	LINK_LEXER(lmHTML);
+	LINK_LEXER(lmXML);
+	LINK_LEXER(lmASP);
+	LINK_LEXER(lmPHP);
+	LINK_LEXER(lmKix);
+	LINK_LEXER(lmLISP);
+	LINK_LEXER(lmLout);
+	LINK_LEXER(lmLua);
+	LINK_LEXER(lmMMIXAL);
+	LINK_LEXER(lmLot);
+	LINK_LEXER(lmMSSQL);
+	LINK_LEXER(lmMatlab);
+	LINK_LEXER(lmOctave);
+	LINK_LEXER(lmMETAPOST);
+	LINK_LEXER(lmNsis);
+	LINK_LEXER(lmBatch);
+	LINK_LEXER(lmDiff);
+	LINK_LEXER(lmProps);
+	LINK_LEXER(lmMake);
+	LINK_LEXER(lmErrorList);
+	LINK_LEXER(lmLatex);
+	LINK_LEXER(lmNull);
+	LINK_LEXER(lmPB);
+	LINK_LEXER(lmPOV);
+	LINK_LEXER(lmPS);
+	LINK_LEXER(lmPascal);
+	LINK_LEXER(lmPerl);
+	LINK_LEXER(lmPython);
+	LINK_LEXER(lmRuby);
+	LINK_LEXER(lmSQL);
+	LINK_LEXER(lmScriptol);
+	LINK_LEXER(lmSpecman);
+	LINK_LEXER(lmTeX);
+	LINK_LEXER(lmVB);
+	LINK_LEXER(lmVBScript);
+	LINK_LEXER(lmVHDL);
+	LINK_LEXER(lmVerilog);
+	LINK_LEXER(lmYAML);
+	LINK_LEXER(lmRenpy);
+
+//--Autogenerated -- end of automatically generated section
+
+	return 1;
+}
diff -u -r -N scite-1.62-clean/scintilla/src/LexRenpy.cxx scite-1.62/scintilla/src/LexRenpy.cxx
--- scite-1.62-clean/scintilla/src/LexRenpy.cxx	1969-12-31 19:00:00.000000000 -0500
+++ scite-1.62/scintilla/src/LexRenpy.cxx	2005-03-17 23:35:50.620302435 -0500
@@ -0,0 +1,442 @@
+// Scintilla source code edit control
+/** @file LexPython.cxx
+ ** Lexer for Python.
+ **/
+// Copyright 1998-2002 by Neil Hodgson <neilh@scintilla.org>
+// The License.txt file describes the conditions under which this software may be distributed.
+
+#include <stdlib.h>
+#include <string.h>
+#include <ctype.h>
+#include <stdio.h>
+#include <stdarg.h>
+
+#include "Platform.h"
+
+#include "PropSet.h"
+#include "Accessor.h"
+#include "StyleContext.h"
+#include "KeyWords.h"
+#include "Scintilla.h"
+#include "SciLexer.h"
+
+enum kwType { kwOther, kwClass, kwDef, kwImport };
+
+static bool IsPyComment(Accessor &styler, int pos, int len) {
+	return len > 0 && styler[pos] == '#';
+}
+
+static bool IsPyStringStart(int ch, int chNext, int chNext2) {
+	if (ch == '\'' || ch == '"')
+		return true;
+	if (ch == 'u' || ch == 'U') {
+		if (chNext == '"' || chNext == '\'')
+			return true;
+		if ((chNext == 'r' || chNext == 'R') && (chNext2 == '"' || chNext2 == '\''))
+			return true;
+	}
+	if ((ch == 'r' || ch == 'R') && (chNext == '"' || chNext == '\''))
+		return true;
+
+	return false;
+}
+
+/* Return the state to use for the string starting at i; *nextIndex will be set to the first index following the quote(s) */
+static int GetPyStringState(Accessor &styler, int i, unsigned int *nextIndex) {
+	char ch = styler.SafeGetCharAt(i);
+	char chNext = styler.SafeGetCharAt(i + 1);
+
+	// Advance beyond r, u, or ur prefix, but bail if there are any unexpected chars
+	if (ch == 'r' || ch == 'R') {
+		i++;
+		ch = styler.SafeGetCharAt(i);
+		chNext = styler.SafeGetCharAt(i + 1);
+	} else if (ch == 'u' || ch == 'U') {
+		if (chNext == 'r' || chNext == 'R')
+			i += 2;
+		else
+			i += 1;
+		ch = styler.SafeGetCharAt(i);
+		chNext = styler.SafeGetCharAt(i + 1);
+	}
+
+	if (ch != '"' && ch != '\'') {
+		*nextIndex = i + 1;
+		return SCE_P_DEFAULT;
+	}
+
+	if (ch == chNext && ch == styler.SafeGetCharAt(i + 2)) {
+		*nextIndex = i + 3;
+
+		if (ch == '"')
+			return SCE_P_TRIPLEDOUBLE;
+		else
+			return SCE_P_TRIPLE;
+	} else {
+		*nextIndex = i + 1;
+
+		if (ch == '"')
+			return SCE_P_STRING;
+		else
+			return SCE_P_CHARACTER;
+	}
+}
+
+static inline bool IsAWordChar(int ch) {
+	return (ch < 0x80) && (isalnum(ch) || ch == '.' || ch == '_');
+}
+
+static inline bool IsAWordStart(int ch) {
+	return (ch < 0x80) && (isalnum(ch) || ch == '_');
+}
+
+static void ColourisePyDoc(unsigned int startPos, int length, int initStyle,
+                           WordList *keywordlists[], Accessor &styler) {
+
+	int endPos = startPos + length;
+
+	// Backtrack to previous line in case need to fix its tab whinging
+	int lineCurrent = styler.GetLine(startPos);
+	if (startPos > 0) {
+		if (lineCurrent > 0) {
+			lineCurrent--;
+			startPos = styler.LineStart(lineCurrent);
+			if (startPos == 0)
+				initStyle = SCE_P_DEFAULT;
+			else
+				initStyle = styler.StyleAt(startPos - 1);
+		}
+	}
+
+	WordList &keywords = *keywordlists[0];
+
+	const int whingeLevel = styler.GetPropertyInt("tab.timmy.whinge.level");
+
+	initStyle = initStyle & 31;
+	if (initStyle == SCE_P_STRINGEOL) {
+		initStyle = SCE_P_DEFAULT;
+	}
+
+	kwType kwLast = kwOther;
+	int spaceFlags = 0;
+	styler.IndentAmount(lineCurrent, &spaceFlags, IsPyComment);
+	bool hexadecimal = false;
+
+	// Python uses a different mask because bad indentation is marked by oring with 32
+	StyleContext sc(startPos, endPos - startPos, initStyle, styler, 0x7f);
+
+	for (; sc.More(); sc.Forward()) {
+
+		if (sc.atLineStart) {
+			const char chBad = static_cast<char>(64);
+			const char chGood = static_cast<char>(0);
+			char chFlags = chGood;
+			if (whingeLevel == 1) {
+				chFlags = (spaceFlags & wsInconsistent) ? chBad : chGood;
+			} else if (whingeLevel == 2) {
+				chFlags = (spaceFlags & wsSpaceTab) ? chBad : chGood;
+			} else if (whingeLevel == 3) {
+				chFlags = (spaceFlags & wsSpace) ? chBad : chGood;
+			} else if (whingeLevel == 4) {
+				chFlags = (spaceFlags & wsTab) ? chBad : chGood;
+			}
+			sc.SetState(sc.state);
+			styler.SetFlags(chFlags, static_cast<char>(sc.state));
+		}
+
+		if (sc.atLineEnd) {
+			if ((sc.state == SCE_P_DEFAULT) ||
+                            (sc.state == SCE_P_TRIPLE) ||
+                            (sc.state == SCE_P_TRIPLEDOUBLE) ||
+                            (sc.state == SCE_P_STRING) ||
+                            (sc.state == SCE_P_CHARACTER)
+                            ) {
+				// Perform colourisation of white space and triple quoted strings at end of each line to allow
+				// tab marking to work inside white space and triple quoted strings
+				sc.SetState(sc.state);
+			}
+			lineCurrent++;
+			styler.IndentAmount(lineCurrent, &spaceFlags, IsPyComment);
+			// if ((sc.state == SCE_P_STRING) || (sc.state == SCE_P_CHARACTER)) {
+			//	sc.ChangeState(SCE_P_STRINGEOL);
+			//	sc.ForwardSetState(SCE_P_DEFAULT);
+			// }
+			if (!sc.More())
+				break;
+		}
+
+		bool needEOLCheck = false;
+
+		// Check for a state end
+		if (sc.state == SCE_P_OPERATOR) {
+			kwLast = kwOther;
+			sc.SetState(SCE_P_DEFAULT);
+		} else if (sc.state == SCE_P_NUMBER) {
+			if (!IsAWordChar(sc.ch) &&
+			        !(!hexadecimal && ((sc.ch == '+' || sc.ch == '-') && (sc.chPrev == 'e' || sc.chPrev == 'E')))) {
+				sc.SetState(SCE_P_DEFAULT);
+			}
+		} else if (sc.state == SCE_P_IDENTIFIER) {
+			if ((sc.ch == '.') || (!IsAWordChar(sc.ch))) {
+				char s[100];
+				sc.GetCurrent(s, sizeof(s));
+				int style = SCE_P_IDENTIFIER;
+				if ((kwLast == kwImport) && (strcmp(s, "as") == 0)) {
+					style = SCE_P_WORD;
+				} else if (keywords.InList(s)) {
+					style = SCE_P_WORD;
+				} else if (kwLast == kwClass) {
+					style = SCE_P_CLASSNAME;
+				} else if (kwLast == kwDef) {
+					style = SCE_P_DEFNAME;
+				}
+				sc.ChangeState(style);
+				sc.SetState(SCE_P_DEFAULT);
+				if (style == SCE_P_WORD) {
+					if (0 == strcmp(s, "class"))
+						kwLast = kwClass;
+					else if (0 == strcmp(s, "def"))
+						kwLast = kwDef;
+					else if (0 == strcmp(s, "import"))
+						kwLast = kwImport;
+					else
+						kwLast = kwOther;
+				} else if (style == SCE_P_CLASSNAME) {
+					kwLast = kwOther;
+				} else if (style == SCE_P_DEFNAME) {
+					kwLast = kwOther;
+				}
+			}
+		} else if ((sc.state == SCE_P_COMMENTLINE) || (sc.state == SCE_P_COMMENTBLOCK)) {
+			if (sc.ch == '\r' || sc.ch == '\n') {
+				sc.SetState(SCE_P_DEFAULT);
+			}
+		} else if ((sc.state == SCE_P_STRING) || (sc.state == SCE_P_CHARACTER)) {
+			if (sc.ch == '\\') {
+				if ((sc.chNext == '\r') && (sc.GetRelative(2) == '\n')) {
+					sc.Forward();
+				}
+				sc.Forward();
+			} else if ((sc.state == SCE_P_STRING) && (sc.ch == '\"')) {
+				sc.ForwardSetState(SCE_P_DEFAULT);
+				needEOLCheck = true;
+			} else if ((sc.state == SCE_P_CHARACTER) && (sc.ch == '\'')) {
+				sc.ForwardSetState(SCE_P_DEFAULT);
+				needEOLCheck = true;
+			}
+		} else if (sc.state == SCE_P_TRIPLE) {
+			if (sc.ch == '\\') {
+				sc.Forward();
+			} else if (sc.Match("\'\'\'")) {
+				sc.Forward();
+				sc.Forward();
+				sc.ForwardSetState(SCE_P_DEFAULT);
+				needEOLCheck = true;
+			}
+		} else if (sc.state == SCE_P_TRIPLEDOUBLE) {
+			if (sc.ch == '\\') {
+				sc.Forward();
+			} else if (sc.Match("\"\"\"")) {
+				sc.Forward();
+				sc.Forward();
+				sc.ForwardSetState(SCE_P_DEFAULT);
+				needEOLCheck = true;
+			}
+		}
+
+		// State exit code may have moved on to end of line
+		if (needEOLCheck && sc.atLineEnd) {
+			lineCurrent++;
+			styler.IndentAmount(lineCurrent, &spaceFlags, IsPyComment);
+			if (!sc.More())
+				break;
+		}
+
+		// Check for a new state starting character
+		if (sc.state == SCE_P_DEFAULT) {
+			if (IsADigit(sc.ch) || (sc.ch == '.' && IsADigit(sc.chNext))) {
+				if (sc.ch == '0' && (sc.chNext == 'x' || sc.chNext == 'X')) {
+					hexadecimal = true;
+				} else {
+					hexadecimal = false;
+				}
+				sc.SetState(SCE_P_NUMBER);
+			} else if (isascii(sc.ch) && isoperator(static_cast<char>(sc.ch)) || sc.ch == '`') {
+				sc.SetState(SCE_P_OPERATOR);
+			} else if (sc.ch == '#') {
+				sc.SetState(sc.chNext == '#' ? SCE_P_COMMENTBLOCK : SCE_P_COMMENTLINE);
+			} else if (IsPyStringStart(sc.ch, sc.chNext, sc.GetRelative(2))) {
+				unsigned int nextIndex = 0;
+				sc.SetState(GetPyStringState(styler, sc.currentPos, &nextIndex));
+				while (nextIndex > (sc.currentPos + 1) && sc.More()) {					sc.Forward();
+				}
+			} else if (IsAWordStart(sc.ch)) {
+				sc.SetState(SCE_P_IDENTIFIER);
+			}
+		}
+	}
+	sc.Complete();
+}
+
+static bool IsCommentLine(int line, Accessor &styler) {
+	int pos = styler.LineStart(line);
+	int eol_pos = styler.LineStart(line + 1) - 1;
+	for (int i = pos; i < eol_pos; i++) {
+		char ch = styler[i];
+		if (ch == '#')
+			return true;
+		else if (ch != ' ' && ch != '\t')
+			return false;
+	}
+	return false;
+}
+
+static bool IsQuoteLine(int line, Accessor &styler) {
+	int style = styler.StyleAt(styler.LineStart(line)) & 31;
+	return ((style == SCE_P_TRIPLE) || (style == SCE_P_TRIPLEDOUBLE));
+}
+
+
+static void FoldRenPyDoc(unsigned int startPos, int length, int /*initStyle - unused*/,
+                         WordList *[], Accessor &styler) {
+	const int maxPos = startPos + length;
+	const int maxLines = styler.GetLine(maxPos - 1);             // Requested last line
+	const int docLines = styler.GetLine(styler.Length() - 1);  // Available last line
+	const bool foldComment = styler.GetPropertyInt("fold.comment.renpy") != 0;
+	const bool foldQuotes = styler.GetPropertyInt("fold.quotes.renpy") != 0;
+        
+	// Backtrack to previous non-blank line so we can determine indent level
+	// for any white space lines (needed esp. within triple quoted strings)
+	// and so we can fix any preceding fold level (which is why we go back
+	// at least one line in all cases)
+	int spaceFlags = 0;
+	int lineCurrent = styler.GetLine(startPos);
+	int indentCurrent = styler.IndentAmount(lineCurrent, &spaceFlags, NULL);
+	while (lineCurrent > 0) {
+		lineCurrent--;
+		indentCurrent = styler.IndentAmount(lineCurrent, &spaceFlags, NULL);
+		if (!(indentCurrent & SC_FOLDLEVELWHITEFLAG) &&
+		        (!IsCommentLine(lineCurrent, styler)) &&
+		        (!IsQuoteLine(lineCurrent, styler)))
+			break;
+	}
+	int indentCurrentLevel = indentCurrent & SC_FOLDLEVELNUMBERMASK;
+
+	// Set up initial loop state
+	startPos = styler.LineStart(lineCurrent);
+	int prev_state = SCE_P_DEFAULT & 31;
+	if (lineCurrent >= 1)
+		prev_state = styler.StyleAt(startPos - 1) & 31;
+	int prevQuote = foldQuotes && ((prev_state == SCE_P_TRIPLE) || (prev_state == SCE_P_TRIPLEDOUBLE));
+	int prevComment = 0;
+	if (lineCurrent >= 1)
+		prevComment = foldComment && IsCommentLine(lineCurrent - 1, styler);
+
+	// Process all characters to end of requested range or end of any triple quote
+	// or comment that hangs over the end of the range.  Cap processing in all cases
+	// to end of document (in case of unclosed quote or comment at end).
+	while ((lineCurrent <= docLines) && ((lineCurrent <= maxLines) || prevQuote || prevComment)) {
+
+		// Gather info
+		int lev = indentCurrent;
+		int lineNext = lineCurrent + 1;
+		int indentNext = indentCurrent;
+		int quote = false;
+		if (lineNext <= docLines) {
+			// Information about next line is only available if not at end of document
+			indentNext = styler.IndentAmount(lineNext, &spaceFlags, NULL);
+			int style = styler.StyleAt(styler.LineStart(lineNext)) & 31;
+			quote = foldQuotes && ((style == SCE_P_TRIPLE) || (style == SCE_P_TRIPLEDOUBLE));
+		}
+
+                const int quote_start = (quote && !prevQuote);
+		const int quote_continue = (quote && prevQuote);
+		const int comment = foldComment && IsCommentLine(lineCurrent, styler);
+		const int comment_start = (comment && !prevComment && (lineNext <= docLines) &&
+		                           IsCommentLine(lineNext, styler) && (lev > SC_FOLDLEVELBASE));
+		const int comment_continue = (comment && prevComment);
+		if ((!quote || !prevQuote) && !comment)
+			indentCurrentLevel = indentCurrent & SC_FOLDLEVELNUMBERMASK;
+		if (quote)
+			indentNext = indentCurrentLevel;
+		if (indentNext & SC_FOLDLEVELWHITEFLAG)
+			indentNext = SC_FOLDLEVELWHITEFLAG | indentCurrentLevel;
+
+		if (quote_start) {
+			// Place fold point at start of triple quoted string
+			lev |= SC_FOLDLEVELHEADERFLAG;
+		} else if (quote_continue || prevQuote) {
+			// Add level to rest of lines in the string
+			lev = lev + 1;
+		} else if (comment_start) {
+			// Place fold point at start of a block of comments
+			lev |= SC_FOLDLEVELHEADERFLAG;
+		} else if (comment_continue) {
+			// Add level to rest of lines in the block
+			lev = lev + 1;
+		}
+
+		// Skip past any blank lines for next indent level info; we skip also
+		// comments (all comments, not just those starting in column 0)
+		// which effectively folds them into surrounding code rather
+		// than screwing up folding.
+
+		while (!quote &&
+		        (lineNext < docLines) &&
+		        ((indentNext & SC_FOLDLEVELWHITEFLAG) ||
+		         (lineNext <= docLines && IsCommentLine(lineNext, styler)))) {
+
+			lineNext++;
+			indentNext = styler.IndentAmount(lineNext, &spaceFlags, NULL);
+		}
+
+		const int levelAfterComments = indentNext & SC_FOLDLEVELNUMBERMASK;
+		const int levelBeforeComments = Platform::Maximum(indentCurrentLevel,levelAfterComments);
+
+		// Now set all the indent levels on the lines we skipped
+		// Do this from end to start.  Once we encounter one line
+		// which is indented more than the line after the end of
+		// the comment-block, use the level of the block before
+
+		int skipLine = lineNext;
+		int skipLevel = levelAfterComments;
+
+		while (--skipLine > lineCurrent) {
+			int skipLineIndent = styler.IndentAmount(skipLine, &spaceFlags, NULL);
+
+			if ((skipLineIndent & SC_FOLDLEVELNUMBERMASK) > levelAfterComments)
+				skipLevel = levelBeforeComments;
+
+			int whiteFlag = skipLineIndent & SC_FOLDLEVELWHITEFLAG;
+
+			styler.SetLevel(skipLine, skipLevel | whiteFlag);
+		}
+
+		// Set fold header on non-quote/non-comment line
+		if (!quote && !comment && !(indentCurrent & SC_FOLDLEVELWHITEFLAG) ) {
+			if ((indentCurrent & SC_FOLDLEVELNUMBERMASK) < (indentNext & SC_FOLDLEVELNUMBERMASK))
+				lev |= SC_FOLDLEVELHEADERFLAG;
+		}
+
+		// Keep track of triple quote and block comment state of previous line
+		prevQuote = quote;
+		prevComment = comment_start || comment_continue;
+
+		// Set fold level for this line and move to next line
+		styler.SetLevel(lineCurrent, lev);
+		indentCurrent = indentNext;
+		lineCurrent = lineNext;
+	}
+
+	// NOTE: Cannot set level of last line here because indentCurrent doesn't have
+	// header flag set; the loop above is crafted to take care of this case!
+	//styler.SetLevel(lineCurrent, indentCurrent);
+}
+
+static const char * const pythonWordListDesc[] = {
+	"Keywords",
+	0
+};
+
+LexerModule lmRenpy(SCLEX_AUTOMATIC, ColourisePyDoc, "renpy", FoldRenPyDoc,
+                    pythonWordListDesc);
diff -u -r -N scite-1.62-clean/scintilla/src/LexRenpy.cxx~ scite-1.62/scintilla/src/LexRenpy.cxx~
--- scite-1.62-clean/scintilla/src/LexRenpy.cxx~	1969-12-31 19:00:00.000000000 -0500
+++ scite-1.62/scintilla/src/LexRenpy.cxx~	2005-03-17 23:11:30.768390706 -0500
@@ -0,0 +1,438 @@
+// Scintilla source code edit control
+/** @file LexPython.cxx
+ ** Lexer for Python.
+ **/
+// Copyright 1998-2002 by Neil Hodgson <neilh@scintilla.org>
+// The License.txt file describes the conditions under which this software may be distributed.
+
+#include <stdlib.h>
+#include <string.h>
+#include <ctype.h>
+#include <stdio.h>
+#include <stdarg.h>
+
+#include "Platform.h"
+
+#include "PropSet.h"
+#include "Accessor.h"
+#include "StyleContext.h"
+#include "KeyWords.h"
+#include "Scintilla.h"
+#include "SciLexer.h"
+
+enum kwType { kwOther, kwClass, kwDef, kwImport };
+
+static bool IsPyComment(Accessor &styler, int pos, int len) {
+	return len > 0 && styler[pos] == '#';
+}
+
+static bool IsPyStringStart(int ch, int chNext, int chNext2) {
+	if (ch == '\'' || ch == '"')
+		return true;
+	if (ch == 'u' || ch == 'U') {
+		if (chNext == '"' || chNext == '\'')
+			return true;
+		if ((chNext == 'r' || chNext == 'R') && (chNext2 == '"' || chNext2 == '\''))
+			return true;
+	}
+	if ((ch == 'r' || ch == 'R') && (chNext == '"' || chNext == '\''))
+		return true;
+
+	return false;
+}
+
+/* Return the state to use for the string starting at i; *nextIndex will be set to the first index following the quote(s) */
+static int GetPyStringState(Accessor &styler, int i, unsigned int *nextIndex) {
+	char ch = styler.SafeGetCharAt(i);
+	char chNext = styler.SafeGetCharAt(i + 1);
+
+	// Advance beyond r, u, or ur prefix, but bail if there are any unexpected chars
+	if (ch == 'r' || ch == 'R') {
+		i++;
+		ch = styler.SafeGetCharAt(i);
+		chNext = styler.SafeGetCharAt(i + 1);
+	} else if (ch == 'u' || ch == 'U') {
+		if (chNext == 'r' || chNext == 'R')
+			i += 2;
+		else
+			i += 1;
+		ch = styler.SafeGetCharAt(i);
+		chNext = styler.SafeGetCharAt(i + 1);
+	}
+
+	if (ch != '"' && ch != '\'') {
+		*nextIndex = i + 1;
+		return SCE_P_DEFAULT;
+	}
+
+	if (ch == chNext && ch == styler.SafeGetCharAt(i + 2)) {
+		*nextIndex = i + 3;
+
+		if (ch == '"')
+			return SCE_P_TRIPLEDOUBLE;
+		else
+			return SCE_P_TRIPLE;
+	} else {
+		*nextIndex = i + 1;
+
+		if (ch == '"')
+			return SCE_P_STRING;
+		else
+			return SCE_P_CHARACTER;
+	}
+}
+
+static inline bool IsAWordChar(int ch) {
+	return (ch < 0x80) && (isalnum(ch) || ch == '.' || ch == '_');
+}
+
+static inline bool IsAWordStart(int ch) {
+	return (ch < 0x80) && (isalnum(ch) || ch == '_');
+}
+
+static void ColourisePyDoc(unsigned int startPos, int length, int initStyle,
+                           WordList *keywordlists[], Accessor &styler) {
+
+	int endPos = startPos + length;
+
+	// Backtrack to previous line in case need to fix its tab whinging
+	int lineCurrent = styler.GetLine(startPos);
+	if (startPos > 0) {
+		if (lineCurrent > 0) {
+			lineCurrent--;
+			startPos = styler.LineStart(lineCurrent);
+			if (startPos == 0)
+				initStyle = SCE_P_DEFAULT;
+			else
+				initStyle = styler.StyleAt(startPos - 1);
+		}
+	}
+
+	WordList &keywords = *keywordlists[0];
+
+	const int whingeLevel = styler.GetPropertyInt("tab.timmy.whinge.level");
+
+	initStyle = initStyle & 31;
+	if (initStyle == SCE_P_STRINGEOL) {
+		initStyle = SCE_P_DEFAULT;
+	}
+
+	kwType kwLast = kwOther;
+	int spaceFlags = 0;
+	styler.IndentAmount(lineCurrent, &spaceFlags, IsPyComment);
+	bool hexadecimal = false;
+
+	// Python uses a different mask because bad indentation is marked by oring with 32
+	StyleContext sc(startPos, endPos - startPos, initStyle, styler, 0x7f);
+
+	for (; sc.More(); sc.Forward()) {
+
+		if (sc.atLineStart) {
+			const char chBad = static_cast<char>(64);
+			const char chGood = static_cast<char>(0);
+			char chFlags = chGood;
+			if (whingeLevel == 1) {
+				chFlags = (spaceFlags & wsInconsistent) ? chBad : chGood;
+			} else if (whingeLevel == 2) {
+				chFlags = (spaceFlags & wsSpaceTab) ? chBad : chGood;
+			} else if (whingeLevel == 3) {
+				chFlags = (spaceFlags & wsSpace) ? chBad : chGood;
+			} else if (whingeLevel == 4) {
+				chFlags = (spaceFlags & wsTab) ? chBad : chGood;
+			}
+			sc.SetState(sc.state);
+			styler.SetFlags(chFlags, static_cast<char>(sc.state));
+		}
+
+		if (sc.atLineEnd) {
+			if ((sc.state == SCE_P_DEFAULT) ||
+			        (sc.state == SCE_P_TRIPLE) ||
+			        (sc.state == SCE_P_TRIPLEDOUBLE)) {
+				// Perform colourisation of white space and triple quoted strings at end of each line to allow
+				// tab marking to work inside white space and triple quoted strings
+				sc.SetState(sc.state);
+			}
+			lineCurrent++;
+			styler.IndentAmount(lineCurrent, &spaceFlags, IsPyComment);
+			if ((sc.state == SCE_P_STRING) || (sc.state == SCE_P_CHARACTER)) {
+				sc.ChangeState(SCE_P_STRINGEOL);
+				sc.ForwardSetState(SCE_P_DEFAULT);
+			}
+			if (!sc.More())
+				break;
+		}
+
+		bool needEOLCheck = false;
+
+		// Check for a state end
+		if (sc.state == SCE_P_OPERATOR) {
+			kwLast = kwOther;
+			sc.SetState(SCE_P_DEFAULT);
+		} else if (sc.state == SCE_P_NUMBER) {
+			if (!IsAWordChar(sc.ch) &&
+			        !(!hexadecimal && ((sc.ch == '+' || sc.ch == '-') && (sc.chPrev == 'e' || sc.chPrev == 'E')))) {
+				sc.SetState(SCE_P_DEFAULT);
+			}
+		} else if (sc.state == SCE_P_IDENTIFIER) {
+			if ((sc.ch == '.') || (!IsAWordChar(sc.ch))) {
+				char s[100];
+				sc.GetCurrent(s, sizeof(s));
+				int style = SCE_P_IDENTIFIER;
+				if ((kwLast == kwImport) && (strcmp(s, "as") == 0)) {
+					style = SCE_P_WORD;
+				} else if (keywords.InList(s)) {
+					style = SCE_P_WORD;
+				} else if (kwLast == kwClass) {
+					style = SCE_P_CLASSNAME;
+				} else if (kwLast == kwDef) {
+					style = SCE_P_DEFNAME;
+				}
+				sc.ChangeState(style);
+				sc.SetState(SCE_P_DEFAULT);
+				if (style == SCE_P_WORD) {
+					if (0 == strcmp(s, "class"))
+						kwLast = kwClass;
+					else if (0 == strcmp(s, "def"))
+						kwLast = kwDef;
+					else if (0 == strcmp(s, "import"))
+						kwLast = kwImport;
+					else
+						kwLast = kwOther;
+				} else if (style == SCE_P_CLASSNAME) {
+					kwLast = kwOther;
+				} else if (style == SCE_P_DEFNAME) {
+					kwLast = kwOther;
+				}
+			}
+		} else if ((sc.state == SCE_P_COMMENTLINE) || (sc.state == SCE_P_COMMENTBLOCK)) {
+			if (sc.ch == '\r' || sc.ch == '\n') {
+				sc.SetState(SCE_P_DEFAULT);
+			}
+		} else if ((sc.state == SCE_P_STRING) || (sc.state == SCE_P_CHARACTER)) {
+			if (sc.ch == '\\') {
+				if ((sc.chNext == '\r') && (sc.GetRelative(2) == '\n')) {
+					sc.Forward();
+				}
+				sc.Forward();
+			} else if ((sc.state == SCE_P_STRING) && (sc.ch == '\"')) {
+				sc.ForwardSetState(SCE_P_DEFAULT);
+				needEOLCheck = true;
+			} else if ((sc.state == SCE_P_CHARACTER) && (sc.ch == '\'')) {
+				sc.ForwardSetState(SCE_P_DEFAULT);
+				needEOLCheck = true;
+			}
+		} else if (sc.state == SCE_P_TRIPLE) {
+			if (sc.ch == '\\') {
+				sc.Forward();
+			} else if (sc.Match("\'\'\'")) {
+				sc.Forward();
+				sc.Forward();
+				sc.ForwardSetState(SCE_P_DEFAULT);
+				needEOLCheck = true;
+			}
+		} else if (sc.state == SCE_P_TRIPLEDOUBLE) {
+			if (sc.ch == '\\') {
+				sc.Forward();
+			} else if (sc.Match("\"\"\"")) {
+				sc.Forward();
+				sc.Forward();
+				sc.ForwardSetState(SCE_P_DEFAULT);
+				needEOLCheck = true;
+			}
+		}
+
+		// State exit code may have moved on to end of line
+		if (needEOLCheck && sc.atLineEnd) {
+			lineCurrent++;
+			styler.IndentAmount(lineCurrent, &spaceFlags, IsPyComment);
+			if (!sc.More())
+				break;
+		}
+
+		// Check for a new state starting character
+		if (sc.state == SCE_P_DEFAULT) {
+			if (IsADigit(sc.ch) || (sc.ch == '.' && IsADigit(sc.chNext))) {
+				if (sc.ch == '0' && (sc.chNext == 'x' || sc.chNext == 'X')) {
+					hexadecimal = true;
+				} else {
+					hexadecimal = false;
+				}
+				sc.SetState(SCE_P_NUMBER);
+			} else if (isascii(sc.ch) && isoperator(static_cast<char>(sc.ch)) || sc.ch == '`') {
+				sc.SetState(SCE_P_OPERATOR);
+			} else if (sc.ch == '#') {
+				sc.SetState(sc.chNext == '#' ? SCE_P_COMMENTBLOCK : SCE_P_COMMENTLINE);
+			} else if (IsPyStringStart(sc.ch, sc.chNext, sc.GetRelative(2))) {
+				unsigned int nextIndex = 0;
+				sc.SetState(GetPyStringState(styler, sc.currentPos, &nextIndex));
+				while (nextIndex > (sc.currentPos + 1) && sc.More()) {					sc.Forward();
+				}
+			} else if (IsAWordStart(sc.ch)) {
+				sc.SetState(SCE_P_IDENTIFIER);
+			}
+		}
+	}
+	sc.Complete();
+}
+
+static bool IsCommentLine(int line, Accessor &styler) {
+	int pos = styler.LineStart(line);
+	int eol_pos = styler.LineStart(line + 1) - 1;
+	for (int i = pos; i < eol_pos; i++) {
+		char ch = styler[i];
+		if (ch == '#')
+			return true;
+		else if (ch != ' ' && ch != '\t')
+			return false;
+	}
+	return false;
+}
+
+static bool IsQuoteLine(int line, Accessor &styler) {
+	int style = styler.StyleAt(styler.LineStart(line)) & 31;
+	return ((style == SCE_P_TRIPLE) || (style == SCE_P_TRIPLEDOUBLE));
+}
+
+
+static void FoldPyDoc(unsigned int startPos, int length, int /*initStyle - unused*/,
+                      WordList *[], Accessor &styler) {
+	const int maxPos = startPos + length;
+	const int maxLines = styler.GetLine(maxPos - 1);             // Requested last line
+	const int docLines = styler.GetLine(styler.Length() - 1);  // Available last line
+	const bool foldComment = styler.GetPropertyInt("fold.comment.python") != 0;
+	const bool foldQuotes = styler.GetPropertyInt("fold.quotes.python") != 0;
+
+	// Backtrack to previous non-blank line so we can determine indent level
+	// for any white space lines (needed esp. within triple quoted strings)
+	// and so we can fix any preceding fold level (which is why we go back
+	// at least one line in all cases)
+	int spaceFlags = 0;
+	int lineCurrent = styler.GetLine(startPos);
+	int indentCurrent = styler.IndentAmount(lineCurrent, &spaceFlags, NULL);
+	while (lineCurrent > 0) {
+		lineCurrent--;
+		indentCurrent = styler.IndentAmount(lineCurrent, &spaceFlags, NULL);
+		if (!(indentCurrent & SC_FOLDLEVELWHITEFLAG) &&
+		        (!IsCommentLine(lineCurrent, styler)) &&
+		        (!IsQuoteLine(lineCurrent, styler)))
+			break;
+	}
+	int indentCurrentLevel = indentCurrent & SC_FOLDLEVELNUMBERMASK;
+
+	// Set up initial loop state
+	startPos = styler.LineStart(lineCurrent);
+	int prev_state = SCE_P_DEFAULT & 31;
+	if (lineCurrent >= 1)
+		prev_state = styler.StyleAt(startPos - 1) & 31;
+	int prevQuote = foldQuotes && ((prev_state == SCE_P_TRIPLE) || (prev_state == SCE_P_TRIPLEDOUBLE));
+	int prevComment = 0;
+	if (lineCurrent >= 1)
+		prevComment = foldComment && IsCommentLine(lineCurrent - 1, styler);
+
+	// Process all characters to end of requested range or end of any triple quote
+	// or comment that hangs over the end of the range.  Cap processing in all cases
+	// to end of document (in case of unclosed quote or comment at end).
+	while ((lineCurrent <= docLines) && ((lineCurrent <= maxLines) || prevQuote || prevComment)) {
+
+		// Gather info
+		int lev = indentCurrent;
+		int lineNext = lineCurrent + 1;
+		int indentNext = indentCurrent;
+		int quote = false;
+		if (lineNext <= docLines) {
+			// Information about next line is only available if not at end of document
+			indentNext = styler.IndentAmount(lineNext, &spaceFlags, NULL);
+			int style = styler.StyleAt(styler.LineStart(lineNext)) & 31;
+			quote = foldQuotes && ((style == SCE_P_TRIPLE) || (style == SCE_P_TRIPLEDOUBLE));
+		}
+		const int quote_start = (quote && !prevQuote);
+		const int quote_continue = (quote && prevQuote);
+		const int comment = foldComment && IsCommentLine(lineCurrent, styler);
+		const int comment_start = (comment && !prevComment && (lineNext <= docLines) &&
+		                           IsCommentLine(lineNext, styler) && (lev > SC_FOLDLEVELBASE));
+		const int comment_continue = (comment && prevComment);
+		if ((!quote || !prevQuote) && !comment)
+			indentCurrentLevel = indentCurrent & SC_FOLDLEVELNUMBERMASK;
+		if (quote)
+			indentNext = indentCurrentLevel;
+		if (indentNext & SC_FOLDLEVELWHITEFLAG)
+			indentNext = SC_FOLDLEVELWHITEFLAG | indentCurrentLevel;
+
+		if (quote_start) {
+			// Place fold point at start of triple quoted string
+			lev |= SC_FOLDLEVELHEADERFLAG;
+		} else if (quote_continue || prevQuote) {
+			// Add level to rest of lines in the string
+			lev = lev + 1;
+		} else if (comment_start) {
+			// Place fold point at start of a block of comments
+			lev |= SC_FOLDLEVELHEADERFLAG;
+		} else if (comment_continue) {
+			// Add level to rest of lines in the block
+			lev = lev + 1;
+		}
+
+		// Skip past any blank lines for next indent level info; we skip also
+		// comments (all comments, not just those starting in column 0)
+		// which effectively folds them into surrounding code rather
+		// than screwing up folding.
+
+		while (!quote &&
+		        (lineNext < docLines) &&
+		        ((indentNext & SC_FOLDLEVELWHITEFLAG) ||
+		         (lineNext <= docLines && IsCommentLine(lineNext, styler)))) {
+
+			lineNext++;
+			indentNext = styler.IndentAmount(lineNext, &spaceFlags, NULL);
+		}
+
+		const int levelAfterComments = indentNext & SC_FOLDLEVELNUMBERMASK;
+		const int levelBeforeComments = Platform::Maximum(indentCurrentLevel,levelAfterComments);
+
+		// Now set all the indent levels on the lines we skipped
+		// Do this from end to start.  Once we encounter one line
+		// which is indented more than the line after the end of
+		// the comment-block, use the level of the block before
+
+		int skipLine = lineNext;
+		int skipLevel = levelAfterComments;
+
+		while (--skipLine > lineCurrent) {
+			int skipLineIndent = styler.IndentAmount(skipLine, &spaceFlags, NULL);
+
+			if ((skipLineIndent & SC_FOLDLEVELNUMBERMASK) > levelAfterComments)
+				skipLevel = levelBeforeComments;
+
+			int whiteFlag = skipLineIndent & SC_FOLDLEVELWHITEFLAG;
+
+			styler.SetLevel(skipLine, skipLevel | whiteFlag);
+		}
+
+		// Set fold header on non-quote/non-comment line
+		if (!quote && !comment && !(indentCurrent & SC_FOLDLEVELWHITEFLAG) ) {
+			if ((indentCurrent & SC_FOLDLEVELNUMBERMASK) < (indentNext & SC_FOLDLEVELNUMBERMASK))
+				lev |= SC_FOLDLEVELHEADERFLAG;
+		}
+
+		// Keep track of triple quote and block comment state of previous line
+		prevQuote = quote;
+		prevComment = comment_start || comment_continue;
+
+		// Set fold level for this line and move to next line
+		styler.SetLevel(lineCurrent, lev);
+		indentCurrent = indentNext;
+		lineCurrent = lineNext;
+	}
+
+	// NOTE: Cannot set level of last line here because indentCurrent doesn't have
+	// header flag set; the loop above is crafted to take care of this case!
+	//styler.SetLevel(lineCurrent, indentCurrent);
+}
+
+static const char * const pythonWordListDesc[] = {
+	"Keywords",
+	0
+};
+
+LexerModule lmPython(SCLEX_PYTHON, ColourisePyDoc, "python", FoldPyDoc,
+					 pythonWordListDesc);
diff -u -r -N scite-1.62-clean/scintilla/win32/makefile scite-1.62/scintilla/win32/makefile
--- scite-1.62-clean/scintilla/win32/makefile	2004-10-15 19:41:28.000000000 -0400
+++ scite-1.62/scintilla/win32/makefile	2005-03-17 23:15:42.971946125 -0500
@@ -51,13 +51,13 @@
 #++Autogenerated -- run src/LexGen.py to regenerate
 #**LEXOBJS=\\\n\(\*.o \)
 LEXOBJS=\
-LexAda.o LexAPDL.o LexAsm.o LexAsn1.o LexAU3.o LexAVE.o LexBaan.o LexBash.o \
-LexBullant.o LexCLW.o LexConf.o LexCPP.o LexCrontab.o LexCSS.o LexEiffel.o \
-LexErlang.o LexEScript.o LexForth.o LexFortran.o LexGui4Cli.o LexHTML.o \
-LexKix.o LexLisp.o LexLout.o LexLua.o LexMatlab.o LexMetapost.o LexMMIXAL.o \
-LexMPT.o LexMSSQL.o LexNsis.o LexOthers.o LexPascal.o LexPB.o LexPerl.o \
-LexPOV.o LexPS.o LexPython.o LexRuby.o LexScriptol.o LexSpecman.o LexSQL.o \
-LexTeX.o LexVB.o LexVerilog.o LexVHDL.o LexYAML.o
+LexAPDL.o LexAU3.o LexAVE.o LexAda.o LexAsm.o LexAsn1.o LexBaan.o LexBash.o \
+LexBullant.o LexCLW.o LexCPP.o LexCSS.o LexConf.o LexCrontab.o LexEScript.o \
+LexEiffel.o LexErlang.o LexForth.o LexFortran.o LexGui4Cli.o LexHTML.o \
+LexKix.o LexLisp.o LexLout.o LexLua.o LexMMIXAL.o LexMPT.o LexMSSQL.o \
+LexMatlab.o LexMetapost.o LexNsis.o LexOthers.o LexPB.o LexPOV.o LexPS.o \
+LexPascal.o LexPerl.o LexPython.o LexRuby.o LexSQL.o LexScriptol.o \
+LexSpecman.o LexTeX.o LexVB.o LexVHDL.o LexVerilog.o LexYAML.o LexRenpy.o
 #--Autogenerated -- end of automatically generated section
 
 SOBJS	= ScintillaWin.o ScintillaBase.o Editor.o Document.o \
diff -u -r -N scite-1.62-clean/scintilla/win32/scintilla.mak scite-1.62/scintilla/win32/scintilla.mak
--- scite-1.62-clean/scintilla/win32/scintilla.mak	2004-10-15 19:41:28.000000000 -0400
+++ scite-1.62/scintilla/win32/scintilla.mak	2005-03-17 23:15:43.003938584 -0500
@@ -109,23 +109,23 @@
 #++Autogenerated -- run src/LexGen.py to regenerate
 #**LEXOBJS=\\\n\(\t$(DIR_O)\\\*.obj \\\n\)
 LEXOBJS=\
-	$(DIR_O)\LexAda.obj \
 	$(DIR_O)\LexAPDL.obj \
-	$(DIR_O)\LexAsm.obj \
-	$(DIR_O)\LexAsn1.obj \
 	$(DIR_O)\LexAU3.obj \
 	$(DIR_O)\LexAVE.obj \
+	$(DIR_O)\LexAda.obj \
+	$(DIR_O)\LexAsm.obj \
+	$(DIR_O)\LexAsn1.obj \
 	$(DIR_O)\LexBaan.obj \
 	$(DIR_O)\LexBash.obj \
 	$(DIR_O)\LexBullant.obj \
 	$(DIR_O)\LexCLW.obj \
-	$(DIR_O)\LexConf.obj \
 	$(DIR_O)\LexCPP.obj \
-	$(DIR_O)\LexCrontab.obj \
 	$(DIR_O)\LexCSS.obj \
+	$(DIR_O)\LexConf.obj \
+	$(DIR_O)\LexCrontab.obj \
+	$(DIR_O)\LexEScript.obj \
 	$(DIR_O)\LexEiffel.obj \
 	$(DIR_O)\LexErlang.obj \
-	$(DIR_O)\LexEScript.obj \
 	$(DIR_O)\LexForth.obj \
 	$(DIR_O)\LexFortran.obj \
 	$(DIR_O)\LexGui4Cli.obj \
@@ -134,28 +134,29 @@
 	$(DIR_O)\LexLisp.obj \
 	$(DIR_O)\LexLout.obj \
 	$(DIR_O)\LexLua.obj \
-	$(DIR_O)\LexMatlab.obj \
-	$(DIR_O)\LexMetapost.obj \
 	$(DIR_O)\LexMMIXAL.obj \
 	$(DIR_O)\LexMPT.obj \
 	$(DIR_O)\LexMSSQL.obj \
+	$(DIR_O)\LexMatlab.obj \
+	$(DIR_O)\LexMetapost.obj \
 	$(DIR_O)\LexNsis.obj \
 	$(DIR_O)\LexOthers.obj \
-	$(DIR_O)\LexPascal.obj \
 	$(DIR_O)\LexPB.obj \
-	$(DIR_O)\LexPerl.obj \
 	$(DIR_O)\LexPOV.obj \
 	$(DIR_O)\LexPS.obj \
+	$(DIR_O)\LexPascal.obj \
+	$(DIR_O)\LexPerl.obj \
 	$(DIR_O)\LexPython.obj \
 	$(DIR_O)\LexRuby.obj \
+	$(DIR_O)\LexSQL.obj \
 	$(DIR_O)\LexScriptol.obj \
 	$(DIR_O)\LexSpecman.obj \
-	$(DIR_O)\LexSQL.obj \
 	$(DIR_O)\LexTeX.obj \
 	$(DIR_O)\LexVB.obj \
-	$(DIR_O)\LexVerilog.obj \
 	$(DIR_O)\LexVHDL.obj \
+	$(DIR_O)\LexVerilog.obj \
 	$(DIR_O)\LexYAML.obj \
+	$(DIR_O)\LexRenpy.obj \
 
 #--Autogenerated -- end of automatically generated section
 
@@ -265,18 +266,18 @@
 #++Autogenerated -- run src/LexGen.py to regenerate
 #**\n\($(DIR_O)\\\*.obj: ..\\src\\\*.cxx $(LEX_HEADERS)\n\n\)
 
-$(DIR_O)\LexAda.obj: ..\src\LexAda.cxx $(LEX_HEADERS)
-
 $(DIR_O)\LexAPDL.obj: ..\src\LexAPDL.cxx $(LEX_HEADERS)
 
-$(DIR_O)\LexAsm.obj: ..\src\LexAsm.cxx $(LEX_HEADERS)
-
-$(DIR_O)\LexAsn1.obj: ..\src\LexAsn1.cxx $(LEX_HEADERS)
-
 $(DIR_O)\LexAU3.obj: ..\src\LexAU3.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexAVE.obj: ..\src\LexAVE.cxx $(LEX_HEADERS)
 
+$(DIR_O)\LexAda.obj: ..\src\LexAda.cxx $(LEX_HEADERS)
+
+$(DIR_O)\LexAsm.obj: ..\src\LexAsm.cxx $(LEX_HEADERS)
+
+$(DIR_O)\LexAsn1.obj: ..\src\LexAsn1.cxx $(LEX_HEADERS)
+
 $(DIR_O)\LexBaan.obj: ..\src\LexBaan.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexBash.obj: ..\src\LexBash.cxx $(LEX_HEADERS)
@@ -285,20 +286,20 @@
 
 $(DIR_O)\LexCLW.obj: ..\src\LexCLW.cxx $(LEX_HEADERS)
 
-$(DIR_O)\LexConf.obj: ..\src\LexConf.cxx $(LEX_HEADERS)
-
 $(DIR_O)\LexCPP.obj: ..\src\LexCPP.cxx $(LEX_HEADERS)
 
+$(DIR_O)\LexCSS.obj: ..\src\LexCSS.cxx $(LEX_HEADERS)
+
+$(DIR_O)\LexConf.obj: ..\src\LexConf.cxx $(LEX_HEADERS)
+
 $(DIR_O)\LexCrontab.obj: ..\src\LexCrontab.cxx $(LEX_HEADERS)
 
-$(DIR_O)\LexCSS.obj: ..\src\LexCSS.cxx $(LEX_HEADERS)
+$(DIR_O)\LexEScript.obj: ..\src\LexEScript.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexEiffel.obj: ..\src\LexEiffel.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexErlang.obj: ..\src\LexErlang.cxx $(LEX_HEADERS)
 
-$(DIR_O)\LexEScript.obj: ..\src\LexEScript.cxx $(LEX_HEADERS)
-
 $(DIR_O)\LexForth.obj: ..\src\LexForth.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexFortran.obj: ..\src\LexFortran.cxx $(LEX_HEADERS)
@@ -315,50 +316,52 @@
 
 $(DIR_O)\LexLua.obj: ..\src\LexLua.cxx $(LEX_HEADERS)
 
-$(DIR_O)\LexMatlab.obj: ..\src\LexMatlab.cxx $(LEX_HEADERS)
-
-$(DIR_O)\LexMetapost.obj: ..\src\LexMetapost.cxx $(LEX_HEADERS)
-
 $(DIR_O)\LexMMIXAL.obj: ..\src\LexMMIXAL.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexMPT.obj: ..\src\LexMPT.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexMSSQL.obj: ..\src\LexMSSQL.cxx $(LEX_HEADERS)
 
+$(DIR_O)\LexMatlab.obj: ..\src\LexMatlab.cxx $(LEX_HEADERS)
+
+$(DIR_O)\LexMetapost.obj: ..\src\LexMetapost.cxx $(LEX_HEADERS)
+
 $(DIR_O)\LexNsis.obj: ..\src\LexNsis.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexOthers.obj: ..\src\LexOthers.cxx $(LEX_HEADERS)
 
-$(DIR_O)\LexPascal.obj: ..\src\LexPascal.cxx $(LEX_HEADERS)
-
 $(DIR_O)\LexPB.obj: ..\src\LexPB.cxx $(LEX_HEADERS)
 
-$(DIR_O)\LexPerl.obj: ..\src\LexPerl.cxx $(LEX_HEADERS)
-
 $(DIR_O)\LexPOV.obj: ..\src\LexPOV.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexPS.obj: ..\src\LexPS.cxx $(LEX_HEADERS)
 
+$(DIR_O)\LexPascal.obj: ..\src\LexPascal.cxx $(LEX_HEADERS)
+
+$(DIR_O)\LexPerl.obj: ..\src\LexPerl.cxx $(LEX_HEADERS)
+
 $(DIR_O)\LexPython.obj: ..\src\LexPython.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexRuby.obj: ..\src\LexRuby.cxx $(LEX_HEADERS)
 
+$(DIR_O)\LexSQL.obj: ..\src\LexSQL.cxx $(LEX_HEADERS)
+
 $(DIR_O)\LexScriptol.obj: ..\src\LexScriptol.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexSpecman.obj: ..\src\LexSpecman.cxx $(LEX_HEADERS)
 
-$(DIR_O)\LexSQL.obj: ..\src\LexSQL.cxx $(LEX_HEADERS)
-
 $(DIR_O)\LexTeX.obj: ..\src\LexTeX.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexVB.obj: ..\src\LexVB.cxx $(LEX_HEADERS)
 
-$(DIR_O)\LexVerilog.obj: ..\src\LexVerilog.cxx $(LEX_HEADERS)
-
 $(DIR_O)\LexVHDL.obj: ..\src\LexVHDL.cxx $(LEX_HEADERS)
 
+$(DIR_O)\LexVerilog.obj: ..\src\LexVerilog.cxx $(LEX_HEADERS)
+
 $(DIR_O)\LexYAML.obj: ..\src\LexYAML.cxx $(LEX_HEADERS)
 
+$(DIR_O)\LexRenpy.obj: ..\src\LexRenpy.cxx $(LEX_HEADERS)
+
 
 #--Autogenerated -- end of automatically generated section
 
diff -u -r -N scite-1.62-clean/scintilla/win32/scintilla_vc6.mak scite-1.62/scintilla/win32/scintilla_vc6.mak
--- scite-1.62-clean/scintilla/win32/scintilla_vc6.mak	2004-10-15 19:41:28.000000000 -0400
+++ scite-1.62/scintilla/win32/scintilla_vc6.mak	2005-03-17 23:15:43.032931751 -0500
@@ -111,23 +111,23 @@
 #++Autogenerated -- run src/LexGen.py to regenerate
 #**LEXOBJS=\\\n\(\t$(DIR_O)\\\*.obj \\\n\)
 LEXOBJS=\
-	$(DIR_O)\LexAda.obj \
 	$(DIR_O)\LexAPDL.obj \
-	$(DIR_O)\LexAsm.obj \
-	$(DIR_O)\LexAsn1.obj \
 	$(DIR_O)\LexAU3.obj \
 	$(DIR_O)\LexAVE.obj \
+	$(DIR_O)\LexAda.obj \
+	$(DIR_O)\LexAsm.obj \
+	$(DIR_O)\LexAsn1.obj \
 	$(DIR_O)\LexBaan.obj \
 	$(DIR_O)\LexBash.obj \
 	$(DIR_O)\LexBullant.obj \
 	$(DIR_O)\LexCLW.obj \
-	$(DIR_O)\LexConf.obj \
 	$(DIR_O)\LexCPP.obj \
-	$(DIR_O)\LexCrontab.obj \
 	$(DIR_O)\LexCSS.obj \
+	$(DIR_O)\LexConf.obj \
+	$(DIR_O)\LexCrontab.obj \
+	$(DIR_O)\LexEScript.obj \
 	$(DIR_O)\LexEiffel.obj \
 	$(DIR_O)\LexErlang.obj \
-	$(DIR_O)\LexEScript.obj \
 	$(DIR_O)\LexForth.obj \
 	$(DIR_O)\LexFortran.obj \
 	$(DIR_O)\LexGui4Cli.obj \
@@ -136,28 +136,29 @@
 	$(DIR_O)\LexLisp.obj \
 	$(DIR_O)\LexLout.obj \
 	$(DIR_O)\LexLua.obj \
-	$(DIR_O)\LexMatlab.obj \
-	$(DIR_O)\LexMetapost.obj \
 	$(DIR_O)\LexMMIXAL.obj \
 	$(DIR_O)\LexMPT.obj \
 	$(DIR_O)\LexMSSQL.obj \
+	$(DIR_O)\LexMatlab.obj \
+	$(DIR_O)\LexMetapost.obj \
 	$(DIR_O)\LexNsis.obj \
 	$(DIR_O)\LexOthers.obj \
-	$(DIR_O)\LexPascal.obj \
 	$(DIR_O)\LexPB.obj \
-	$(DIR_O)\LexPerl.obj \
 	$(DIR_O)\LexPOV.obj \
 	$(DIR_O)\LexPS.obj \
+	$(DIR_O)\LexPascal.obj \
+	$(DIR_O)\LexPerl.obj \
 	$(DIR_O)\LexPython.obj \
 	$(DIR_O)\LexRuby.obj \
+	$(DIR_O)\LexSQL.obj \
 	$(DIR_O)\LexScriptol.obj \
 	$(DIR_O)\LexSpecman.obj \
-	$(DIR_O)\LexSQL.obj \
 	$(DIR_O)\LexTeX.obj \
 	$(DIR_O)\LexVB.obj \
-	$(DIR_O)\LexVerilog.obj \
 	$(DIR_O)\LexVHDL.obj \
+	$(DIR_O)\LexVerilog.obj \
 	$(DIR_O)\LexYAML.obj \
+	$(DIR_O)\LexRenpy.obj \
 
 #--Autogenerated -- end of automatically generated section
 
@@ -267,18 +268,18 @@
 #++Autogenerated -- run src/LexGen.py to regenerate
 #**\n\($(DIR_O)\\\*.obj: ..\\src\\\*.cxx $(LEX_HEADERS)\n\n\)
 
-$(DIR_O)\LexAda.obj: ..\src\LexAda.cxx $(LEX_HEADERS)
-
 $(DIR_O)\LexAPDL.obj: ..\src\LexAPDL.cxx $(LEX_HEADERS)
 
-$(DIR_O)\LexAsm.obj: ..\src\LexAsm.cxx $(LEX_HEADERS)
-
-$(DIR_O)\LexAsn1.obj: ..\src\LexAsn1.cxx $(LEX_HEADERS)
-
 $(DIR_O)\LexAU3.obj: ..\src\LexAU3.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexAVE.obj: ..\src\LexAVE.cxx $(LEX_HEADERS)
 
+$(DIR_O)\LexAda.obj: ..\src\LexAda.cxx $(LEX_HEADERS)
+
+$(DIR_O)\LexAsm.obj: ..\src\LexAsm.cxx $(LEX_HEADERS)
+
+$(DIR_O)\LexAsn1.obj: ..\src\LexAsn1.cxx $(LEX_HEADERS)
+
 $(DIR_O)\LexBaan.obj: ..\src\LexBaan.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexBash.obj: ..\src\LexBash.cxx $(LEX_HEADERS)
@@ -287,20 +288,20 @@
 
 $(DIR_O)\LexCLW.obj: ..\src\LexCLW.cxx $(LEX_HEADERS)
 
-$(DIR_O)\LexConf.obj: ..\src\LexConf.cxx $(LEX_HEADERS)
-
 $(DIR_O)\LexCPP.obj: ..\src\LexCPP.cxx $(LEX_HEADERS)
 
+$(DIR_O)\LexCSS.obj: ..\src\LexCSS.cxx $(LEX_HEADERS)
+
+$(DIR_O)\LexConf.obj: ..\src\LexConf.cxx $(LEX_HEADERS)
+
 $(DIR_O)\LexCrontab.obj: ..\src\LexCrontab.cxx $(LEX_HEADERS)
 
-$(DIR_O)\LexCSS.obj: ..\src\LexCSS.cxx $(LEX_HEADERS)
+$(DIR_O)\LexEScript.obj: ..\src\LexEScript.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexEiffel.obj: ..\src\LexEiffel.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexErlang.obj: ..\src\LexErlang.cxx $(LEX_HEADERS)
 
-$(DIR_O)\LexEScript.obj: ..\src\LexEScript.cxx $(LEX_HEADERS)
-
 $(DIR_O)\LexForth.obj: ..\src\LexForth.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexFortran.obj: ..\src\LexFortran.cxx $(LEX_HEADERS)
@@ -317,50 +318,52 @@
 
 $(DIR_O)\LexLua.obj: ..\src\LexLua.cxx $(LEX_HEADERS)
 
-$(DIR_O)\LexMatlab.obj: ..\src\LexMatlab.cxx $(LEX_HEADERS)
-
-$(DIR_O)\LexMetapost.obj: ..\src\LexMetapost.cxx $(LEX_HEADERS)
-
 $(DIR_O)\LexMMIXAL.obj: ..\src\LexMMIXAL.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexMPT.obj: ..\src\LexMPT.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexMSSQL.obj: ..\src\LexMSSQL.cxx $(LEX_HEADERS)
 
+$(DIR_O)\LexMatlab.obj: ..\src\LexMatlab.cxx $(LEX_HEADERS)
+
+$(DIR_O)\LexMetapost.obj: ..\src\LexMetapost.cxx $(LEX_HEADERS)
+
 $(DIR_O)\LexNsis.obj: ..\src\LexNsis.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexOthers.obj: ..\src\LexOthers.cxx $(LEX_HEADERS)
 
-$(DIR_O)\LexPascal.obj: ..\src\LexPascal.cxx $(LEX_HEADERS)
-
 $(DIR_O)\LexPB.obj: ..\src\LexPB.cxx $(LEX_HEADERS)
 
-$(DIR_O)\LexPerl.obj: ..\src\LexPerl.cxx $(LEX_HEADERS)
-
 $(DIR_O)\LexPOV.obj: ..\src\LexPOV.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexPS.obj: ..\src\LexPS.cxx $(LEX_HEADERS)
 
+$(DIR_O)\LexPascal.obj: ..\src\LexPascal.cxx $(LEX_HEADERS)
+
+$(DIR_O)\LexPerl.obj: ..\src\LexPerl.cxx $(LEX_HEADERS)
+
 $(DIR_O)\LexPython.obj: ..\src\LexPython.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexRuby.obj: ..\src\LexRuby.cxx $(LEX_HEADERS)
 
+$(DIR_O)\LexSQL.obj: ..\src\LexSQL.cxx $(LEX_HEADERS)
+
 $(DIR_O)\LexScriptol.obj: ..\src\LexScriptol.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexSpecman.obj: ..\src\LexSpecman.cxx $(LEX_HEADERS)
 
-$(DIR_O)\LexSQL.obj: ..\src\LexSQL.cxx $(LEX_HEADERS)
-
 $(DIR_O)\LexTeX.obj: ..\src\LexTeX.cxx $(LEX_HEADERS)
 
 $(DIR_O)\LexVB.obj: ..\src\LexVB.cxx $(LEX_HEADERS)
 
-$(DIR_O)\LexVerilog.obj: ..\src\LexVerilog.cxx $(LEX_HEADERS)
-
 $(DIR_O)\LexVHDL.obj: ..\src\LexVHDL.cxx $(LEX_HEADERS)
 
+$(DIR_O)\LexVerilog.obj: ..\src\LexVerilog.cxx $(LEX_HEADERS)
+
 $(DIR_O)\LexYAML.obj: ..\src\LexYAML.cxx $(LEX_HEADERS)
 
+$(DIR_O)\LexRenpy.obj: ..\src\LexRenpy.cxx $(LEX_HEADERS)
+
 
 #--Autogenerated -- end of automatically generated section
 
diff -u -r -N scite-1.62-clean/scite/boundscheck/SciTE.vcproj scite-1.62/scite/boundscheck/SciTE.vcproj
--- scite-1.62-clean/scite/boundscheck/SciTE.vcproj	2004-10-15 19:41:28.000000000 -0400
+++ scite-1.62/scite/boundscheck/SciTE.vcproj	2005-03-17 23:15:43.183896168 -0500
@@ -220,22 +220,22 @@
 				RelativePath="..\lua\src\ldump.c">
 			</File>
 			<File
-				RelativePath="..\..\scintilla\src\LexAda.cxx">
+				RelativePath="..\..\scintilla\src\LexAPDL.cxx">
 			</File>
 			<File
-				RelativePath="..\..\scintilla\src\LexAPDL.cxx">
+				RelativePath="..\..\scintilla\src\LexAU3.cxx">
 			</File>
 			<File
-				RelativePath="..\..\scintilla\src\LexAsm.cxx">
+				RelativePath="..\..\scintilla\src\LexAVE.cxx">
 			</File>
 			<File
-				RelativePath="..\..\scintilla\src\LexAsn1.cxx">
+				RelativePath="..\..\scintilla\src\LexAda.cxx">
 			</File>
 			<File
-				RelativePath="..\..\scintilla\src\LexAU3.cxx">
+				RelativePath="..\..\scintilla\src\LexAsm.cxx">
 			</File>
 			<File
-				RelativePath="..\..\scintilla\src\LexAVE.cxx">
+				RelativePath="..\..\scintilla\src\LexAsn1.cxx">
 			</File>
 			<File
 				RelativePath="..\..\scintilla\src\LexBaan.cxx">
@@ -250,16 +250,19 @@
 				RelativePath="..\..\scintilla\src\LexCLW.cxx">
 			</File>
 			<File
-				RelativePath="..\..\scintilla\src\LexConf.cxx">
+				RelativePath="..\..\scintilla\src\LexCPP.cxx">
 			</File>
 			<File
-				RelativePath="..\..\scintilla\src\LexCPP.cxx">
+				RelativePath="..\..\scintilla\src\LexCSS.cxx">
+			</File>
+			<File
+				RelativePath="..\..\scintilla\src\LexConf.cxx">
 			</File>
 			<File
 				RelativePath="..\..\scintilla\src\LexCrontab.cxx">
 			</File>
 			<File
-				RelativePath="..\..\scintilla\src\LexCSS.cxx">
+				RelativePath="..\..\scintilla\src\LexEScript.cxx">
 			</File>
 			<File
 				RelativePath="..\..\scintilla\src\LexEiffel.cxx">
@@ -268,9 +271,6 @@
 				RelativePath="..\..\scintilla\src\LexErlang.cxx">
 			</File>
 			<File
-				RelativePath="..\..\scintilla\src\LexEScript.cxx">
-			</File>
-			<File
 				RelativePath="..\..\scintilla\src\LexForth.cxx">
 			</File>
 			<File
@@ -295,19 +295,19 @@
 				RelativePath="..\..\scintilla\src\LexLua.cxx">
 			</File>
 			<File
-				RelativePath="..\..\scintilla\src\LexMatlab.cxx">
+				RelativePath="..\..\scintilla\src\LexMMIXAL.cxx">
 			</File>
 			<File
-				RelativePath="..\..\scintilla\src\LexMetapost.cxx">
+				RelativePath="..\..\scintilla\src\LexMPT.cxx">
 			</File>
 			<File
-				RelativePath="..\..\scintilla\src\LexMMIXAL.cxx">
+				RelativePath="..\..\scintilla\src\LexMSSQL.cxx">
 			</File>
 			<File
-				RelativePath="..\..\scintilla\src\LexMPT.cxx">
+				RelativePath="..\..\scintilla\src\LexMatlab.cxx">
 			</File>
 			<File
-				RelativePath="..\..\scintilla\src\LexMSSQL.cxx">
+				RelativePath="..\..\scintilla\src\LexMetapost.cxx">
 			</File>
 			<File
 				RelativePath="..\..\scintilla\src\LexNsis.cxx">
@@ -316,19 +316,19 @@
 				RelativePath="..\..\scintilla\src\LexOthers.cxx">
 			</File>
 			<File
-				RelativePath="..\..\scintilla\src\LexPascal.cxx">
+				RelativePath="..\..\scintilla\src\LexPB.cxx">
 			</File>
 			<File
-				RelativePath="..\..\scintilla\src\LexPB.cxx">
+				RelativePath="..\..\scintilla\src\LexPOV.cxx">
 			</File>
 			<File
-				RelativePath="..\..\scintilla\src\LexPerl.cxx">
+				RelativePath="..\..\scintilla\src\LexPS.cxx">
 			</File>
 			<File
-				RelativePath="..\..\scintilla\src\LexPOV.cxx">
+				RelativePath="..\..\scintilla\src\LexPascal.cxx">
 			</File>
 			<File
-				RelativePath="..\..\scintilla\src\LexPS.cxx">
+				RelativePath="..\..\scintilla\src\LexPerl.cxx">
 			</File>
 			<File
 				RelativePath="..\..\scintilla\src\LexPython.cxx">
@@ -337,13 +337,13 @@
 				RelativePath="..\..\scintilla\src\LexRuby.cxx">
 			</File>
 			<File
-				RelativePath="..\..\scintilla\src\LexScriptol.cxx">
+				RelativePath="..\..\scintilla\src\LexSQL.cxx">
 			</File>
 			<File
-				RelativePath="..\..\scintilla\src\LexSpecman.cxx">
+				RelativePath="..\..\scintilla\src\LexScriptol.cxx">
 			</File>
 			<File
-				RelativePath="..\..\scintilla\src\LexSQL.cxx">
+				RelativePath="..\..\scintilla\src\LexSpecman.cxx">
 			</File>
 			<File
 				RelativePath="..\..\scintilla\src\LexTeX.cxx">
@@ -352,14 +352,17 @@
 				RelativePath="..\..\scintilla\src\LexVB.cxx">
 			</File>
 			<File
-				RelativePath="..\..\scintilla\src\LexVerilog.cxx">
+				RelativePath="..\..\scintilla\src\LexVHDL.cxx">
 			</File>
 			<File
-				RelativePath="..\..\scintilla\src\LexVHDL.cxx">
+				RelativePath="..\..\scintilla\src\LexVerilog.cxx">
 			</File>
 			<File
 				RelativePath="..\..\scintilla\src\LexYAML.cxx">
 			</File>
+			<File
+				RelativePath="..\..\scintilla\src\LexRenpy.cxx">
+			</File>
 
 			<File
 				RelativePath="..\lua\src\lfunc.c">
diff -u -r -N scite-1.62-clean/scite/src/SciTEGlobal.properties scite-1.62/scite/src/SciTEGlobal.properties
--- scite-1.62-clean/scite/src/SciTEGlobal.properties	2004-10-15 19:41:28.000000000 -0400
+++ scite-1.62/scite/src/SciTEGlobal.properties	2005-03-17 23:22:20.183323084 -0500
@@ -250,6 +250,7 @@
 open.filter=\
 All Source|$(source.files)|\
 $(all.files)\
+$(filter.renpy)\
 $(filter.ada)\
 $(filter.conf)\
 $(filter.asm)\
@@ -386,6 +387,7 @@
 # [Ctrl+][Shift+][Fn|a] such as F12 or Ctrl+Shift+D.
 # A '&' may be placed before a letter to be used as an accelerator. This does not work on GTK+.
 menu.language=\
+RenPy|rpy||\
 Text|txt|Shift+F11|\
 Ada|ads||\
 Apache Confi&g|conf||\
@@ -483,6 +485,7 @@
 import pov
 import ps
 import python
+import renpy
 import ruby
 #import scriptol
 import sql
diff -u -r -N scite-1.62-clean/scite/src/SciTEGlobal.properties~ scite-1.62/scite/src/SciTEGlobal.properties~
--- scite-1.62-clean/scite/src/SciTEGlobal.properties~	1969-12-31 19:00:00.000000000 -0500
+++ scite-1.62/scite/src/SciTEGlobal.properties~	2004-10-15 19:41:28.000000000 -0400
@@ -0,0 +1,496 @@
+# Global initialisation file for SciTE
+# For Linux, place in $prefix/share/scite
+# For Windows, place in same directory as SciTE.EXE (or Sc1.EXE)
+# Documentation at http://www.scintilla.org/SciTEDoc.html
+
+# Globals
+
+# Window sizes and visibility
+if PLAT_WIN
+	position.left=0
+	position.top=0
+if PLAT_GTK
+	position.left=5
+	position.top=22
+position.width=576
+position.height=740
+#position.tile=1
+#full.screen.hides.menu=1
+#minimize.to.tray=1
+split.vertical=1
+#output.horizontal.size=200
+#output.vertical.size=60
+#horizontal.scrollbar=0
+#horizontal.scroll.width=10000
+#output.horizontal.scrollbar=0
+#output.horizontal.scroll.width=10000
+#output.scroll=0
+#error.select.line=1
+#end.at.last.line=0
+tabbar.visible=1
+#tabbar.hide.one=1
+#tabbar.multiline=1
+#toolbar.visible=1
+#undo.redo.lazy=1
+#statusbar.visible=1
+#fileselector.width=800
+#fileselector.height=600
+#magnification=-1
+#output.magnification=-1
+
+# Sizes and visibility in edit pane
+#line.margin.visible=1
+line.margin.width=4
+margin.width=16
+#fold.margin.width=16
+#fold.margin.colour=#FF0000
+#fold.margin.highlight.colour=#0000FF
+#blank.margin.left=4
+#blank.margin.right=4
+buffered.draw=1
+#two.phase.draw=0
+use.palette=0
+
+# Element styles
+#view.eol=1
+#control.char.symbol=.
+caret.period=500
+view.whitespace=0
+view.indentation.whitespace=1
+view.indentation.guides=1
+highlight.indentation.guides=1
+#caret.fore=#FF0000
+#caret.width=2
+#caret.line.back=#FFFED8
+#calltip.back=#FFF0FE
+edge.column=200
+edge.mode=0
+edge.colour=#C0DCC0
+braces.check=1
+braces.sloppy=1
+#selection.fore=#006000
+# DADADA used as background because it yields standard silver C0C0C0
+# on low colour displays and a reasonable light grey on higher bit depths
+selection.back=#DADADA
+#whitespace.fore=#FF0000
+#whitespace.back=#FFF0F0
+#error.marker.fore=#0000A0
+#error.marker.back=#DADAFF
+#bookmark.fore=#808000
+#bookmark.back=#FFFFA0
+
+# Checking
+are.you.sure=1
+#are.you.sure.for.build=1
+#quit.on.close.last=1
+#load.on.activate=1
+#save.on.deactivate=1
+#are.you.sure.on.reload=1
+#reload.preserves.undo=1
+#check.if.already.open=1
+default.file.ext=.cxx
+#title.full.path=1
+#title.show.buffers=1
+#save.recent=1
+#save.session=1
+#open.dialog.in.file.directory=1
+#strip.trailing.spaces=1
+#ensure.final.line.end=1
+#ensure.consistent.line.ends=1
+#save.deletes.first=1
+#buffers=10
+#api.*.cxx=d:\api\w.api
+#win95.death.delay=1000
+#translation.missing=***
+#read.only=1
+#max.file.size=1
+
+# Indentation
+tabsize=8
+indent.size=8
+use.tabs=1
+#indent.auto=1
+indent.automatic=1
+indent.opening=0
+indent.closing=0
+#tab.indents=0
+#backspace.unindents=0
+
+# Wrapping of long lines
+#wrap=1
+#cache.layout=3
+#output.wrap=1
+#output.cache.layout=3
+#wrap.visual.flags=3
+#wrap.visual.flags.location=3
+#wrap.visual.startindent=4
+
+# Folding
+# enable folding, and show lines below when collapsed.
+fold=1
+fold.compact=1
+fold.flags=16
+fold.symbols=1
+#fold.on.open=1
+
+# Find and Replace
+#escapes.in.find.replace=1
+# findstr is available on recent versions of Windows including 2000
+if PLAT_WIN
+	find.command=findstr /n /s $(find.what) $(find.files)
+#find.input=$(find.what)
+if PLAT_GTK
+	find.command=grep --line-number "$(find.what)" $(find.files)
+find.files=*.c *.cxx *.h
+#find.in.files.close.on.find=0
+#find.replace.matchcase=1
+#find.replace.escapes=1
+#find.replace.regexp=1
+#find.replace.regexp.posix=1
+#find.replace.wrap=0
+#find.replacewith.focus=0
+
+# Behaviour
+#eol.mode=LF
+#eol.auto=1
+clear.before.execute=0
+#vc.home.key=1
+#wrap.aware.home.end.keys=1
+#autocompleteword.automatic=1
+#autocomplete.choose.single=1
+caret.policy.xslop=1
+caret.policy.width=20
+caret.policy.xstrict=0
+caret.policy.xeven=0
+caret.policy.xjumps=0
+caret.policy.yslop=1
+caret.policy.lines=1
+caret.policy.ystrict=1
+caret.policy.yeven=1
+caret.policy.yjumps=0
+#visible.policy.strict=1
+#visible.policy.slop=1
+#visible.policy.lines=4
+#time.commands=1
+
+# Status Bar
+statusbar.number=4
+statusbar.text.1=\
+li=$(LineNumber) co=$(ColumnNumber) $(OverType) ($(EOLMode)) $(FileAttr)
+statusbar.text.2=\
+$(BufferLength) chars in $(NbOfLines) lines. Sel: $(SelLength) chars.
+statusbar.text.3=\
+Now is: Date=$(CurrentDate) Time=$(CurrentTime)
+statusbar.text.4=\
+$(FileNameExt) : $(FileDate) � $(FileTime) | $(FileAttr)
+
+if PLAT_WIN
+	command.scite.help="file://$(SciteDefaultHome)\SciTEDoc.html"
+	command.scite.help.subsystem=2
+if PLAT_GTK
+	command.print.*=a2ps "$(FileNameExt)"
+	command.scite.help=netscape "file://$(SciteDefaultHome)/SciTEDoc.html"
+
+# Internationalisation
+# Japanese input code page 932 and ShiftJIS character set 128
+#code.page=932
+#character.set=128
+# Unicode
+#code.page=65001
+code.page=0
+#character.set=204
+# Required for Unicode to work on GTK+:
+#LC_CTYPE=en_US.UTF-8
+
+# Export
+#export.keep.ext=1
+export.html.wysiwyg=1
+#export.html.tabs=1
+#export.html.folding=1
+export.html.styleused=1
+#export.html.title.fullpath=1
+#export.rtf.tabs=1
+#export.rtf.font.face=Arial
+#export.rtf.font.size=9
+#export.rtf.tabsize=8
+# Magnification (added to default screen font size)
+export.pdf.magnification=0
+# Font: Courier, Helvetica or Times (Courier line-wraps)
+export.pdf.font=Helvetica
+# Page size (in points): width, height
+# E.g. Letter 612,792; A4 595,842; maximum 14400,14400
+export.pdf.pagesize=595,842
+# Margins (in points): left, right, top, bottom
+export.pdf.margins=72,72,72,72
+export.xml.collapse.spaces=1
+export.xml.collapse.lines=1
+
+# Define values for use in the imported properties files
+chars.alpha=abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ
+chars.numeric=0123456789
+chars.accented=�������������������������������������������������������������������
+# This is a better set for Russian:
+#chars.accented=�����������娸����������������������������������������������������
+
+# The open.filter setting is only used on Windows where the file selector has a menu of filters to apply
+# to the types of files seen when opening.
+# There is a limit (possibly 256 characters) to the length of a filter,
+# so not all source extensions can be in this setting.
+source.files=*.asm;*.c;*.cc;*.cpp;*.cxx;*.cs;*.h;*.hh;*.hxx;*.hpp;\
+*.idl;*.odl;*.rc;*.rc2;*.dlg;*.def;\
+*.vb;*.vbs;*.bas;*.frm;*.cls;*.ctl;\
+*.java;*.js;*.py;*.pl;*.rb;*.cgi;*.lua;*.conf;\
+make*;*.mak;\
+*.properties;*.html;*.xml;*.iface;*.bat;*.e
+
+if PLAT_WIN
+	all.files=All Files (*.*)|*.*|
+if PLAT_GTK
+	all.files=All Files (*)|*|Hidden Files (.*)|.*|
+open.filter=\
+All Source|$(source.files)|\
+$(all.files)\
+$(filter.ada)\
+$(filter.conf)\
+$(filter.asm)\
+$(filter.asn1)\
+$(filter.ave)\
+$(filter.baan)\
+$(filter.bash)\
+$(filter.cpp)\
+$(filter.css)\
+$(filter.eiffel)\
+$(filter.erlang)\
+$(filter.fortran)\
+$(filter.idl)\
+$(filter.java)\
+$(filter.js)\
+$(filter.kix)\
+$(filter.lout)\
+$(filter.lua)\
+$(filter.matlab)\
+$(filter.metapost)\
+$(filter.mmixal)\
+$(filter.nncrontab)\
+$(filter.nsis)\
+$(filter.pascal)\
+$(filter.perl)\
+$(filter.php)\
+$(filter.pov)\
+$(filter.properties)\
+$(filter.ps)\
+$(filter.python)\
+$(filter.ruby)\
+$(filter.sql)\
+$(filter.specman)\
+$(filter.tcl)\
+$(filter.tex)\
+$(filter.text)\
+$(filter.vb)\
+$(filter.web)\
+$(filter.yaml)\
+$(filter.verilog)\
+$(filter.vhdl)
+
+# Give symbolic names to the set of fonts used in the standard styles.
+if PLAT_WIN
+	font.base=font:Verdana,size:10
+	font.small=font:Verdana,size:8
+	font.comment=font:Comic Sans MS,size:9
+	font.code.comment.box=$(font.comment)
+	font.code.comment.line=$(font.comment)
+	font.code.comment.doc=$(font.comment)
+	font.text=font:Times New Roman,size:11
+	font.text.comment=font:Verdana,size:9
+	font.embedded.base=font:Verdana,size:9
+	font.embedded.comment=font:Comic Sans MS,size:8
+	font.monospace=font:Courier New,size:10
+	font.vbs=font:Lucida Sans Unicode,size:10
+if PLAT_GTK
+	font.base=font:lucidatypewriter,size:12
+	font.small=font:lucidatypewriter,size:10
+	font.comment=font:new century schoolbook,size:12
+	font.code.comment.box=$(font.comment)
+	font.code.comment.line=$(font.comment)
+	font.code.comment.doc=$(font.comment)
+	font.text=font:times,size:14
+	font.text.comment=font:lucidatypewriter,size:10
+	font.embedded.base=font:lucidatypewriter,size:12
+	font.embedded.comment=font:lucidatypewriter,size:12
+	font.monospace=font:courier,size:12
+	font.vbs=font:new century schoolbook,size:12
+font.js=$(font.comment)
+
+# Give symbolic names to the set of colours used in the standard styles.
+colour.code.comment.box=fore:#007F00
+colour.code.comment.line=fore:#007F00
+colour.code.comment.doc=fore:#3F703F
+colour.text.comment=fore:#0000FF,back:#D0F0D0
+colour.other.comment=fore:#007F00
+colour.embedded.comment=back:#E0EEFF
+colour.embedded.js=back:#F0F0FF
+colour.notused=back:#FF0000
+
+colour.number=fore:#007F7F
+colour.keyword=fore:#00007F
+colour.string=fore:#7F007F
+colour.char=fore:#7F007F
+colour.operator=fore:#000000
+colour.preproc=fore:#7F7F00
+colour.error=fore:#FFFF00,back:#FF0000
+
+# Global default styles for all languages
+# Default
+style.*.32=$(font.base)
+# Line number
+style.*.33=back:#C0C0C0,$(font.base)
+# Brace highlight
+style.*.34=fore:#0000FF,bold
+# Brace incomplete highlight
+style.*.35=fore:#FF0000,bold
+# Control characters
+style.*.36=
+# Indentation guides
+style.*.37=fore:#C0C0C0,back:#FFFFFF
+
+# Printing - only works on Windows
+if PLAT_WIN
+	#print.colour.mode=1
+	print.magnification=-1
+	# Setup: left, right, top, bottom margins, in local units:
+	# hundredths of millimeters or thousandths of inches
+	print.margins=1500,1000,1000,1500
+	# Header/footer:
+	# && = &; &p = current page
+	# &f = file name; &F = full path
+	# &d = file date; &D = current date
+	# &t = file time; &T = full time
+	print.header.format=$(FileNameExt) � Printed on $(CurrentDate), $(CurrentTime) � Page $(CurrentPage)
+	print.footer.format=$(FilePath) � File date: $(FileDate) � File time: $(FileTime)
+	# Header/footer style
+	print.header.style=font:Arial,size:12,bold
+	print.footer.style=font:Arial Narrow,size:10,italics
+
+# Warnings - only works on Windows and needs to be pointed at files on machine
+#if PLAT_WIN
+#	warning.findwrapped=100,E:\Windows\Media\SFX\Boing.wav
+#	warning.notfound=0,Effect.wav
+#	warning.wrongfile=0,Glass.wav
+#	warning.executeok=0,Fanfare.wav
+#	warning.executeko=100,GlassBreak.wav
+#	warning.nootherbookmark=100,Boing2.wav
+
+# Define the Lexer menu,
+# Each item contains three parts: menu string | file extension | key
+# The only keys allowed currently are based on F-keys and alphabetic keys and look like
+# [Ctrl+][Shift+][Fn|a] such as F12 or Ctrl+Shift+D.
+# A '&' may be placed before a letter to be used as an accelerator. This does not work on GTK+.
+menu.language=\
+Text|txt|Shift+F11|\
+Ada|ads||\
+Apache Confi&g|conf||\
+Assembler|asm||\
+#ASN.1|asn1||\
+Avenue|ave||\
+Baan|bc||\
+&Batch|bat||\
+#Bullant|ant||\
+&C / C++|c||\
+C&#|cs||\
+CSS|css||\
+&Difference|diff||\
+&Eiffel|e||\
+Erlang|erl||\
+&Errorlist|err||\
+&Fortran|f90||\
+H&ypertext|html|F12|\
+&Java|java||\
+Java&Script|js||\
+#&Kix|kix||\
+TeX|tex||\
+Lisp|lisp||\
+Lot|lot||\
+#Lout|lt||\
+Lu&a|lua||\
+Matlab|m.matlab||\
+&Makefile|mak|Ctrl+Shift+F11|\
+MetaPost|mp||\
+MMIXAL|mms||\
+#&nnCron crontab|tab||\
+#NSIS|nsis||\
+Octave|m.octave||\
+Pascal|pas||\
+Pe&rl|pl||\
+P&HP|php||\
+P&LSQL|spec||\
+&Properties|properties||\
+P&ostScript|ps||\
+P&OV-Ray SDL|pov||\
+Pytho&n|py||\
+Reso&urce|rc||\
+Ruby|rb||\
+Shell|sh||\
+S&QL|sql||\
+#Specman|e||\
+&TCL|tcl||\
+&VB|vb||\
+VBScr&ipt|vbs||\
+#Verilog|v||\
+#VHDL|vhd||\
+&XML|xml|Shift+F12|\
+&YAML|yaml||
+
+
+# User defined key commands
+user.shortcuts=\
+Ctrl+Shift+V|IDM_PASTEANDDOWN|\
+Ctrl+PageUp|IDM_PREVFILE|\
+Ctrl+PageDown|IDM_NEXTFILE|
+
+#KeypadPlus|IDM_EXPAND|\
+#KeypadMinus|IDM_BLOCK_COMMENT|
+
+# Import all the language specific properties files
+import ada
+import asm
+#import asn1
+#import au3
+import ave
+import baan
+#import bullant
+import conf
+import cpp
+import css
+import eiffel
+import erlang
+import escript
+#import forth
+import fortran
+import html
+#import kix
+import lisp
+import lot
+#import lout
+import lua
+import matlab
+import metapost
+import mmixal
+#import nncrontab
+#import nsis
+import others
+import pascal
+import perl
+import pov
+import ps
+import python
+import ruby
+#import scriptol
+import sql
+#import specman
+import tcl
+import tex
+import vb
+import yaml
+#import verilog
+#import vhdl
+
diff -u -r -N scite-1.62-clean/scite/src/SciTEProps.cxx scite-1.62/scite/src/SciTEProps.cxx
--- scite-1.62-clean/scite/src/SciTEProps.cxx	2004-10-31 02:12:53.000000000 -0500
+++ scite-1.62/scite/src/SciTEProps.cxx	2005-03-17 23:15:43.155902766 -0500
@@ -1,1572 +1,1572 @@
-// SciTE - Scintilla based Text Editor
-/** @file SciTEProps.cxx
- ** Properties management.
- **/
-// Copyright 1998-2004 by Neil Hodgson <neilh@scintilla.org>
-// The License.txt file describes the conditions under which this software may be distributed.
-
-#include <stdlib.h>
-#include <string.h>
-#include <ctype.h>
-#include <stdio.h>
-#include <fcntl.h>
-#include <time.h>
-#include <locale.h>
-
-#include "Platform.h"
-
-#if PLAT_FOX
-
-#include <unistd.h>
-
-const char menuAccessIndicator[] = "&";
-
-#endif
-
-#if PLAT_GTK
-
-#include <unistd.h>
-#include <gtk/gtk.h>
-
-const char menuAccessIndicator[] = "_";
-
-#endif
-
-#if PLAT_WIN
-
-#define _WIN32_WINNT  0x0400
-#ifdef _MSC_VER
-// windows.h, et al, use a lot of nameless struct/unions - can't fix it, so allow it
-#pragma warning(disable: 4201)
-#endif
-#include <windows.h>
-#ifdef _MSC_VER
-// okay, that's done, don't allow it in our code
-#pragma warning(default: 4201)
-#endif
-#include <commctrl.h>
-
-// For getcwd
-#ifdef _MSC_VER
-#include <direct.h>
-#endif
-#ifdef __BORLANDC__
-#include <dir.h>
-#endif
-#ifdef __DMC__
-#include <dir.h>
-#endif
-
-const char menuAccessIndicator[] = "&";
-
-#endif
-
-#include "SciTE.h"
-#include "PropSet.h"
-#include "Accessor.h"
-#include "Scintilla.h"
-#include "SciLexer.h"
-#include "Extender.h"
-#include "SciTEBase.h"
-
-PropSetFile::PropSetFile(bool lowerKeys_) : lowerKeys(lowerKeys_) {}
-
-PropSetFile::~PropSetFile() {}
-
-/**
- * Get a line of input. If end of line escaped with '\\' then continue reading.
- */
-static bool GetFullLine(const char *&fpc, int &lenData, char *s, int len) {
-	bool continuation = true;
-	s[0] = '\0';
-	while ((len > 1) && lenData > 0) {
-		char ch = *fpc;
-		fpc++;
-		lenData--;
-		if ((ch == '\r') || (ch == '\n')) {
-			if (!continuation) {
-				if ((lenData > 0) && (ch == '\r') && ((*fpc) == '\n')) {
-					// munch the second half of a crlf
-					fpc++;
-					lenData--;
-				}
-				*s = '\0';
-				return true;
-			}
-		} else if ((ch == '\\') && (lenData > 0) && ((*fpc == '\r') || (*fpc == '\n'))) {
-			continuation = true;
-		} else {
-			continuation = false;
-			*s++ = ch;
-			*s = '\0';
-			len--;
-		}
-	}
-	return false;
-}
-
-static bool IsSpaceOrTab(char ch) {
-	return (ch == ' ') || (ch == '\t');
-}
-
-static bool IsCommentLine(const char *line) {
-	while (IsSpaceOrTab(*line)) ++line;
-	return (*line == '#');
-}
-
-bool PropSetFile::ReadLine(const char *lineBuffer, bool ifIsTrue, const char *directoryForImports,
-                           SString imports[], int sizeImports) {
-	//UnSlash(lineBuffer);
-	if (!IsSpaceOrTab(lineBuffer[0]))    // If clause ends with first non-indented line
-		ifIsTrue = true;
-	if (isprefix(lineBuffer, "if ")) {
-		const char *expr = lineBuffer + strlen("if") + 1;
-		ifIsTrue = GetInt(expr);
-	} else if (isprefix(lineBuffer, "import ") && directoryForImports) {
-		char importPath[1024];
-		strcpy(importPath, directoryForImports);
-		strcat(importPath, lineBuffer + strlen("import") + 1);
-		strcat(importPath, ".properties");
-		if (Read(importPath, directoryForImports, imports, sizeImports)) {
-			if (imports) {
-				for (int i = 0; i < sizeImports; i++) {
-					if (!imports[i].length()) {
-						imports[i] = importPath;
-						break;
-					}
-				}
-			}
-		}
-	} else if (ifIsTrue && !IsCommentLine(lineBuffer)) {
-		Set(lineBuffer);
-	}
-	return ifIsTrue;
-}
-
-void PropSetFile::ReadFromMemory(const char *data, int len, const char *directoryForImports,
-                                 SString imports[], int sizeImports) {
-	const char *pd = data;
-	char lineBuffer[60000];
-	bool ifIsTrue = true;
-	while (len > 0) {
-		GetFullLine(pd, len, lineBuffer, sizeof(lineBuffer));
-		if (lowerKeys) {
-			for (int i=0; lineBuffer[i] && (lineBuffer[i] != '='); i++) {
-				if ((lineBuffer[i] >= 'A') && (lineBuffer[i] <= 'Z')) {
-					lineBuffer[i] = static_cast<char>(lineBuffer[i] - 'A' + 'a');
-				}
-			}
-		}
-		ifIsTrue = ReadLine(lineBuffer, ifIsTrue, directoryForImports, imports, sizeImports);
-	}
-}
-
-bool PropSetFile::Read(const char *filename, const char *directoryForImports,
-                       SString imports[], int sizeImports) {
-	FILE *rcfile = fopen(filename, fileRead);
-	if (rcfile) {
-		char propsData[60000];
-		int lenFile = static_cast<int>(fread(propsData, 1, sizeof(propsData), rcfile));
-		fclose(rcfile);
-		ReadFromMemory(propsData, lenFile, directoryForImports, imports, sizeImports);
-		return true;
-	}
-	return false;
-}
-
-void PropSetFile::SetInteger(const char *key, sptr_t i) {
-	char tmp[32];
-	sprintf(tmp, "%d", static_cast<int>(i));
-	Set(key, tmp);
-}
-
-void SciTEBase::SetImportMenu() {
-	for (int i = 0; i < importMax; i++) {
-		DestroyMenuItem(menuOptions, importCmdID + i);
-	}
-	if (importFiles[0][0]) {
-		for (int stackPos = 0; stackPos < importMax; stackPos++) {
-			int itemID = importCmdID + stackPos;
-			if (importFiles[stackPos][0]) {
-				SString entry = LocaliseString("Open");
-				entry += " ";
-				const char *cpDirEnd = strrchr(importFiles[stackPos].c_str(), pathSepChar);
-				if (cpDirEnd) {
-					entry += cpDirEnd + 1;
-				} else {
-					entry += importFiles[stackPos];
-				}
-				SetMenuItem(menuOptions, IMPORT_START + stackPos, itemID, entry.c_str());
-			}
-		}
-	}
-}
-
-void SciTEBase::ImportMenu(int pos) {
-	//Platform::DebugPrintf("Stack menu %d\n", pos);
-	if (pos >= 0) {
-		if (importFiles[pos][0] != '\0') {
-			Open(importFiles[pos].c_str());
-		}
-	}
-}
-
-void SciTEBase::SetLanguageMenu() {
-	for (int i = 0; i < 100; i++) {
-		DestroyMenuItem(menuLanguage, languageCmdID + i);
-	}
-	for (int item = 0; item < languageItems; item++) {
-		int itemID = languageCmdID + item;
-		SString entry = LocaliseString(languageMenu[item].menuItem.c_str());
-		if (languageMenu[item].menuKey.length()) {
-#if PLAT_GTK
-			entry += " ";
-#else
-			entry += "\t";
-#endif
-			entry += languageMenu[item].menuKey;
-		}
-		if (entry[0] != '#') {
-			SetMenuItem(menuLanguage, item, itemID, entry.c_str());
-		}
-	}
-}
-
-const char propFileName[] = "SciTE.properties";
-
-void SciTEBase::ReadGlobalPropFile() {
-#ifdef unix
-	extern char **environ;
-	char **e=environ;
-#else
-	char **e=_environ;
-#endif
-	for (; *e; e++) {
-		char key[1024];
-		char *k=*e;
-		char *v=strchr(k,'=');
-		if (v && (static_cast<size_t>(v-k) < sizeof(key))) {
-			memcpy(key, k, v-k);
-			key[v-k] = '\0';
-			propsEmbed.Set(key, v+1);
-		}
-	}
-
-	for (int stackPos = 0; stackPos < importMax; stackPos++) {
-		importFiles[stackPos] = "";
-	}
-	char propfile[MAX_PATH + 20];
-	char propdir[MAX_PATH + 20];
-	propsBase.Clear();
-	if (GetDefaultPropertiesFileName(propfile, propdir, sizeof(propfile))) {
-		strcat(propdir, pathSepString);
-		propsBase.Read(propfile, propdir, importFiles, importMax);
-	}
-	propsUser.Clear();
-	if (GetUserPropertiesFileName(propfile, propdir, sizeof(propfile))) {
-		strcat(propdir, pathSepString);
-		propsUser.Read(propfile, propdir, importFiles, importMax);
-	}
-	if (!localisationRead) {
-		ReadLocalisation();
-	}
-}
-
-void SciTEBase::ReadAbbrevPropFile() {
-	char propfile[MAX_PATH + 20];
-	char propdir[MAX_PATH + 20];
-	propsAbbrev.Clear();
-	if (GetAbbrevPropertiesFileName(propfile, propdir, sizeof(propfile))) {
-		strcat(propdir, pathSepString);
-		propsAbbrev.Read(propfile, propdir, importFiles, importMax);
-	}
-}
-
-void ChopTerminalSlash(char *path) {
-	size_t endOfPath = strlen(path) - 1;
-	if (path[endOfPath] == pathSepChar) {
-		path[endOfPath] = '\0';
-	}
-}
-
-void SciTEBase::GetDocumentDirectory(char *docDir, int len) {
-	if (dirName[0]) {
-		strncpy(docDir, dirName, len);
-		docDir[len - 1] = '\0';
-	} else {
-		getcwd(docDir, len);
-		docDir[len - 1] = '\0';
-		// In Windows, getcwd returns a trailing backslash
-		// when the CWD is at the root of a disk, so remove it
-		ChopTerminalSlash(docDir);
-	}
-}
-
-void SciTEBase::ReadLocalPropFile() {
-	char propdir[MAX_PATH + 20];
-	GetDocumentDirectory(propdir, sizeof(propdir));
-	char propfile[MAX_PATH + 20];
-	strcpy(propfile, propdir);
-#ifndef __vms
-
-	strcat(propdir, pathSepString);
-	strcat(propfile, pathSepString);
-#endif
-
-	strcat(propfile, propFileName);
-	propsLocal.Clear();
-	propsLocal.Read(propfile, propdir);
-	//Platform::DebugPrintf("Reading local properties from %s\n", propfile);
-
-	// TODO: Grab these from Platform and update when environment says to
-	props.Set("Chrome", "#C0C0C0");
-	props.Set("ChromeHighlight", "#FFFFFF");
-}
-
-int IntFromHexDigit(const char ch) {
-	if (isdigit(ch)) {
-		return ch - '0';
-	} else if (ch >= 'A' && ch <= 'F') {
-		return ch - 'A' + 10;
-	} else if (ch >= 'a' && ch <= 'f') {
-		return ch - 'a' + 10;
-	} else {
-		return 0;
-	}
-}
-
-int IntFromHexByte(const char *hexByte) {
-	return IntFromHexDigit(hexByte[0]) * 16 + IntFromHexDigit(hexByte[1]);
-}
-
-static long ColourFromString(const SString &s) {
-	if (s.length()) {
-		int r = IntFromHexByte(s.c_str() + 1);
-		int g = IntFromHexByte(s.c_str() + 3);
-		int b = IntFromHexByte(s.c_str() + 5);
-		return ColourDesired(r, g, b).AsLong();
-	} else {
-		return ColourDesired().AsLong();
-	}
-}
-
-long ColourOfProperty(PropSet &props, const char *key, ColourDesired colourDefault) {
-	SString colour = props.Get(key);
-	if (colour.length()) {
-		return ColourFromString(colour);
-	}
-	return colourDefault.AsLong();
-}
-
-/**
- * Put the next property item from the given property string
- * into the buffer pointed by @a pPropItem.
- * @return NULL if the end of the list is met, else, it points to the next item.
- */
-const char *SciTEBase::GetNextPropItem(
-	const char *pStart,	/**< the property string to parse for the first call,
-						 * pointer returned by the previous call for the following. */
-	char *pPropItem,	///< pointer on a buffer receiving the requested prop item
-	int maxLen)			///< size of the above buffer
-{
-	int size = maxLen - 1;
-
-	*pPropItem = '\0';
-	if (pStart == NULL) {
-		return NULL;
-	}
-	const char *pNext = strchr(pStart, ',');
-	if (pNext) {	// Separator is found
-		if (size > pNext - pStart) {
-			// Found string fits in buffer
-			size = pNext - pStart;
-		}
-		pNext++;
-	}
-	strncpy(pPropItem, pStart, size);
-	pPropItem[size] = '\0';
-	return pNext;
-}
-
-StyleDefinition::StyleDefinition(const char *definition) :
-		size(0), fore("#000000"), back("#FFFFFF"),
-		bold(false), italics(false), eolfilled(false), underlined(false),
-		caseForce(SC_CASE_MIXED),
-		visible(true), changeable(true),
-		specified(sdNone) {
-	ParseStyleDefinition(definition);
-}
-
-bool StyleDefinition::ParseStyleDefinition(const char *definition) {
-	if (definition == 0 || *definition == '\0') {
-		return false;
-	}
-	char *val = StringDup(definition);
-	//Platform::DebugPrintf("Style %d is [%s]\n", style, val);
-	char *opt = val;
-	while (opt) {
-		// Find attribute separator
-		char *cpComma = strchr(opt, ',');
-		if (cpComma) {
-			// If found, we terminate the current attribute (opt) string
-			*cpComma = '\0';
-		}
-		// Find attribute name/value separator
-		char *colon = strchr(opt, ':');
-		if (colon) {
-			// If found, we terminate the current attribute name and point on the value
-			*colon++ = '\0';
-		}
-		if (0 == strcmp(opt, "italics")) {
-			specified = static_cast<flags>(specified | sdItalics);
-			italics = true;
-		}
-		if (0 == strcmp(opt, "notitalics")) {
-			specified = static_cast<flags>(specified | sdItalics);
-			italics = false;
-		}
-		if (0 == strcmp(opt, "bold")) {
-			specified = static_cast<flags>(specified | sdBold);
-			bold = true;
-		}
-		if (0 == strcmp(opt, "notbold")) {
-			specified = static_cast<flags>(specified | sdBold);
-			bold = false;
-		}
-		if (0 == strcmp(opt, "font")) {
-			specified = static_cast<flags>(specified | sdFont);
-			font = colon;
-			font.substitute('|', ',');
-		}
-		if (0 == strcmp(opt, "fore")) {
-			specified = static_cast<flags>(specified | sdFore);
-			fore = colon;
-		}
-		if (0 == strcmp(opt, "back")) {
-			specified = static_cast<flags>(specified | sdBack);
-			back = colon;
-		}
-		if (0 == strcmp(opt, "size")) {
-			specified = static_cast<flags>(specified | sdSize);
-			size = atoi(colon);
-		}
-		if (0 == strcmp(opt, "eolfilled")) {
-			specified = static_cast<flags>(specified | sdEOLFilled);
-			eolfilled = true;
-		}
-		if (0 == strcmp(opt, "noteolfilled")) {
-			specified = static_cast<flags>(specified | sdEOLFilled);
-			eolfilled = false;
-		}
-		if (0 == strcmp(opt, "underlined")) {
-			specified = static_cast<flags>(specified | sdUnderlined);
-			underlined = true;
-		}
-		if (0 == strcmp(opt, "notunderlined")) {
-			specified = static_cast<flags>(specified | sdUnderlined);
-			underlined = false;
-		}
-		if (0 == strcmp(opt, "case")) {
-			specified = static_cast<flags>(specified | sdCaseForce);
-			caseForce = SC_CASE_MIXED;
-			if (colon) {
-				if (*colon == 'u')
-					caseForce = SC_CASE_UPPER;
-				else if (*colon == 'l')
-					caseForce = SC_CASE_LOWER;
-			}
-		}
-		if (0 == strcmp(opt, "visible")) {
-			specified = static_cast<flags>(specified | sdVisible);
-			visible = true;
-		}
-		if (0 == strcmp(opt, "notvisible")) {
-			specified = static_cast<flags>(specified | sdVisible);
-			visible = false;
-		}
-		if (0 == strcmp(opt, "changeable")) {
-			specified = static_cast<flags>(specified | sdChangeable);
-			changeable = true;
-		}
-		if (0 == strcmp(opt, "notchangeable")) {
-			specified = static_cast<flags>(specified | sdChangeable);
-			changeable = false;
-		}
-		if (cpComma)
-			opt = cpComma + 1;
-		else
-			opt = 0;
-	}
-	delete []val;
-	return true;
-}
-
-long StyleDefinition::ForeAsLong() const {
-	return ColourFromString(fore);
-}
-
-long StyleDefinition::BackAsLong() const {
-	return ColourFromString(back);
-}
-
-void SciTEBase::SetOneStyle(Window &win, int style, const StyleDefinition &sd) {
-	if (sd.specified & StyleDefinition::sdItalics)
-		Platform::SendScintilla(win.GetID(), SCI_STYLESETITALIC, style, sd.italics ? 1 : 0);
-	if (sd.specified & StyleDefinition::sdBold)
-		Platform::SendScintilla(win.GetID(), SCI_STYLESETBOLD, style, sd.bold ? 1 : 0);
-	if (sd.specified & StyleDefinition::sdFont)
-		Platform::SendScintillaPointer(win.GetID(), SCI_STYLESETFONT, style,
-			const_cast<char *>(sd.font.c_str()));
-	if (sd.specified & StyleDefinition::sdFore)
-		Platform::SendScintilla(win.GetID(), SCI_STYLESETFORE, style, sd.ForeAsLong());
-	if (sd.specified & StyleDefinition::sdBack)
-		Platform::SendScintilla(win.GetID(), SCI_STYLESETBACK, style, sd.BackAsLong());
-	if (sd.specified & StyleDefinition::sdSize)
-		Platform::SendScintilla(win.GetID(), SCI_STYLESETSIZE, style, sd.size);
-	if (sd.specified & StyleDefinition::sdEOLFilled)
-		Platform::SendScintilla(win.GetID(), SCI_STYLESETEOLFILLED, style, sd.eolfilled ? 1 : 0);
-	if (sd.specified & StyleDefinition::sdUnderlined)
-		Platform::SendScintilla(win.GetID(), SCI_STYLESETUNDERLINE, style, sd.underlined ? 1 : 0);
-	if (sd.specified & StyleDefinition::sdCaseForce)
-		Platform::SendScintilla(win.GetID(), SCI_STYLESETCASE, style, sd.caseForce);
-	if (sd.specified & StyleDefinition::sdVisible)
-		Platform::SendScintilla(win.GetID(), SCI_STYLESETVISIBLE, style, sd.visible ? 1 : 0);
-	if (sd.specified & StyleDefinition::sdChangeable)
-		Platform::SendScintilla(win.GetID(), SCI_STYLESETCHANGEABLE, style, sd.changeable ? 1 : 0);
-	Platform::SendScintilla(win.GetID(), SCI_STYLESETCHARACTERSET, style, characterSet);
-}
-
-void SciTEBase::SetStyleFor(Window &win, const char *lang) {
-	for (int style = 0; style <= STYLE_MAX; style++) {
-		if (style != STYLE_DEFAULT) {
-			char key[200];
-			sprintf(key, "style.%s.%0d", lang, style);
-			SString sval = props.GetExpanded(key);
-			SetOneStyle(win, style, sval.c_str());
-		}
-	}
-}
-
-void LowerCaseString(char *s) {
-	while (*s) {
-		*s = static_cast<char>(tolower(*s));
-		s++;
-	}
-}
-
-SString SciTEBase::ExtensionFileName() {
-	if (overrideExtension.length())
-		return overrideExtension;
-	else if (fileName[0]) {
-		// Force extension to lower case
-		char fileNameWithLowerCaseExtension[MAX_PATH];
-		strcpy(fileNameWithLowerCaseExtension, fileName);
-		char *extension = strrchr(fileNameWithLowerCaseExtension, '.');
-		if (extension) {
-			LowerCaseString(extension);
-		}
-		return SString(fileNameWithLowerCaseExtension);
-	} else
-		return props.Get("default.file.ext");
-}
-
-void SciTEBase::ForwardPropertyToEditor(const char *key) {
-	SString value = props.Get(key);
-	SendEditorString(SCI_SETPROPERTY,
-	                 reinterpret_cast<uptr_t>(key), value.c_str());
-}
-
-void SciTEBase::DefineMarker(int marker, int markerType, ColourDesired fore, ColourDesired back) {
-	SendEditor(SCI_MARKERDEFINE, marker, markerType);
-	SendEditor(SCI_MARKERSETFORE, marker, fore.AsLong());
-	SendEditor(SCI_MARKERSETBACK, marker, back.AsLong());
-}
-
-static int FileLength(const char *path) {
-	int len = 0;
-	FILE *fp = fopen(path, fileRead);
-	if (fp) {
-		fseek(fp, 0, SEEK_END);
-		len = ftell(fp);
-		fclose(fp);
-	}
-	return len;
-}
-
-void SciTEBase::ReadAPI(const SString &fileNameForExtension) {
-	SString apisFileNames = props.GetNewExpand("api.",
-	                        fileNameForExtension.c_str());
-	size_t nameLength = apisFileNames.length();
-	if (nameLength) {
-		apisFileNames.substitute(';', '\0');
-		const char *apiFileName = apisFileNames.c_str();
-		const char *nameEnd = apiFileName + nameLength;
-
-		int tlen = 0;    // total api length
-
-		// Calculate total length
-		while (apiFileName < nameEnd) {
-			tlen += FileLength(apiFileName);
-			apiFileName += strlen(apiFileName) + 1;
-		}
-
-		// Load files
-		if (tlen > 0) {
-			char *buffer = apis.Allocate(tlen);
-			if (buffer) {
-				apiFileName = apisFileNames.c_str();
-				tlen = 0;
-				while (apiFileName < nameEnd) {
-					FILE *fp = fopen(apiFileName, fileRead);
-					if (fp) {
-						fseek(fp, 0, SEEK_END);
-						int len = ftell(fp);
-						fseek(fp, 0, SEEK_SET);
-						fread(buffer + tlen, 1, len, fp);
-						tlen += len;
-						fclose(fp);
-					}
-					apiFileName += strlen(apiFileName) + 1;
-				}
-				apis.SetFromAllocated();
-			}
-		}
-	}
-}
-
-SString SciTEBase::FindLanguageProperty(const char *pattern, const char *defaultValue) {
-	SString key = pattern;
-	key.substitute("*", language.c_str());
-	SString ret = props.GetExpanded(key.c_str());
-	if (ret == "")
-		ret = props.GetExpanded(pattern);
-	if (ret == "")
-		ret = defaultValue;
-	return ret;
-}
-
-/**
- * A list of all the properties that should be forwarded to Scintilla lexers.
- */
-static const char *propertiesToForward[] = {
-	"fold",
-	"fold.comment",
-	"fold.comment.python",
-	"fold.compact",
-	"fold.at.else",
-	"fold.html",
-	"fold.html.preprocessor",
-	"fold.preprocessor",
-	"fold.quotes.python",
-	"fold.verilog.flags",
-	"styling.within.preprocessor",
-	"tab.timmy.whinge.level",
-	"asp.default.language",
-	"html.tags.case.sensitive",
-	"ps.level",
-	"ps.tokenize",
-	"sql.backslash.escapes",
-
-	"lexer.tex.interface.default",
-	"lexer.tex.comment.process",
-	"lexer.tex.auto.if",
-	"lexer.tex.use.keywords",
-	"lexer.metapost.interface.default",
-	"lexer.metapost.comment.process",
-	"nsis.uservars",
-	"nsis.ignorecase",
-
-	0,
-};
-
-void SciTEBase::ReadProperties() {
-	if (extender)
-		extender->Clear();
-
-	SString fileNameForExtension = ExtensionFileName();
-
-	SString modulePath = props.GetNewExpand("lexerpath.",
-	    fileNameForExtension.c_str());
-	if (modulePath.length())
-	    SendEditorString(SCI_LOADLEXERLIBRARY, 0, modulePath.c_str());
-	language = props.GetNewExpand("lexer.", fileNameForExtension.c_str());
-	if (language.length())
-	    SendEditorString(SCI_SETLEXERLANGUAGE, 0, language.c_str());
-	else
-	    SendEditorString(SCI_SETLEXER, 0, SCLEX_CONTAINER);
-
-	lexLanguage = SendEditor(SCI_GETLEXER);
-
-	if ((lexLanguage == SCLEX_HTML) || (lexLanguage == SCLEX_XML) ||
-	        (lexLanguage == SCLEX_ASP) || (lexLanguage == SCLEX_PHP))
-		SendEditor(SCI_SETSTYLEBITS, 7);
-	else
-		SendEditor(SCI_SETSTYLEBITS, 5);
-
-	SendOutput(SCI_SETLEXER, SCLEX_ERRORLIST);
-
-	SString kw0 = props.GetNewExpand("keywords.", fileNameForExtension.c_str());
-	SendEditorString(SCI_SETKEYWORDS, 0, kw0.c_str());
-
-	for (int wl = 1; wl <= KEYWORDSET_MAX; wl++) {
-		SString kwk(wl+1);
-		kwk += '.';
-		kwk.insert(0, "keywords");
-		SString kw = props.GetNewExpand(kwk.c_str(), fileNameForExtension.c_str());
-		SendEditorString(SCI_SETKEYWORDS, wl, kw.c_str());
-	}
-
-	char homepath[MAX_PATH + 20];
-	if (GetSciteDefaultHome(homepath, sizeof(homepath))) {
-		props.Set("SciteDefaultHome", homepath);
-	}
-	if (GetSciteUserHome(homepath, sizeof(homepath))) {
-		props.Set("SciteUserHome", homepath);
-	}
-
-	for (size_t i=0; propertiesToForward[i]; i++) {
-		ForwardPropertyToEditor(propertiesToForward[i]);
-	}
-
-	if (apisFileNames != props.GetNewExpand("api.",	fileNameForExtension.c_str())) {
-		apis.Clear();
-		ReadAPI(fileNameForExtension);
-		apisFileNames = props.GetNewExpand("api.", fileNameForExtension.c_str());
-	}
-
-	if (!props.GetInt("eol.auto")) {
-		SetEol();
-	}
-
-	codePage = props.GetInt("code.page");
-	if (unicodeMode != uni8Bit) {
-		// Override properties file to ensure Unicode displayed.
-		codePage = SC_CP_UTF8;
-	}
-	SendEditor(SCI_SETCODEPAGE, codePage);
-	SendOutput(SCI_SETCODEPAGE, codePage);
-
-	characterSet = props.GetInt("character.set");
-
-#ifdef unix
-	SString localeCType = props.Get("LC_CTYPE");
-	if (localeCType.length())
-		setlocale(LC_CTYPE, localeCType.c_str());
-	else
-		setlocale(LC_CTYPE, "C");
-#endif
-
-	SendEditor(SCI_SETCARETFORE,
-	           ColourOfProperty(props, "caret.fore", ColourDesired(0, 0, 0)));
-
-	SendEditor(SCI_SETMOUSEDWELLTIME,
-	           props.GetInt("dwell.period", SC_TIME_FOREVER), 0);
-
-	SendEditor(SCI_SETCARETWIDTH, props.GetInt("caret.width", 1));
-	SendOutput(SCI_SETCARETWIDTH, props.GetInt("caret.width", 1));
-
-	SString caretLineBack = props.Get("caret.line.back");
-	if (caretLineBack.length()) {
-		SendEditor(SCI_SETCARETLINEVISIBLE, 1);
-		SendEditor(SCI_SETCARETLINEBACK, ColourFromString(caretLineBack));
-	} else {
-		SendEditor(SCI_SETCARETLINEVISIBLE, 0);
-	}
-
-	SString controlCharSymbol = props.Get("control.char.symbol");
-	if (controlCharSymbol.length()) {
-		SendEditor(SCI_SETCONTROLCHARSYMBOL, static_cast<unsigned char>(controlCharSymbol[0]));
-	} else {
-		SendEditor(SCI_SETCONTROLCHARSYMBOL, 0);
-	}
-
-	SendEditor(SCI_CALLTIPSETBACK,
-	           ColourOfProperty(props, "calltip.back", ColourDesired(0xff, 0xff, 0xff)));
-
-	SString caretPeriod = props.Get("caret.period");
-	if (caretPeriod.length()) {
-		SendEditor(SCI_SETCARETPERIOD, caretPeriod.value());
-		SendOutput(SCI_SETCARETPERIOD, caretPeriod.value());
-	}
-
-	int caretSlop = props.GetInt("caret.policy.xslop", 1) ? CARET_SLOP : 0;
-	int caretZone = props.GetInt("caret.policy.width", 50);
-	int caretStrict = props.GetInt("caret.policy.xstrict") ? CARET_STRICT : 0;
-	int caretEven = props.GetInt("caret.policy.xeven", 1) ? CARET_EVEN : 0;
-	int caretJumps = props.GetInt("caret.policy.xjumps") ? CARET_JUMPS : 0;
-	SendEditor(SCI_SETXCARETPOLICY, caretStrict | caretSlop | caretEven | caretJumps, caretZone);
-
-	caretSlop = props.GetInt("caret.policy.yslop", 1) ? CARET_SLOP : 0;
-	caretZone = props.GetInt("caret.policy.lines");
-	caretStrict = props.GetInt("caret.policy.ystrict") ? CARET_STRICT : 0;
-	caretEven = props.GetInt("caret.policy.yeven", 1) ? CARET_EVEN : 0;
-	caretJumps = props.GetInt("caret.policy.yjumps") ? CARET_JUMPS : 0;
-	SendEditor(SCI_SETYCARETPOLICY, caretStrict | caretSlop | caretEven | caretJumps, caretZone);
-
-	int visibleStrict = props.GetInt("visible.policy.strict") ? VISIBLE_STRICT : 0;
-	int visibleSlop = props.GetInt("visible.policy.slop", 1) ? VISIBLE_SLOP : 0;
-	int visibleLines = props.GetInt("visible.policy.lines");
-	SendEditor(SCI_SETVISIBLEPOLICY, visibleStrict | visibleSlop, visibleLines);
-
-	SendEditor(SCI_SETEDGECOLUMN, props.GetInt("edge.column", 0));
-	SendEditor(SCI_SETEDGEMODE, props.GetInt("edge.mode", EDGE_NONE));
-	SendEditor(SCI_SETEDGECOLOUR,
-	           ColourOfProperty(props, "edge.colour", ColourDesired(0xff, 0xda, 0xda)));
-
-	SString selFore = props.Get("selection.fore");
-	if (selFore.length()) {
-		SendChildren(SCI_SETSELFORE, 1, ColourFromString(selFore));
-	} else {
-		SendChildren(SCI_SETSELFORE, 0, 0);
-	}
-	SString selBack = props.Get("selection.back");
-	if (selBack.length()) {
-		SendChildren(SCI_SETSELBACK, 1, ColourFromString(selBack));
-	} else {
-		if (selFore.length())
-			SendChildren(SCI_SETSELBACK, 0, 0);
-		else	// Have to show selection somehow
-			SendChildren(SCI_SETSELBACK, 1, ColourDesired(0xC0, 0xC0, 0xC0).AsLong());
-	}
-
-	SString foldColour = props.Get("fold.margin.colour");
-	if (foldColour.length()) {
-		SendChildren(SCI_SETFOLDMARGINCOLOUR, 1, ColourFromString(foldColour));
-	} else {
-		SendChildren(SCI_SETFOLDMARGINCOLOUR, 0, 0);
-	}
-	SString foldHiliteColour = props.Get("fold.margin.highlight.colour");
-	if (foldHiliteColour.length()) {
-		SendChildren(SCI_SETFOLDMARGINHICOLOUR, 1, ColourFromString(foldHiliteColour));
-	} else {
-		SendChildren(SCI_SETFOLDMARGINHICOLOUR, 0, 0);
-	}
-
-	SString whitespaceFore = props.Get("whitespace.fore");
-	if (whitespaceFore.length()) {
-		SendChildren(SCI_SETWHITESPACEFORE, 1, ColourFromString(whitespaceFore));
-	} else {
-		SendChildren(SCI_SETWHITESPACEFORE, 0, 0);
-	}
-	SString whitespaceBack = props.Get("whitespace.back");
-	if (whitespaceBack.length()) {
-		SendChildren(SCI_SETWHITESPACEBACK, 1, ColourFromString(whitespaceBack));
-	} else {
-		SendChildren(SCI_SETWHITESPACEBACK, 0, 0);
-	}
-
-	char bracesStyleKey[200];
-	sprintf(bracesStyleKey, "braces.%s.style", language.c_str());
-	bracesStyle = props.GetInt(bracesStyleKey, 0);
-
-	char key[200];
-	SString sval;
-
-	sval = FindLanguageProperty("calltip.*.ignorecase");
-	callTipIgnoreCase = sval == "1";
-
-	calltipWordCharacters = FindLanguageProperty("calltip.*.word.characters",
-		"_abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ");
-
-	calltipParametersStart = FindLanguageProperty("calltip.*.parameters.start", "(");
-	calltipParametersEnd = FindLanguageProperty("calltip.*.parameters.end", ")");
-	calltipParametersSeparators = FindLanguageProperty("calltip.*.parameters.separators", ",;");
-
-	calltipEndDefinition = FindLanguageProperty("calltip.*.end.definition");
-
-	sprintf(key, "autocomplete.%s.start.characters", language.c_str());
-	autoCompleteStartCharacters = props.GetExpanded(key);
-	if (autoCompleteStartCharacters == "")
-		autoCompleteStartCharacters = props.GetExpanded("autocomplete.*.start.characters");
-	// "" is a quite reasonable value for this setting
-
-	sprintf(key, "autocomplete.%s.fillups", language.c_str());
-	autoCompleteFillUpCharacters = props.GetExpanded(key);
-	if (autoCompleteFillUpCharacters == "")
-		autoCompleteFillUpCharacters =
-			props.GetExpanded("autocomplete.*.fillups");
-	SendEditorString(SCI_AUTOCSETFILLUPS, 0,
-		autoCompleteFillUpCharacters.c_str());
-
-	sprintf(key, "autocomplete.%s.ignorecase", "*");
-	sval = props.GetNewExpand(key);
-	autoCompleteIgnoreCase = sval == "1";
-	sprintf(key, "autocomplete.%s.ignorecase", language.c_str());
-	sval = props.GetNewExpand(key);
-	if (sval != "")
-		autoCompleteIgnoreCase = sval == "1";
-	SendEditor(SCI_AUTOCSETIGNORECASE, autoCompleteIgnoreCase ? 1 : 0);
-
-	int autoCChooseSingle = props.GetInt("autocomplete.choose.single");
-	SendEditor(SCI_AUTOCSETCHOOSESINGLE, autoCChooseSingle),
-
-	SendEditor(SCI_AUTOCSETCANCELATSTART, 0);
-	SendEditor(SCI_AUTOCSETDROPRESTOFWORD, 0);
-
-	if (firstPropertiesRead) {
-		ReadPropertiesInitial();
-	}
-
-	ReadFontProperties();
-
-	SendEditor(SCI_SETUSEPALETTE, props.GetInt("use.palette"));
-	SendEditor(SCI_SETPRINTMAGNIFICATION, props.GetInt("print.magnification"));
-	SendEditor(SCI_SETPRINTCOLOURMODE, props.GetInt("print.colour.mode"));
-
-	clearBeforeExecute = props.GetInt("clear.before.execute");
-	timeCommands = props.GetInt("time.commands");
-
-	int blankMarginLeft = props.GetInt("blank.margin.left", 1);
-	int blankMarginRight = props.GetInt("blank.margin.right", 1);
-	SendEditor(SCI_SETMARGINLEFT, 0, blankMarginLeft);
-	SendEditor(SCI_SETMARGINRIGHT, 0, blankMarginRight);
-	SendOutput(SCI_SETMARGINLEFT, 0, blankMarginLeft);
-	SendOutput(SCI_SETMARGINRIGHT, 0, blankMarginRight);
-
-	SendEditor(SCI_SETMARGINWIDTHN, 1, margin ? marginWidth : 0);
-
-	SString lineMarginProp = props.Get("line.margin.width");
-	lineNumbersWidth = lineMarginProp.value();
-	if (lineNumbersWidth == 0)
-		lineNumbersWidth = lineNumbersWidthDefault;
-	lineNumbersExpand = lineMarginProp.contains('+');
-
-	SetLineNumberWidth();
-
-	bufferedDraw = props.GetInt("buffered.draw", 1);
-	SendEditor(SCI_SETBUFFEREDDRAW, bufferedDraw);
-
-	twoPhaseDraw = props.GetInt("two.phase.draw", 1);
-	SendEditor(SCI_SETTWOPHASEDRAW, twoPhaseDraw);
-
-	SendEditor(SCI_SETLAYOUTCACHE, props.GetInt("cache.layout"));
-	SendOutput(SCI_SETLAYOUTCACHE, props.GetInt("output.cache.layout"));
-
-	bracesCheck = props.GetInt("braces.check");
-	bracesSloppy = props.GetInt("braces.sloppy");
-
-	SendEditor(SCI_SETCHARSDEFAULT);
-	wordCharacters = props.GetNewExpand("word.characters.", fileNameForExtension.c_str());
-	if (wordCharacters.length()) {
-		SendEditorString(SCI_SETWORDCHARS, 0, wordCharacters.c_str());
-	} else {
-		wordCharacters = "_abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ";
-	}
-
-	whitespaceCharacters = props.GetNewExpand("whitespace.characters.", fileNameForExtension.c_str());
-	if (whitespaceCharacters.length()) {
-		SendEditorString(SCI_SETWHITESPACECHARS, 0, whitespaceCharacters.c_str());
-	}
-
-	SendEditor(SCI_SETTABINDENTS, props.GetInt("tab.indents", 1));
-	SendEditor(SCI_SETBACKSPACEUNINDENTS, props.GetInt("backspace.unindents", 1));
-
-	indentOpening = props.GetInt("indent.opening");
-	indentClosing = props.GetInt("indent.closing");
-	indentMaintain = props.GetNewExpand("indent.maintain.", fileNameForExtension.c_str()).value();
-
-	SString lookback = props.GetNewExpand("statement.lookback.", fileNameForExtension.c_str());
-	statementLookback = lookback.value();
-	statementIndent = GetStyleAndWords("statement.indent.");
-	statementEnd = GetStyleAndWords("statement.end.");
-	blockStart = GetStyleAndWords("block.start.");
-	blockEnd = GetStyleAndWords("block.end.");
-
-	SString list;
-	list = props.GetNewExpand("preprocessor.symbol.", fileNameForExtension.c_str());
-	preprocessorSymbol = list[0];
-	list = props.GetNewExpand("preprocessor.start.", fileNameForExtension.c_str());
-	preprocCondStart.Clear();
-	preprocCondStart.Set(list.c_str());
-	list = props.GetNewExpand("preprocessor.middle.", fileNameForExtension.c_str());
-	preprocCondMiddle.Clear();
-	preprocCondMiddle.Set(list.c_str());
-	list = props.GetNewExpand("preprocessor.end.", fileNameForExtension.c_str());
-	preprocCondEnd.Clear();
-	preprocCondEnd.Set(list.c_str());
-
-	memFiles.AppendList(props.GetNewExpand("find.files"));
-
-	SendEditor(SCI_SETWRAPVISUALFLAGS, props.GetInt("wrap.visual.flags"));
-	SendEditor(SCI_SETWRAPVISUALFLAGSLOCATION, props.GetInt("wrap.visual.flags.location"));
- 	SendEditor(SCI_SETWRAPSTARTINDENT, props.GetInt("wrap.visual.startindent"));
-
-	if (props.GetInt("wrap.aware.home.end.keys",0)) {
-		if (props.GetInt("vc.home.key", 1)) {
-			AssignKey(SCK_HOME, 0, SCI_VCHOMEWRAP);
-			AssignKey(SCK_HOME, SCMOD_SHIFT, SCI_VCHOMEWRAPEXTEND);
-			AssignKey(SCK_HOME, SCMOD_SHIFT | SCMOD_ALT, SCI_VCHOMERECTEXTEND);
-		} else {
-			AssignKey(SCK_HOME, 0, SCI_HOMEWRAP);
-			AssignKey(SCK_HOME, SCMOD_SHIFT, SCI_HOMEWRAPEXTEND);
-			AssignKey(SCK_HOME, SCMOD_SHIFT | SCMOD_ALT, SCI_HOMERECTEXTEND);
-		}
-		AssignKey(SCK_END, 0, SCI_LINEENDWRAP);
-		AssignKey(SCK_END, SCMOD_SHIFT, SCI_LINEENDWRAPEXTEND);
-	} else {
-		if (props.GetInt("vc.home.key", 1)) {
-			AssignKey(SCK_HOME, 0, SCI_VCHOME);
-			AssignKey(SCK_HOME, SCMOD_SHIFT, SCI_VCHOMEEXTEND);
-			AssignKey(SCK_HOME, SCMOD_SHIFT | SCMOD_ALT, SCI_VCHOMERECTEXTEND);
-		} else {
-			AssignKey(SCK_HOME, 0, SCI_HOME);
-			AssignKey(SCK_HOME, SCMOD_SHIFT, SCI_HOMEEXTEND);
-			AssignKey(SCK_HOME, SCMOD_SHIFT | SCMOD_ALT, SCI_HOMERECTEXTEND);
-		}
-		AssignKey(SCK_END, 0, SCI_LINEEND);
-		AssignKey(SCK_END, SCMOD_SHIFT, SCI_LINEENDEXTEND);
-	}
-
-	AssignKey('L', SCMOD_SHIFT | SCMOD_CTRL, SCI_LINEDELETE);
-
-	scrollOutput = props.GetInt("output.scroll", 1);
-
-	tabHideOne = props.GetInt("tabbar.hide.one");
-
-	SetToolsMenu();
-
-	SendEditor(SCI_SETFOLDFLAGS, props.GetInt("fold.flags"));
-
-	// To put the folder markers in the line number region
-	//SendEditor(SCI_SETMARGINMASKN, 0, SC_MASK_FOLDERS);
-
-	SendEditor(SCI_SETMODEVENTMASK, SC_MOD_CHANGEFOLD);
-
-	if (0==props.GetInt("undo.redo.lazy")) {
-		// Trap for insert/delete notifications (also fired by undo
-		// and redo) so that the buttons can be enabled if needed.
-		SendEditor(SCI_SETMODEVENTMASK, SC_MOD_INSERTTEXT | SC_MOD_DELETETEXT
-			| SC_LASTSTEPINUNDOREDO | SendEditor(SCI_GETMODEVENTMASK, 0));
-
-		//SC_LASTSTEPINUNDOREDO is probably not needed in the mask; it
-		//doesn't seem to fire as an event of its own; just modifies the
-		//insert and delete events.
-	}
-
-	// Create a margin column for the folding symbols
-	SendEditor(SCI_SETMARGINTYPEN, 2, SC_MARGIN_SYMBOL);
-
-	SendEditor(SCI_SETMARGINWIDTHN, 2, foldMargin ? foldMarginWidth : 0);
-
-	SendEditor(SCI_SETMARGINMASKN, 2, SC_MASK_FOLDERS);
-	SendEditor(SCI_SETMARGINSENSITIVEN, 2, 1);
-
-	switch (props.GetInt("fold.symbols")) {
-	case 0:
-		// Arrow pointing right for contracted folders, arrow pointing down for expanded
-		DefineMarker(SC_MARKNUM_FOLDEROPEN, SC_MARK_ARROWDOWN,
-		             ColourDesired(0, 0, 0), ColourDesired(0, 0, 0));
-		DefineMarker(SC_MARKNUM_FOLDER, SC_MARK_ARROW,
-		             ColourDesired(0, 0, 0), ColourDesired(0, 0, 0));
-		DefineMarker(SC_MARKNUM_FOLDERSUB, SC_MARK_EMPTY,
-		             ColourDesired(0, 0, 0), ColourDesired(0, 0, 0));
-		DefineMarker(SC_MARKNUM_FOLDERTAIL, SC_MARK_EMPTY,
-		             ColourDesired(0, 0, 0), ColourDesired(0, 0, 0));
-		DefineMarker(SC_MARKNUM_FOLDEREND, SC_MARK_EMPTY,
-		             ColourDesired(0xff, 0xff, 0xff), ColourDesired(0, 0, 0));
-		DefineMarker(SC_MARKNUM_FOLDEROPENMID, SC_MARK_EMPTY,
-		             ColourDesired(0xff, 0xff, 0xff), ColourDesired(0, 0, 0));
-		DefineMarker(SC_MARKNUM_FOLDERMIDTAIL, SC_MARK_EMPTY, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0, 0, 0));
-		break;
-	case 1:
-		// Plus for contracted folders, minus for expanded
-		DefineMarker(SC_MARKNUM_FOLDEROPEN, SC_MARK_MINUS, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0, 0, 0));
-		DefineMarker(SC_MARKNUM_FOLDER, SC_MARK_PLUS, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0, 0, 0));
-		DefineMarker(SC_MARKNUM_FOLDERSUB, SC_MARK_EMPTY, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0, 0, 0));
-		DefineMarker(SC_MARKNUM_FOLDERTAIL, SC_MARK_EMPTY, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0, 0, 0));
-		DefineMarker(SC_MARKNUM_FOLDEREND, SC_MARK_EMPTY, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0, 0, 0));
-		DefineMarker(SC_MARKNUM_FOLDEROPENMID, SC_MARK_EMPTY, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0, 0, 0));
-		DefineMarker(SC_MARKNUM_FOLDERMIDTAIL, SC_MARK_EMPTY, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0, 0, 0));
-		break;
-	case 2:
-		// Like a flattened tree control using circular headers and curved joins
-		DefineMarker(SC_MARKNUM_FOLDEROPEN, SC_MARK_CIRCLEMINUS, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0x40, 0x40, 0x40));
-		DefineMarker(SC_MARKNUM_FOLDER, SC_MARK_CIRCLEPLUS, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0x40, 0x40, 0x40));
-		DefineMarker(SC_MARKNUM_FOLDERSUB, SC_MARK_VLINE, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0x40, 0x40, 0x40));
-		DefineMarker(SC_MARKNUM_FOLDERTAIL, SC_MARK_LCORNERCURVE, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0x40, 0x40, 0x40));
-		DefineMarker(SC_MARKNUM_FOLDEREND, SC_MARK_CIRCLEPLUSCONNECTED, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0x40, 0x40, 0x40));
-		DefineMarker(SC_MARKNUM_FOLDEROPENMID, SC_MARK_CIRCLEMINUSCONNECTED, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0x40, 0x40, 0x40));
-		DefineMarker(SC_MARKNUM_FOLDERMIDTAIL, SC_MARK_TCORNERCURVE, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0x40, 0x40, 0x40));
-		break;
-	case 3:
-		// Like a flattened tree control using square headers
-		DefineMarker(SC_MARKNUM_FOLDEROPEN, SC_MARK_BOXMINUS, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0x80, 0x80, 0x80));
-		DefineMarker(SC_MARKNUM_FOLDER, SC_MARK_BOXPLUS, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0x80, 0x80, 0x80));
-		DefineMarker(SC_MARKNUM_FOLDERSUB, SC_MARK_VLINE, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0x80, 0x80, 0x80));
-		DefineMarker(SC_MARKNUM_FOLDERTAIL, SC_MARK_LCORNER, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0x80, 0x80, 0x80));
-		DefineMarker(SC_MARKNUM_FOLDEREND, SC_MARK_BOXPLUSCONNECTED, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0x80, 0x80, 0x80));
-		DefineMarker(SC_MARKNUM_FOLDEROPENMID, SC_MARK_BOXMINUSCONNECTED, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0x80, 0x80, 0x80));
-		DefineMarker(SC_MARKNUM_FOLDERMIDTAIL, SC_MARK_TCORNER, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0x80, 0x80, 0x80));
-		break;
-	}
-
-	SendEditor(SCI_MARKERSETFORE, SciTE_MARKER_BOOKMARK,
-	           ColourOfProperty(props, "bookmark.fore", ColourDesired(0, 0, 0x7f)));
-	SendEditor(SCI_MARKERSETBACK, SciTE_MARKER_BOOKMARK,
-	           ColourOfProperty(props, "bookmark.back", ColourDesired(0x80, 0xff, 0xff)));
-	SString bookMarkXPM = props.Get("bookmark.pixmap");
-	if (bookMarkXPM.length()) {
-		SendEditorString(SCI_MARKERDEFINEPIXMAP, SciTE_MARKER_BOOKMARK,
-			bookMarkXPM.c_str());
-	} else {
-		SendEditor(SCI_MARKERDEFINE, SciTE_MARKER_BOOKMARK, SC_MARK_CIRCLE);
-	}
-
-	SendEditor(SCI_SETSCROLLWIDTH, props.GetInt("horizontal.scroll.width", 2000));
-	SendOutput(SCI_SETSCROLLWIDTH, props.GetInt("output.horizontal.scroll.width", 2000));
-
-	// Do these last as they force a style refresh
-	SendEditor(SCI_SETHSCROLLBAR, props.GetInt("horizontal.scrollbar", 1));
-	SendOutput(SCI_SETHSCROLLBAR, props.GetInt("output.horizontal.scrollbar", 1));
-
-	SendEditor(SCI_SETENDATLASTLINE, props.GetInt("end.at.last.line", 1));
-
-	if (extender) {
-		char defaultDir[MAX_PATH];
-		GetDefaultDirectory(defaultDir, sizeof(defaultDir));
-		char scriptPath[MAX_PATH];
-
-		// Check for an extension script
-		SString extensionFile = props.GetNewExpand("extension.", fileNameForExtension.c_str());
-		if (extensionFile.length()) {
-			// find file in local directory
-			char docDir[MAX_PATH];
-			GetDocumentDirectory(docDir, sizeof(docDir));
-			if (Exists(docDir, extensionFile.c_str(), scriptPath)) {
-				// Found file in document directory
-				extender->Load(scriptPath);
-			} else if (Exists(defaultDir, extensionFile.c_str(), scriptPath)) {
-				// Found file in global directory
-				extender->Load(scriptPath);
-			} else if (Exists("", extensionFile.c_str(), scriptPath)) {
-				// Found as completely specified file name
-				extender->Load(scriptPath);
-			}
-		}
-	}
-	firstPropertiesRead = false;
-	needReadProperties = false;
-}
-
-void SciTEBase::ReadFontProperties() {
-	char key[200];
-	SString sval;
-
-	// Set styles
-	// For each window set the global default style, then the language default style, then the other global styles, then the other language styles
-
-	SendEditor(SCI_STYLERESETDEFAULT, 0, 0);
-	SendOutput(SCI_STYLERESETDEFAULT, 0, 0);
-
-	sprintf(key, "style.%s.%0d", "*", STYLE_DEFAULT);
-	sval = props.GetNewExpand(key);
-	SetOneStyle(wEditor, STYLE_DEFAULT, sval.c_str());
-	SetOneStyle(wOutput, STYLE_DEFAULT, sval.c_str());
-
-	sprintf(key, "style.%s.%0d", language.c_str(), STYLE_DEFAULT);
-	sval = props.GetNewExpand(key);
-	SetOneStyle(wEditor, STYLE_DEFAULT, sval.c_str());
-
-	SendEditor(SCI_STYLECLEARALL, 0, 0);
-
-	SetStyleFor(wEditor, "*");
-	SetStyleFor(wEditor, language.c_str());
-
-	SendOutput(SCI_STYLECLEARALL, 0, 0);
-
-	sprintf(key, "style.%s.%0d", "errorlist", STYLE_DEFAULT);
-	sval = props.GetNewExpand(key);
-	SetOneStyle(wOutput, STYLE_DEFAULT, sval.c_str());
-
-	SendOutput(SCI_STYLECLEARALL, 0, 0);
-
-	SetStyleFor(wOutput, "*");
-	SetStyleFor(wOutput, "errorlist");
-
-	if (useMonoFont) {
-		sval = props.GetExpanded("font.monospace");
-		StyleDefinition sd(sval.c_str());
-		for (int style = 0; style <= STYLE_MAX; style++) {
-			if (style != STYLE_LINENUMBER) {
-				if (sd.specified & StyleDefinition::sdFont) {
-					SendEditorString(SCI_STYLESETFONT, style, sd.font.c_str());
-				}
-				if (sd.specified & StyleDefinition::sdSize) {
-					SendEditor(SCI_STYLESETSIZE, style, sd.size);
-				}
-			}
-		}
-	}
-}
-
-// Properties that are interactively modifiable are only read from the properties file once.
-void SciTEBase::SetPropertiesInitial() {
-	splitVertical = props.GetInt("split.vertical");
-	openFilesHere = props.GetInt("check.if.already.open");
-	wrap = props.GetInt("wrap");
-	wrapOutput = props.GetInt("output.wrap");
-	indentationWSVisible = props.GetInt("view.indentation.whitespace", 1);
-	sbVisible = props.GetInt("statusbar.visible");
-	tbVisible = props.GetInt("toolbar.visible");
-	tabVisible = props.GetInt("tabbar.visible");
-	tabMultiLine = props.GetInt("tabbar.multiline");
-	lineNumbers = props.GetInt("line.margin.visible");
-	marginWidth = 0;
-	SString margwidth = props.Get("margin.width");
-	if (margwidth.length())
-		marginWidth = margwidth.value();
-	margin = marginWidth;
-	if (marginWidth == 0)
-		marginWidth = marginWidthDefault;
-	foldMarginWidth = props.GetInt("fold.margin.width", foldMarginWidthDefault);
-	foldMargin = foldMarginWidth;
-	if (foldMarginWidth == 0)
-		foldMarginWidth = foldMarginWidthDefault;
-
-	matchCase = props.GetInt("find.replace.matchcase");
-	regExp = props.GetInt("find.replace.regexp");
-	unSlash = props.GetInt("find.replace.escapes");
-	wrapFind = props.GetInt("find.replace.wrap", 1);
-}
-
-SString SciTEBase::LocaliseString(const char *s, bool retainIfNotFound) {
-	SString translation = s;
-	int ellipseIndicator = translation.remove("...");
-	int accessKeyPresent = translation.remove(menuAccessIndicator);
-	translation.lowercase();
-	translation.substitute("\n", "\\n");
-	translation = propsUI.Get(translation.c_str());
-	if (translation.length()) {
-		if (ellipseIndicator)
-			translation += "...";
-		if (0 == accessKeyPresent)
-			translation.remove("&");
-		translation.substitute("&", menuAccessIndicator);
-		translation.substitute("\\n", "\n");
-	} else {
-		translation = props.Get("translation.missing");
-	}
-	if ((translation.length() > 0) || !retainIfNotFound) {
-		return translation;
-	}
-	return s;
-}
-
-SString SciTEBase::LocaliseMessage(const char *s, const char *param0, const char *param1, const char *param2) {
-	SString translation = LocaliseString(s);
-	if (param0)
-		translation.substitute("^0", param0);
-	if (param1)
-		translation.substitute("^1", param1);
-	if (param2)
-		translation.substitute("^2", param2);
-	return translation;
-}
-
-void SciTEBase::ReadLocalisation() {
-	char propfile[MAX_PATH + 20];
-	char propdir[MAX_PATH + 20];
-	propsUI.Clear();
-	const char *title = "locale.properties";
-	SString localeProps = props.GetExpanded(title);
-	if (localeProps.length()) {
-		title = localeProps.c_str();
-	}
-	if (GetSciteDefaultHome(propdir, sizeof propdir)
-	    && BuildPath(propfile, propdir, title, sizeof propfile)) {
-		strcat(propdir, pathSepString);
-		propsUI.Read(propfile, propdir, importFiles, importMax);
-	}
-	localisationRead = true;
-}
-
-void SciTEBase::ReadPropertiesInitial() {
-	SetPropertiesInitial();
-	int sizeHorizontal = props.GetInt("output.horizontal.size", 0);
-	int sizeVertical = props.GetInt("output.vertical.size", 0);
-	if ((!splitVertical && (sizeVertical > 0) && (heightOutput < sizeVertical)) ||
-		(splitVertical && (sizeHorizontal > 0) && (heightOutput < sizeHorizontal))) {
-		heightOutput = NormaliseSplit(splitVertical ? sizeHorizontal : sizeVertical);
-		SizeSubWindows();
-		Redraw();
-	}
-	ViewWhitespace(props.GetInt("view.whitespace"));
-	SendEditor(SCI_SETINDENTATIONGUIDES, props.GetInt("view.indentation.guides"));
-	SendEditor(SCI_SETVIEWEOL, props.GetInt("view.eol"));
-	SendEditor(SCI_SETZOOM, props.GetInt("magnification"));
-	SendOutput(SCI_SETZOOM, props.GetInt("output.magnification"));
-	SendEditor(SCI_SETWRAPMODE, wrap ? SC_WRAP_WORD : SC_WRAP_NONE);
-	SendOutput(SCI_SETWRAPMODE, wrapOutput ? SC_WRAP_WORD : SC_WRAP_NONE);
-
-	useMonoFont = false;
-
-	SString menuLanguageProp = props.GetNewExpand("menu.language");
-	languageItems = 0;
-	for (unsigned int i = 0; i < menuLanguageProp.length(); i++) {
-		if (menuLanguageProp[i] == '|')
-			languageItems++;
-	}
-	languageItems /= 3;
-	languageMenu = new LanguageMenuItem[languageItems];
-
-	menuLanguageProp.substitute('|', '\0');
-	const char *sMenuLanguage = menuLanguageProp.c_str();
-	for (int item = 0; item < languageItems; item++) {
-		languageMenu[item].menuItem = sMenuLanguage;
-		sMenuLanguage += strlen(sMenuLanguage) + 1;
-		languageMenu[item].extension = sMenuLanguage;
-		sMenuLanguage += strlen(sMenuLanguage) + 1;
-		languageMenu[item].menuKey = sMenuLanguage;
-		sMenuLanguage += strlen(sMenuLanguage) + 1;
-	}
-	SetLanguageMenu();
-
-	// load the user defined short cut props
-	SString shortCutProp = props.GetNewExpand("user.shortcuts");
-	if ( shortCutProp.length() ) {
-		shortCutItems = 0;
-		for (unsigned int i = 0; i < shortCutProp.length(); i++) {
-			if (shortCutProp[i] == '|')
-				shortCutItems++;
-		}
-		shortCutItems /= 2;
-		shortCutItemList = new ShortcutItem[shortCutItems];
-		shortCutProp.substitute('|', '\0');
-		const char *sShortCutProp = shortCutProp.c_str();
-		for (int item = 0; item < shortCutItems; item++) {
-			shortCutItemList[item].menuKey = sShortCutProp;
-			sShortCutProp += strlen(sShortCutProp) + 1;
-			shortCutItemList[item].menuCommand = sShortCutProp;
-			sShortCutProp += strlen(sShortCutProp) + 1;
-		}
-	}
-	// end load the user defined short cut props
-
-
-#if PLAT_WIN
-
-	if (tabMultiLine) {	// Windows specific!
-		long wl = ::GetWindowLong(reinterpret_cast<HWND>(wTabBar.GetID()), GWL_STYLE);
-		::SetWindowLong(reinterpret_cast<HWND>(wTabBar.GetID()), GWL_STYLE, wl | TCS_MULTILINE);
-	}
-#endif
-
-	char homepath[MAX_PATH + 20];
-	if (GetSciteDefaultHome(homepath, sizeof(homepath))) {
-		props.Set("SciteDefaultHome", homepath);
-	}
-	if (GetSciteUserHome(homepath, sizeof(homepath))) {
-		props.Set("SciteUserHome", homepath);
-	}
-}
-
-bool SciTEBase::GetDefaultPropertiesFileName(char *pathDefaultProps,
-        char *pathDefaultDir, unsigned int lenPath) {
-	if (!GetSciteDefaultHome(pathDefaultDir, lenPath)) {
-		return false;
-	}
-	return BuildPath(pathDefaultProps, pathDefaultDir, propGlobalFileName, lenPath);
-}
-
-bool SciTEBase::GetAbbrevPropertiesFileName(char *pathAbbrevProps,
-        char *pathDefaultDir, unsigned int lenPath) {
-	if (!GetSciteUserHome(pathDefaultDir, lenPath)) {
-		return false;
-	}
-	return BuildPath(pathAbbrevProps, pathDefaultDir, propAbbrevFileName, lenPath);
-}
-
-bool SciTEBase::GetUserPropertiesFileName(char *pathUserProps,
-        char *pathUserDir, unsigned int lenPath) {
-	if (!GetSciteUserHome(pathUserDir, lenPath)) {
-		return false;
-	}
-	return BuildPath(pathUserProps, pathUserDir, propUserFileName, lenPath);
-}
-
-void SciTEBase::OpenProperties(int propsFile) {
-	char propfile[MAX_PATH + 20];
-	char propdir[MAX_PATH + 20];
-	if (propsFile == IDM_OPENLOCALPROPERTIES) {
-		GetDocumentDirectory(propfile, sizeof(propfile));
-#ifdef __vms
-
-		strcpy(propfile, VMSToUnixStyle(propfile));
-#endif
-
-		strcat(propfile, pathSepString);
-		strcat(propfile, propFileName);
-		Open(propfile, ofQuiet);
-	} else if (propsFile == IDM_OPENUSERPROPERTIES) {
-		if (GetUserPropertiesFileName(propfile, propdir, sizeof(propfile))) {
-			Open(propfile, ofQuiet);
-		}
-	} else if (propsFile == IDM_OPENABBREVPROPERTIES) {
-		if (GetAbbrevPropertiesFileName(propfile, propdir, sizeof(propfile))) {
-			Open(propfile, ofQuiet);
-		}
-	} else if (propsFile == IDM_OPENGLOBALPROPERTIES) {
-		if (GetDefaultPropertiesFileName(propfile, propdir, sizeof(propfile))) {
-			Open(propfile, ofQuiet);
-		}
-	} else if (propsFile == IDM_OPENLUAEXTERNALFILE) {
-		SString extlua = props.GetExpanded("ext.lua.startup.script");
-		if (extlua.length()) {
-			Open(extlua.c_str(), ofQuiet);
-		}
-	}
-}
-
-// return the int value of the command name passed in.
-int SciTEBase::GetMenuCommandAsInt(SString commandName) {
-	struct {
-		const char *name;
-		int id;
-	} idmTable[] = {
-//++Autogenerated -- run ../scintilla/src/LexGen.py to regenerate
-//**\(\t\t{"\*",\t\*},\n\)
-		{"IDM_MRUFILE",	IDM_MRUFILE},
-		{"IDM_TOOLS",	IDM_TOOLS},
-		{"IDM_BUFFER",	IDM_BUFFER},
-		{"IDM_IMPORT",	IDM_IMPORT},
-		{"IDM_LANGUAGE",	IDM_LANGUAGE},
-		{"IDM_NEW",	IDM_NEW},
-		{"IDM_OPEN",	IDM_OPEN},
-		{"IDM_OPENSELECTED",	IDM_OPENSELECTED},
-		{"IDM_REVERT",	IDM_REVERT},
-		{"IDM_CLOSE",	IDM_CLOSE},
-		{"IDM_SAVE",	IDM_SAVE},
-		{"IDM_SAVEAS",	IDM_SAVEAS},
-		{"IDM_SAVEASHTML",	IDM_SAVEASHTML},
-		{"IDM_SAVEASRTF",	IDM_SAVEASRTF},
-		{"IDM_SAVEASPDF",	IDM_SAVEASPDF},
-		{"IDM_FILER",	IDM_FILER},
-		{"IDM_SAVEASTEX",	IDM_SAVEASTEX},
-		{"IDM_SAVEACOPY",	IDM_SAVEACOPY},
-		{"IDM_SAVEASXML",	IDM_SAVEASXML},
-		{"IDM_MRU_SEP",	IDM_MRU_SEP},
-		{"IDM_PRINTSETUP",	IDM_PRINTSETUP},
-		{"IDM_PRINT",	IDM_PRINT},
-		{"IDM_LOADSESSION",	IDM_LOADSESSION},
-		{"IDM_SAVESESSION",	IDM_SAVESESSION},
-		{"IDM_QUIT",	IDM_QUIT},
-		{"IDM_ENCODING_DEFAULT",	IDM_ENCODING_DEFAULT},
-		{"IDM_ENCODING_UCS2BE",	IDM_ENCODING_UCS2BE},
-		{"IDM_ENCODING_UCS2LE",	IDM_ENCODING_UCS2LE},
-		{"IDM_ENCODING_UTF8",	IDM_ENCODING_UTF8},
-		{"IDM_ENCODING_UCOOKIE",	IDM_ENCODING_UCOOKIE},
-		{"IDM_UNDO",	IDM_UNDO},
-		{"IDM_REDO",	IDM_REDO},
-		{"IDM_CUT",	IDM_CUT},
-		{"IDM_COPY",	IDM_COPY},
-		{"IDM_PASTE",	IDM_PASTE},
-		{"IDM_CLEAR",	IDM_CLEAR},
-		{"IDM_SELECTALL",	IDM_SELECTALL},
-		{"IDM_PASTEANDDOWN",	IDM_PASTEANDDOWN},
-		{"IDM_FIND",	IDM_FIND},
-		{"IDM_FINDNEXT",	IDM_FINDNEXT},
-		{"IDM_FINDNEXTBACK",	IDM_FINDNEXTBACK},
-		{"IDM_FINDNEXTSEL",	IDM_FINDNEXTSEL},
-		{"IDM_FINDNEXTBACKSEL",	IDM_FINDNEXTBACKSEL},
-		{"IDM_FINDINFILES",	IDM_FINDINFILES},
-		{"IDM_REPLACE",	IDM_REPLACE},
-		{"IDM_GOTO",	IDM_GOTO},
-		{"IDM_BOOKMARK_NEXT",	IDM_BOOKMARK_NEXT},
-		{"IDM_BOOKMARK_TOGGLE",	IDM_BOOKMARK_TOGGLE},
-		{"IDM_BOOKMARK_PREV",	IDM_BOOKMARK_PREV},
-		{"IDM_BOOKMARK_CLEARALL",	IDM_BOOKMARK_CLEARALL},
-		{"IDM_BOOKMARK_NEXT_SELECT",	IDM_BOOKMARK_NEXT_SELECT},
-		{"IDM_BOOKMARK_PREV_SELECT",	IDM_BOOKMARK_PREV_SELECT},
-		{"IDM_MATCHBRACE",	IDM_MATCHBRACE},
-		{"IDM_SELECTTOBRACE",	IDM_SELECTTOBRACE},
-		{"IDM_SHOWCALLTIP",	IDM_SHOWCALLTIP},
-		{"IDM_COMPLETE",	IDM_COMPLETE},
-		{"IDM_COMPLETEWORD",	IDM_COMPLETEWORD},
-		{"IDM_EXPAND",	IDM_EXPAND},
-		{"IDM_TOGGLE_FOLDALL",	IDM_TOGGLE_FOLDALL},
-		{"IDM_UPRCASE",	IDM_UPRCASE},
-		{"IDM_LWRCASE",	IDM_LWRCASE},
-		{"IDM_ABBREV",	IDM_ABBREV},
-		{"IDM_BLOCK_COMMENT",	IDM_BLOCK_COMMENT},
-		{"IDM_STREAM_COMMENT",	IDM_STREAM_COMMENT},
-		{"IDM_COPYASRTF",	IDM_COPYASRTF},
-		{"IDM_BOX_COMMENT",	IDM_BOX_COMMENT},
-		{"IDM_INS_ABBREV",	IDM_INS_ABBREV},
-		{"IDM_JOIN",	IDM_JOIN},
-		{"IDM_SPLIT",	IDM_SPLIT},
-		{"IDM_INCSEARCH",	IDM_INCSEARCH},
-		{"IDM_ENTERSELECTION",	IDM_ENTERSELECTION},
-		{"IDM_PREVMATCHPPC",	IDM_PREVMATCHPPC},
-		{"IDM_SELECTTOPREVMATCHPPC",	IDM_SELECTTOPREVMATCHPPC},
-		{"IDM_NEXTMATCHPPC",	IDM_NEXTMATCHPPC},
-		{"IDM_SELECTTONEXTMATCHPPC",	IDM_SELECTTONEXTMATCHPPC},
-		{"IDM_COMPILE",	IDM_COMPILE},
-		{"IDM_BUILD",	IDM_BUILD},
-		{"IDM_GO",	IDM_GO},
-		{"IDM_STOPEXECUTE",	IDM_STOPEXECUTE},
-		{"IDM_FINISHEDEXECUTE",	IDM_FINISHEDEXECUTE},
-		{"IDM_NEXTMSG",	IDM_NEXTMSG},
-		{"IDM_PREVMSG",	IDM_PREVMSG},
-		{"IDM_MACRO_SEP",	IDM_MACRO_SEP},
-		{"IDM_MACRORECORD",	IDM_MACRORECORD},
-		{"IDM_MACROSTOPRECORD",	IDM_MACROSTOPRECORD},
-		{"IDM_MACROPLAY",	IDM_MACROPLAY},
-		{"IDM_MACROLIST",	IDM_MACROLIST},
-		{"IDM_ACTIVATE",	IDM_ACTIVATE},
-		{"IDM_SRCWIN",	IDM_SRCWIN},
-		{"IDM_RUNWIN",	IDM_RUNWIN},
-		{"IDM_TOOLWIN",	IDM_TOOLWIN},
-		{"IDM_STATUSWIN",	IDM_STATUSWIN},
-		{"IDM_TABWIN",	IDM_TABWIN},
-		{"IDM_SPLITVERTICAL",	IDM_SPLITVERTICAL},
-		{"IDM_VIEWSPACE",	IDM_VIEWSPACE},
-		{"IDM_VIEWEOL",	IDM_VIEWEOL},
-		{"IDM_VIEWGUIDES",	IDM_VIEWGUIDES},
-		{"IDM_SELMARGIN",	IDM_SELMARGIN},
-		{"IDM_FOLDMARGIN",	IDM_FOLDMARGIN},
-		{"IDM_LINENUMBERMARGIN",	IDM_LINENUMBERMARGIN},
-		{"IDM_VIEWTOOLBAR",	IDM_VIEWTOOLBAR},
-		{"IDM_TOGGLEOUTPUT",	IDM_TOGGLEOUTPUT},
-		{"IDM_VIEWTABBAR",	IDM_VIEWTABBAR},
-		{"IDM_VIEWSTATUSBAR",	IDM_VIEWSTATUSBAR},
-		{"IDM_TOGGLEPARAMETERS",	IDM_TOGGLEPARAMETERS},
-		{"IDM_OPENFILESHERE",	IDM_OPENFILESHERE},
-		{"IDM_WRAP",	IDM_WRAP},
-		{"IDM_WRAPOUTPUT",	IDM_WRAPOUTPUT},
-		{"IDM_READONLY",	IDM_READONLY},
-		{"IDM_CLEAROUTPUT",	IDM_CLEAROUTPUT},
-		{"IDM_SWITCHPANE",	IDM_SWITCHPANE},
-		{"IDM_EOL_CRLF",	IDM_EOL_CRLF},
-		{"IDM_EOL_CR",	IDM_EOL_CR},
-		{"IDM_EOL_LF",	IDM_EOL_LF},
-		{"IDM_EOL_CONVERT",	IDM_EOL_CONVERT},
-		{"IDM_TABSIZE",	IDM_TABSIZE},
-		{"IDM_MONOFONT",	IDM_MONOFONT},
-		{"IDM_OPENLOCALPROPERTIES",	IDM_OPENLOCALPROPERTIES},
-		{"IDM_OPENUSERPROPERTIES",	IDM_OPENUSERPROPERTIES},
-		{"IDM_OPENGLOBALPROPERTIES",	IDM_OPENGLOBALPROPERTIES},
-		{"IDM_OPENABBREVPROPERTIES",	IDM_OPENABBREVPROPERTIES},
-		{"IDM_OPENLUAEXTERNALFILE",	IDM_OPENLUAEXTERNALFILE},
-		{"IDM_PREVFILE",	IDM_PREVFILE},
-		{"IDM_NEXTFILE",	IDM_NEXTFILE},
-		{"IDM_CLOSEALL",	IDM_CLOSEALL},
-		{"IDM_SAVEALL",	IDM_SAVEALL},
-		{"IDM_BUFFERSEP",	IDM_BUFFERSEP},
-		{"IDM_HELP",	IDM_HELP},
-		{"IDM_ABOUT",	IDM_ABOUT},
-		{"IDM_HELP_SCITE",	IDM_HELP_SCITE},
-		{"IDM_ONTOP",	IDM_ONTOP},
-		{"IDM_FULLSCREEN",	IDM_FULLSCREEN},
-
-//--Autogenerated -- end of automatically generated section
-		{0, 0},
-	};
-
-	for (int i=0; idmTable[i].id; i++) {
-		if (commandName == idmTable[i].name) {
-			return idmTable[i].id;
-		}
-	}
-	// Otherwise we might have entered a number as command to access a "SCI_" command
-	return commandName.value();
-}
+// SciTE - Scintilla based Text Editor
+/** @file SciTEProps.cxx
+ ** Properties management.
+ **/
+// Copyright 1998-2004 by Neil Hodgson <neilh@scintilla.org>
+// The License.txt file describes the conditions under which this software may be distributed.
+
+#include <stdlib.h>
+#include <string.h>
+#include <ctype.h>
+#include <stdio.h>
+#include <fcntl.h>
+#include <time.h>
+#include <locale.h>
+
+#include "Platform.h"
+
+#if PLAT_FOX
+
+#include <unistd.h>
+
+const char menuAccessIndicator[] = "&";
+
+#endif
+
+#if PLAT_GTK
+
+#include <unistd.h>
+#include <gtk/gtk.h>
+
+const char menuAccessIndicator[] = "_";
+
+#endif
+
+#if PLAT_WIN
+
+#define _WIN32_WINNT  0x0400
+#ifdef _MSC_VER
+// windows.h, et al, use a lot of nameless struct/unions - can't fix it, so allow it
+#pragma warning(disable: 4201)
+#endif
+#include <windows.h>
+#ifdef _MSC_VER
+// okay, that's done, don't allow it in our code
+#pragma warning(default: 4201)
+#endif
+#include <commctrl.h>
+
+// For getcwd
+#ifdef _MSC_VER
+#include <direct.h>
+#endif
+#ifdef __BORLANDC__
+#include <dir.h>
+#endif
+#ifdef __DMC__
+#include <dir.h>
+#endif
+
+const char menuAccessIndicator[] = "&";
+
+#endif
+
+#include "SciTE.h"
+#include "PropSet.h"
+#include "Accessor.h"
+#include "Scintilla.h"
+#include "SciLexer.h"
+#include "Extender.h"
+#include "SciTEBase.h"
+
+PropSetFile::PropSetFile(bool lowerKeys_) : lowerKeys(lowerKeys_) {}
+
+PropSetFile::~PropSetFile() {}
+
+/**
+ * Get a line of input. If end of line escaped with '\\' then continue reading.
+ */
+static bool GetFullLine(const char *&fpc, int &lenData, char *s, int len) {
+	bool continuation = true;
+	s[0] = '\0';
+	while ((len > 1) && lenData > 0) {
+		char ch = *fpc;
+		fpc++;
+		lenData--;
+		if ((ch == '\r') || (ch == '\n')) {
+			if (!continuation) {
+				if ((lenData > 0) && (ch == '\r') && ((*fpc) == '\n')) {
+					// munch the second half of a crlf
+					fpc++;
+					lenData--;
+				}
+				*s = '\0';
+				return true;
+			}
+		} else if ((ch == '\\') && (lenData > 0) && ((*fpc == '\r') || (*fpc == '\n'))) {
+			continuation = true;
+		} else {
+			continuation = false;
+			*s++ = ch;
+			*s = '\0';
+			len--;
+		}
+	}
+	return false;
+}
+
+static bool IsSpaceOrTab(char ch) {
+	return (ch == ' ') || (ch == '\t');
+}
+
+static bool IsCommentLine(const char *line) {
+	while (IsSpaceOrTab(*line)) ++line;
+	return (*line == '#');
+}
+
+bool PropSetFile::ReadLine(const char *lineBuffer, bool ifIsTrue, const char *directoryForImports,
+                           SString imports[], int sizeImports) {
+	//UnSlash(lineBuffer);
+	if (!IsSpaceOrTab(lineBuffer[0]))    // If clause ends with first non-indented line
+		ifIsTrue = true;
+	if (isprefix(lineBuffer, "if ")) {
+		const char *expr = lineBuffer + strlen("if") + 1;
+		ifIsTrue = GetInt(expr);
+	} else if (isprefix(lineBuffer, "import ") && directoryForImports) {
+		char importPath[1024];
+		strcpy(importPath, directoryForImports);
+		strcat(importPath, lineBuffer + strlen("import") + 1);
+		strcat(importPath, ".properties");
+		if (Read(importPath, directoryForImports, imports, sizeImports)) {
+			if (imports) {
+				for (int i = 0; i < sizeImports; i++) {
+					if (!imports[i].length()) {
+						imports[i] = importPath;
+						break;
+					}
+				}
+			}
+		}
+	} else if (ifIsTrue && !IsCommentLine(lineBuffer)) {
+		Set(lineBuffer);
+	}
+	return ifIsTrue;
+}
+
+void PropSetFile::ReadFromMemory(const char *data, int len, const char *directoryForImports,
+                                 SString imports[], int sizeImports) {
+	const char *pd = data;
+	char lineBuffer[60000];
+	bool ifIsTrue = true;
+	while (len > 0) {
+		GetFullLine(pd, len, lineBuffer, sizeof(lineBuffer));
+		if (lowerKeys) {
+			for (int i=0; lineBuffer[i] && (lineBuffer[i] != '='); i++) {
+				if ((lineBuffer[i] >= 'A') && (lineBuffer[i] <= 'Z')) {
+					lineBuffer[i] = static_cast<char>(lineBuffer[i] - 'A' + 'a');
+				}
+			}
+		}
+		ifIsTrue = ReadLine(lineBuffer, ifIsTrue, directoryForImports, imports, sizeImports);
+	}
+}
+
+bool PropSetFile::Read(const char *filename, const char *directoryForImports,
+                       SString imports[], int sizeImports) {
+	FILE *rcfile = fopen(filename, fileRead);
+	if (rcfile) {
+		char propsData[60000];
+		int lenFile = static_cast<int>(fread(propsData, 1, sizeof(propsData), rcfile));
+		fclose(rcfile);
+		ReadFromMemory(propsData, lenFile, directoryForImports, imports, sizeImports);
+		return true;
+	}
+	return false;
+}
+
+void PropSetFile::SetInteger(const char *key, sptr_t i) {
+	char tmp[32];
+	sprintf(tmp, "%d", static_cast<int>(i));
+	Set(key, tmp);
+}
+
+void SciTEBase::SetImportMenu() {
+	for (int i = 0; i < importMax; i++) {
+		DestroyMenuItem(menuOptions, importCmdID + i);
+	}
+	if (importFiles[0][0]) {
+		for (int stackPos = 0; stackPos < importMax; stackPos++) {
+			int itemID = importCmdID + stackPos;
+			if (importFiles[stackPos][0]) {
+				SString entry = LocaliseString("Open");
+				entry += " ";
+				const char *cpDirEnd = strrchr(importFiles[stackPos].c_str(), pathSepChar);
+				if (cpDirEnd) {
+					entry += cpDirEnd + 1;
+				} else {
+					entry += importFiles[stackPos];
+				}
+				SetMenuItem(menuOptions, IMPORT_START + stackPos, itemID, entry.c_str());
+			}
+		}
+	}
+}
+
+void SciTEBase::ImportMenu(int pos) {
+	//Platform::DebugPrintf("Stack menu %d\n", pos);
+	if (pos >= 0) {
+		if (importFiles[pos][0] != '\0') {
+			Open(importFiles[pos].c_str());
+		}
+	}
+}
+
+void SciTEBase::SetLanguageMenu() {
+	for (int i = 0; i < 100; i++) {
+		DestroyMenuItem(menuLanguage, languageCmdID + i);
+	}
+	for (int item = 0; item < languageItems; item++) {
+		int itemID = languageCmdID + item;
+		SString entry = LocaliseString(languageMenu[item].menuItem.c_str());
+		if (languageMenu[item].menuKey.length()) {
+#if PLAT_GTK
+			entry += " ";
+#else
+			entry += "\t";
+#endif
+			entry += languageMenu[item].menuKey;
+		}
+		if (entry[0] != '#') {
+			SetMenuItem(menuLanguage, item, itemID, entry.c_str());
+		}
+	}
+}
+
+const char propFileName[] = "SciTE.properties";
+
+void SciTEBase::ReadGlobalPropFile() {
+#ifdef unix
+	extern char **environ;
+	char **e=environ;
+#else
+	char **e=_environ;
+#endif
+	for (; *e; e++) {
+		char key[1024];
+		char *k=*e;
+		char *v=strchr(k,'=');
+		if (v && (static_cast<size_t>(v-k) < sizeof(key))) {
+			memcpy(key, k, v-k);
+			key[v-k] = '\0';
+			propsEmbed.Set(key, v+1);
+		}
+	}
+
+	for (int stackPos = 0; stackPos < importMax; stackPos++) {
+		importFiles[stackPos] = "";
+	}
+	char propfile[MAX_PATH + 20];
+	char propdir[MAX_PATH + 20];
+	propsBase.Clear();
+	if (GetDefaultPropertiesFileName(propfile, propdir, sizeof(propfile))) {
+		strcat(propdir, pathSepString);
+		propsBase.Read(propfile, propdir, importFiles, importMax);
+	}
+	propsUser.Clear();
+	if (GetUserPropertiesFileName(propfile, propdir, sizeof(propfile))) {
+		strcat(propdir, pathSepString);
+		propsUser.Read(propfile, propdir, importFiles, importMax);
+	}
+	if (!localisationRead) {
+		ReadLocalisation();
+	}
+}
+
+void SciTEBase::ReadAbbrevPropFile() {
+	char propfile[MAX_PATH + 20];
+	char propdir[MAX_PATH + 20];
+	propsAbbrev.Clear();
+	if (GetAbbrevPropertiesFileName(propfile, propdir, sizeof(propfile))) {
+		strcat(propdir, pathSepString);
+		propsAbbrev.Read(propfile, propdir, importFiles, importMax);
+	}
+}
+
+void ChopTerminalSlash(char *path) {
+	size_t endOfPath = strlen(path) - 1;
+	if (path[endOfPath] == pathSepChar) {
+		path[endOfPath] = '\0';
+	}
+}
+
+void SciTEBase::GetDocumentDirectory(char *docDir, int len) {
+	if (dirName[0]) {
+		strncpy(docDir, dirName, len);
+		docDir[len - 1] = '\0';
+	} else {
+		getcwd(docDir, len);
+		docDir[len - 1] = '\0';
+		// In Windows, getcwd returns a trailing backslash
+		// when the CWD is at the root of a disk, so remove it
+		ChopTerminalSlash(docDir);
+	}
+}
+
+void SciTEBase::ReadLocalPropFile() {
+	char propdir[MAX_PATH + 20];
+	GetDocumentDirectory(propdir, sizeof(propdir));
+	char propfile[MAX_PATH + 20];
+	strcpy(propfile, propdir);
+#ifndef __vms
+
+	strcat(propdir, pathSepString);
+	strcat(propfile, pathSepString);
+#endif
+
+	strcat(propfile, propFileName);
+	propsLocal.Clear();
+	propsLocal.Read(propfile, propdir);
+	//Platform::DebugPrintf("Reading local properties from %s\n", propfile);
+
+	// TODO: Grab these from Platform and update when environment says to
+	props.Set("Chrome", "#C0C0C0");
+	props.Set("ChromeHighlight", "#FFFFFF");
+}
+
+int IntFromHexDigit(const char ch) {
+	if (isdigit(ch)) {
+		return ch - '0';
+	} else if (ch >= 'A' && ch <= 'F') {
+		return ch - 'A' + 10;
+	} else if (ch >= 'a' && ch <= 'f') {
+		return ch - 'a' + 10;
+	} else {
+		return 0;
+	}
+}
+
+int IntFromHexByte(const char *hexByte) {
+	return IntFromHexDigit(hexByte[0]) * 16 + IntFromHexDigit(hexByte[1]);
+}
+
+static long ColourFromString(const SString &s) {
+	if (s.length()) {
+		int r = IntFromHexByte(s.c_str() + 1);
+		int g = IntFromHexByte(s.c_str() + 3);
+		int b = IntFromHexByte(s.c_str() + 5);
+		return ColourDesired(r, g, b).AsLong();
+	} else {
+		return ColourDesired().AsLong();
+	}
+}
+
+long ColourOfProperty(PropSet &props, const char *key, ColourDesired colourDefault) {
+	SString colour = props.Get(key);
+	if (colour.length()) {
+		return ColourFromString(colour);
+	}
+	return colourDefault.AsLong();
+}
+
+/**
+ * Put the next property item from the given property string
+ * into the buffer pointed by @a pPropItem.
+ * @return NULL if the end of the list is met, else, it points to the next item.
+ */
+const char *SciTEBase::GetNextPropItem(
+	const char *pStart,	/**< the property string to parse for the first call,
+						 * pointer returned by the previous call for the following. */
+	char *pPropItem,	///< pointer on a buffer receiving the requested prop item
+	int maxLen)			///< size of the above buffer
+{
+	int size = maxLen - 1;
+
+	*pPropItem = '\0';
+	if (pStart == NULL) {
+		return NULL;
+	}
+	const char *pNext = strchr(pStart, ',');
+	if (pNext) {	// Separator is found
+		if (size > pNext - pStart) {
+			// Found string fits in buffer
+			size = pNext - pStart;
+		}
+		pNext++;
+	}
+	strncpy(pPropItem, pStart, size);
+	pPropItem[size] = '\0';
+	return pNext;
+}
+
+StyleDefinition::StyleDefinition(const char *definition) :
+		size(0), fore("#000000"), back("#FFFFFF"),
+		bold(false), italics(false), eolfilled(false), underlined(false),
+		caseForce(SC_CASE_MIXED),
+		visible(true), changeable(true),
+		specified(sdNone) {
+	ParseStyleDefinition(definition);
+}
+
+bool StyleDefinition::ParseStyleDefinition(const char *definition) {
+	if (definition == 0 || *definition == '\0') {
+		return false;
+	}
+	char *val = StringDup(definition);
+	//Platform::DebugPrintf("Style %d is [%s]\n", style, val);
+	char *opt = val;
+	while (opt) {
+		// Find attribute separator
+		char *cpComma = strchr(opt, ',');
+		if (cpComma) {
+			// If found, we terminate the current attribute (opt) string
+			*cpComma = '\0';
+		}
+		// Find attribute name/value separator
+		char *colon = strchr(opt, ':');
+		if (colon) {
+			// If found, we terminate the current attribute name and point on the value
+			*colon++ = '\0';
+		}
+		if (0 == strcmp(opt, "italics")) {
+			specified = static_cast<flags>(specified | sdItalics);
+			italics = true;
+		}
+		if (0 == strcmp(opt, "notitalics")) {
+			specified = static_cast<flags>(specified | sdItalics);
+			italics = false;
+		}
+		if (0 == strcmp(opt, "bold")) {
+			specified = static_cast<flags>(specified | sdBold);
+			bold = true;
+		}
+		if (0 == strcmp(opt, "notbold")) {
+			specified = static_cast<flags>(specified | sdBold);
+			bold = false;
+		}
+		if (0 == strcmp(opt, "font")) {
+			specified = static_cast<flags>(specified | sdFont);
+			font = colon;
+			font.substitute('|', ',');
+		}
+		if (0 == strcmp(opt, "fore")) {
+			specified = static_cast<flags>(specified | sdFore);
+			fore = colon;
+		}
+		if (0 == strcmp(opt, "back")) {
+			specified = static_cast<flags>(specified | sdBack);
+			back = colon;
+		}
+		if (0 == strcmp(opt, "size")) {
+			specified = static_cast<flags>(specified | sdSize);
+			size = atoi(colon);
+		}
+		if (0 == strcmp(opt, "eolfilled")) {
+			specified = static_cast<flags>(specified | sdEOLFilled);
+			eolfilled = true;
+		}
+		if (0 == strcmp(opt, "noteolfilled")) {
+			specified = static_cast<flags>(specified | sdEOLFilled);
+			eolfilled = false;
+		}
+		if (0 == strcmp(opt, "underlined")) {
+			specified = static_cast<flags>(specified | sdUnderlined);
+			underlined = true;
+		}
+		if (0 == strcmp(opt, "notunderlined")) {
+			specified = static_cast<flags>(specified | sdUnderlined);
+			underlined = false;
+		}
+		if (0 == strcmp(opt, "case")) {
+			specified = static_cast<flags>(specified | sdCaseForce);
+			caseForce = SC_CASE_MIXED;
+			if (colon) {
+				if (*colon == 'u')
+					caseForce = SC_CASE_UPPER;
+				else if (*colon == 'l')
+					caseForce = SC_CASE_LOWER;
+			}
+		}
+		if (0 == strcmp(opt, "visible")) {
+			specified = static_cast<flags>(specified | sdVisible);
+			visible = true;
+		}
+		if (0 == strcmp(opt, "notvisible")) {
+			specified = static_cast<flags>(specified | sdVisible);
+			visible = false;
+		}
+		if (0 == strcmp(opt, "changeable")) {
+			specified = static_cast<flags>(specified | sdChangeable);
+			changeable = true;
+		}
+		if (0 == strcmp(opt, "notchangeable")) {
+			specified = static_cast<flags>(specified | sdChangeable);
+			changeable = false;
+		}
+		if (cpComma)
+			opt = cpComma + 1;
+		else
+			opt = 0;
+	}
+	delete []val;
+	return true;
+}
+
+long StyleDefinition::ForeAsLong() const {
+	return ColourFromString(fore);
+}
+
+long StyleDefinition::BackAsLong() const {
+	return ColourFromString(back);
+}
+
+void SciTEBase::SetOneStyle(Window &win, int style, const StyleDefinition &sd) {
+	if (sd.specified & StyleDefinition::sdItalics)
+		Platform::SendScintilla(win.GetID(), SCI_STYLESETITALIC, style, sd.italics ? 1 : 0);
+	if (sd.specified & StyleDefinition::sdBold)
+		Platform::SendScintilla(win.GetID(), SCI_STYLESETBOLD, style, sd.bold ? 1 : 0);
+	if (sd.specified & StyleDefinition::sdFont)
+		Platform::SendScintillaPointer(win.GetID(), SCI_STYLESETFONT, style,
+			const_cast<char *>(sd.font.c_str()));
+	if (sd.specified & StyleDefinition::sdFore)
+		Platform::SendScintilla(win.GetID(), SCI_STYLESETFORE, style, sd.ForeAsLong());
+	if (sd.specified & StyleDefinition::sdBack)
+		Platform::SendScintilla(win.GetID(), SCI_STYLESETBACK, style, sd.BackAsLong());
+	if (sd.specified & StyleDefinition::sdSize)
+		Platform::SendScintilla(win.GetID(), SCI_STYLESETSIZE, style, sd.size);
+	if (sd.specified & StyleDefinition::sdEOLFilled)
+		Platform::SendScintilla(win.GetID(), SCI_STYLESETEOLFILLED, style, sd.eolfilled ? 1 : 0);
+	if (sd.specified & StyleDefinition::sdUnderlined)
+		Platform::SendScintilla(win.GetID(), SCI_STYLESETUNDERLINE, style, sd.underlined ? 1 : 0);
+	if (sd.specified & StyleDefinition::sdCaseForce)
+		Platform::SendScintilla(win.GetID(), SCI_STYLESETCASE, style, sd.caseForce);
+	if (sd.specified & StyleDefinition::sdVisible)
+		Platform::SendScintilla(win.GetID(), SCI_STYLESETVISIBLE, style, sd.visible ? 1 : 0);
+	if (sd.specified & StyleDefinition::sdChangeable)
+		Platform::SendScintilla(win.GetID(), SCI_STYLESETCHANGEABLE, style, sd.changeable ? 1 : 0);
+	Platform::SendScintilla(win.GetID(), SCI_STYLESETCHARACTERSET, style, characterSet);
+}
+
+void SciTEBase::SetStyleFor(Window &win, const char *lang) {
+	for (int style = 0; style <= STYLE_MAX; style++) {
+		if (style != STYLE_DEFAULT) {
+			char key[200];
+			sprintf(key, "style.%s.%0d", lang, style);
+			SString sval = props.GetExpanded(key);
+			SetOneStyle(win, style, sval.c_str());
+		}
+	}
+}
+
+void LowerCaseString(char *s) {
+	while (*s) {
+		*s = static_cast<char>(tolower(*s));
+		s++;
+	}
+}
+
+SString SciTEBase::ExtensionFileName() {
+	if (overrideExtension.length())
+		return overrideExtension;
+	else if (fileName[0]) {
+		// Force extension to lower case
+		char fileNameWithLowerCaseExtension[MAX_PATH];
+		strcpy(fileNameWithLowerCaseExtension, fileName);
+		char *extension = strrchr(fileNameWithLowerCaseExtension, '.');
+		if (extension) {
+			LowerCaseString(extension);
+		}
+		return SString(fileNameWithLowerCaseExtension);
+	} else
+		return props.Get("default.file.ext");
+}
+
+void SciTEBase::ForwardPropertyToEditor(const char *key) {
+	SString value = props.Get(key);
+	SendEditorString(SCI_SETPROPERTY,
+	                 reinterpret_cast<uptr_t>(key), value.c_str());
+}
+
+void SciTEBase::DefineMarker(int marker, int markerType, ColourDesired fore, ColourDesired back) {
+	SendEditor(SCI_MARKERDEFINE, marker, markerType);
+	SendEditor(SCI_MARKERSETFORE, marker, fore.AsLong());
+	SendEditor(SCI_MARKERSETBACK, marker, back.AsLong());
+}
+
+static int FileLength(const char *path) {
+	int len = 0;
+	FILE *fp = fopen(path, fileRead);
+	if (fp) {
+		fseek(fp, 0, SEEK_END);
+		len = ftell(fp);
+		fclose(fp);
+	}
+	return len;
+}
+
+void SciTEBase::ReadAPI(const SString &fileNameForExtension) {
+	SString apisFileNames = props.GetNewExpand("api.",
+	                        fileNameForExtension.c_str());
+	size_t nameLength = apisFileNames.length();
+	if (nameLength) {
+		apisFileNames.substitute(';', '\0');
+		const char *apiFileName = apisFileNames.c_str();
+		const char *nameEnd = apiFileName + nameLength;
+
+		int tlen = 0;    // total api length
+
+		// Calculate total length
+		while (apiFileName < nameEnd) {
+			tlen += FileLength(apiFileName);
+			apiFileName += strlen(apiFileName) + 1;
+		}
+
+		// Load files
+		if (tlen > 0) {
+			char *buffer = apis.Allocate(tlen);
+			if (buffer) {
+				apiFileName = apisFileNames.c_str();
+				tlen = 0;
+				while (apiFileName < nameEnd) {
+					FILE *fp = fopen(apiFileName, fileRead);
+					if (fp) {
+						fseek(fp, 0, SEEK_END);
+						int len = ftell(fp);
+						fseek(fp, 0, SEEK_SET);
+						fread(buffer + tlen, 1, len, fp);
+						tlen += len;
+						fclose(fp);
+					}
+					apiFileName += strlen(apiFileName) + 1;
+				}
+				apis.SetFromAllocated();
+			}
+		}
+	}
+}
+
+SString SciTEBase::FindLanguageProperty(const char *pattern, const char *defaultValue) {
+	SString key = pattern;
+	key.substitute("*", language.c_str());
+	SString ret = props.GetExpanded(key.c_str());
+	if (ret == "")
+		ret = props.GetExpanded(pattern);
+	if (ret == "")
+		ret = defaultValue;
+	return ret;
+}
+
+/**
+ * A list of all the properties that should be forwarded to Scintilla lexers.
+ */
+static const char *propertiesToForward[] = {
+	"fold",
+	"fold.comment",
+	"fold.comment.python",
+	"fold.compact",
+	"fold.at.else",
+	"fold.html",
+	"fold.html.preprocessor",
+	"fold.preprocessor",
+	"fold.quotes.python",
+	"fold.verilog.flags",
+	"styling.within.preprocessor",
+	"tab.timmy.whinge.level",
+	"asp.default.language",
+	"html.tags.case.sensitive",
+	"ps.level",
+	"ps.tokenize",
+	"sql.backslash.escapes",
+
+	"lexer.tex.interface.default",
+	"lexer.tex.comment.process",
+	"lexer.tex.auto.if",
+	"lexer.tex.use.keywords",
+	"lexer.metapost.interface.default",
+	"lexer.metapost.comment.process",
+	"nsis.uservars",
+	"nsis.ignorecase",
+
+	0,
+};
+
+void SciTEBase::ReadProperties() {
+	if (extender)
+		extender->Clear();
+
+	SString fileNameForExtension = ExtensionFileName();
+
+	SString modulePath = props.GetNewExpand("lexerpath.",
+	    fileNameForExtension.c_str());
+	if (modulePath.length())
+	    SendEditorString(SCI_LOADLEXERLIBRARY, 0, modulePath.c_str());
+	language = props.GetNewExpand("lexer.", fileNameForExtension.c_str());
+	if (language.length())
+	    SendEditorString(SCI_SETLEXERLANGUAGE, 0, language.c_str());
+	else
+	    SendEditorString(SCI_SETLEXER, 0, SCLEX_CONTAINER);
+
+	lexLanguage = SendEditor(SCI_GETLEXER);
+
+	if ((lexLanguage == SCLEX_HTML) || (lexLanguage == SCLEX_XML) ||
+	        (lexLanguage == SCLEX_ASP) || (lexLanguage == SCLEX_PHP))
+		SendEditor(SCI_SETSTYLEBITS, 7);
+	else
+		SendEditor(SCI_SETSTYLEBITS, 5);
+
+	SendOutput(SCI_SETLEXER, SCLEX_ERRORLIST);
+
+	SString kw0 = props.GetNewExpand("keywords.", fileNameForExtension.c_str());
+	SendEditorString(SCI_SETKEYWORDS, 0, kw0.c_str());
+
+	for (int wl = 1; wl <= KEYWORDSET_MAX; wl++) {
+		SString kwk(wl+1);
+		kwk += '.';
+		kwk.insert(0, "keywords");
+		SString kw = props.GetNewExpand(kwk.c_str(), fileNameForExtension.c_str());
+		SendEditorString(SCI_SETKEYWORDS, wl, kw.c_str());
+	}
+
+	char homepath[MAX_PATH + 20];
+	if (GetSciteDefaultHome(homepath, sizeof(homepath))) {
+		props.Set("SciteDefaultHome", homepath);
+	}
+	if (GetSciteUserHome(homepath, sizeof(homepath))) {
+		props.Set("SciteUserHome", homepath);
+	}
+
+	for (size_t i=0; propertiesToForward[i]; i++) {
+		ForwardPropertyToEditor(propertiesToForward[i]);
+	}
+
+	if (apisFileNames != props.GetNewExpand("api.",	fileNameForExtension.c_str())) {
+		apis.Clear();
+		ReadAPI(fileNameForExtension);
+		apisFileNames = props.GetNewExpand("api.", fileNameForExtension.c_str());
+	}
+
+	if (!props.GetInt("eol.auto")) {
+		SetEol();
+	}
+
+	codePage = props.GetInt("code.page");
+	if (unicodeMode != uni8Bit) {
+		// Override properties file to ensure Unicode displayed.
+		codePage = SC_CP_UTF8;
+	}
+	SendEditor(SCI_SETCODEPAGE, codePage);
+	SendOutput(SCI_SETCODEPAGE, codePage);
+
+	characterSet = props.GetInt("character.set");
+
+#ifdef unix
+	SString localeCType = props.Get("LC_CTYPE");
+	if (localeCType.length())
+		setlocale(LC_CTYPE, localeCType.c_str());
+	else
+		setlocale(LC_CTYPE, "C");
+#endif
+
+	SendEditor(SCI_SETCARETFORE,
+	           ColourOfProperty(props, "caret.fore", ColourDesired(0, 0, 0)));
+
+	SendEditor(SCI_SETMOUSEDWELLTIME,
+	           props.GetInt("dwell.period", SC_TIME_FOREVER), 0);
+
+	SendEditor(SCI_SETCARETWIDTH, props.GetInt("caret.width", 1));
+	SendOutput(SCI_SETCARETWIDTH, props.GetInt("caret.width", 1));
+
+	SString caretLineBack = props.Get("caret.line.back");
+	if (caretLineBack.length()) {
+		SendEditor(SCI_SETCARETLINEVISIBLE, 1);
+		SendEditor(SCI_SETCARETLINEBACK, ColourFromString(caretLineBack));
+	} else {
+		SendEditor(SCI_SETCARETLINEVISIBLE, 0);
+	}
+
+	SString controlCharSymbol = props.Get("control.char.symbol");
+	if (controlCharSymbol.length()) {
+		SendEditor(SCI_SETCONTROLCHARSYMBOL, static_cast<unsigned char>(controlCharSymbol[0]));
+	} else {
+		SendEditor(SCI_SETCONTROLCHARSYMBOL, 0);
+	}
+
+	SendEditor(SCI_CALLTIPSETBACK,
+	           ColourOfProperty(props, "calltip.back", ColourDesired(0xff, 0xff, 0xff)));
+
+	SString caretPeriod = props.Get("caret.period");
+	if (caretPeriod.length()) {
+		SendEditor(SCI_SETCARETPERIOD, caretPeriod.value());
+		SendOutput(SCI_SETCARETPERIOD, caretPeriod.value());
+	}
+
+	int caretSlop = props.GetInt("caret.policy.xslop", 1) ? CARET_SLOP : 0;
+	int caretZone = props.GetInt("caret.policy.width", 50);
+	int caretStrict = props.GetInt("caret.policy.xstrict") ? CARET_STRICT : 0;
+	int caretEven = props.GetInt("caret.policy.xeven", 1) ? CARET_EVEN : 0;
+	int caretJumps = props.GetInt("caret.policy.xjumps") ? CARET_JUMPS : 0;
+	SendEditor(SCI_SETXCARETPOLICY, caretStrict | caretSlop | caretEven | caretJumps, caretZone);
+
+	caretSlop = props.GetInt("caret.policy.yslop", 1) ? CARET_SLOP : 0;
+	caretZone = props.GetInt("caret.policy.lines");
+	caretStrict = props.GetInt("caret.policy.ystrict") ? CARET_STRICT : 0;
+	caretEven = props.GetInt("caret.policy.yeven", 1) ? CARET_EVEN : 0;
+	caretJumps = props.GetInt("caret.policy.yjumps") ? CARET_JUMPS : 0;
+	SendEditor(SCI_SETYCARETPOLICY, caretStrict | caretSlop | caretEven | caretJumps, caretZone);
+
+	int visibleStrict = props.GetInt("visible.policy.strict") ? VISIBLE_STRICT : 0;
+	int visibleSlop = props.GetInt("visible.policy.slop", 1) ? VISIBLE_SLOP : 0;
+	int visibleLines = props.GetInt("visible.policy.lines");
+	SendEditor(SCI_SETVISIBLEPOLICY, visibleStrict | visibleSlop, visibleLines);
+
+	SendEditor(SCI_SETEDGECOLUMN, props.GetInt("edge.column", 0));
+	SendEditor(SCI_SETEDGEMODE, props.GetInt("edge.mode", EDGE_NONE));
+	SendEditor(SCI_SETEDGECOLOUR,
+	           ColourOfProperty(props, "edge.colour", ColourDesired(0xff, 0xda, 0xda)));
+
+	SString selFore = props.Get("selection.fore");
+	if (selFore.length()) {
+		SendChildren(SCI_SETSELFORE, 1, ColourFromString(selFore));
+	} else {
+		SendChildren(SCI_SETSELFORE, 0, 0);
+	}
+	SString selBack = props.Get("selection.back");
+	if (selBack.length()) {
+		SendChildren(SCI_SETSELBACK, 1, ColourFromString(selBack));
+	} else {
+		if (selFore.length())
+			SendChildren(SCI_SETSELBACK, 0, 0);
+		else	// Have to show selection somehow
+			SendChildren(SCI_SETSELBACK, 1, ColourDesired(0xC0, 0xC0, 0xC0).AsLong());
+	}
+
+	SString foldColour = props.Get("fold.margin.colour");
+	if (foldColour.length()) {
+		SendChildren(SCI_SETFOLDMARGINCOLOUR, 1, ColourFromString(foldColour));
+	} else {
+		SendChildren(SCI_SETFOLDMARGINCOLOUR, 0, 0);
+	}
+	SString foldHiliteColour = props.Get("fold.margin.highlight.colour");
+	if (foldHiliteColour.length()) {
+		SendChildren(SCI_SETFOLDMARGINHICOLOUR, 1, ColourFromString(foldHiliteColour));
+	} else {
+		SendChildren(SCI_SETFOLDMARGINHICOLOUR, 0, 0);
+	}
+
+	SString whitespaceFore = props.Get("whitespace.fore");
+	if (whitespaceFore.length()) {
+		SendChildren(SCI_SETWHITESPACEFORE, 1, ColourFromString(whitespaceFore));
+	} else {
+		SendChildren(SCI_SETWHITESPACEFORE, 0, 0);
+	}
+	SString whitespaceBack = props.Get("whitespace.back");
+	if (whitespaceBack.length()) {
+		SendChildren(SCI_SETWHITESPACEBACK, 1, ColourFromString(whitespaceBack));
+	} else {
+		SendChildren(SCI_SETWHITESPACEBACK, 0, 0);
+	}
+
+	char bracesStyleKey[200];
+	sprintf(bracesStyleKey, "braces.%s.style", language.c_str());
+	bracesStyle = props.GetInt(bracesStyleKey, 0);
+
+	char key[200];
+	SString sval;
+
+	sval = FindLanguageProperty("calltip.*.ignorecase");
+	callTipIgnoreCase = sval == "1";
+
+	calltipWordCharacters = FindLanguageProperty("calltip.*.word.characters",
+		"_abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ");
+
+	calltipParametersStart = FindLanguageProperty("calltip.*.parameters.start", "(");
+	calltipParametersEnd = FindLanguageProperty("calltip.*.parameters.end", ")");
+	calltipParametersSeparators = FindLanguageProperty("calltip.*.parameters.separators", ",;");
+
+	calltipEndDefinition = FindLanguageProperty("calltip.*.end.definition");
+
+	sprintf(key, "autocomplete.%s.start.characters", language.c_str());
+	autoCompleteStartCharacters = props.GetExpanded(key);
+	if (autoCompleteStartCharacters == "")
+		autoCompleteStartCharacters = props.GetExpanded("autocomplete.*.start.characters");
+	// "" is a quite reasonable value for this setting
+
+	sprintf(key, "autocomplete.%s.fillups", language.c_str());
+	autoCompleteFillUpCharacters = props.GetExpanded(key);
+	if (autoCompleteFillUpCharacters == "")
+		autoCompleteFillUpCharacters =
+			props.GetExpanded("autocomplete.*.fillups");
+	SendEditorString(SCI_AUTOCSETFILLUPS, 0,
+		autoCompleteFillUpCharacters.c_str());
+
+	sprintf(key, "autocomplete.%s.ignorecase", "*");
+	sval = props.GetNewExpand(key);
+	autoCompleteIgnoreCase = sval == "1";
+	sprintf(key, "autocomplete.%s.ignorecase", language.c_str());
+	sval = props.GetNewExpand(key);
+	if (sval != "")
+		autoCompleteIgnoreCase = sval == "1";
+	SendEditor(SCI_AUTOCSETIGNORECASE, autoCompleteIgnoreCase ? 1 : 0);
+
+	int autoCChooseSingle = props.GetInt("autocomplete.choose.single");
+	SendEditor(SCI_AUTOCSETCHOOSESINGLE, autoCChooseSingle),
+
+	SendEditor(SCI_AUTOCSETCANCELATSTART, 0);
+	SendEditor(SCI_AUTOCSETDROPRESTOFWORD, 0);
+
+	if (firstPropertiesRead) {
+		ReadPropertiesInitial();
+	}
+
+	ReadFontProperties();
+
+	SendEditor(SCI_SETUSEPALETTE, props.GetInt("use.palette"));
+	SendEditor(SCI_SETPRINTMAGNIFICATION, props.GetInt("print.magnification"));
+	SendEditor(SCI_SETPRINTCOLOURMODE, props.GetInt("print.colour.mode"));
+
+	clearBeforeExecute = props.GetInt("clear.before.execute");
+	timeCommands = props.GetInt("time.commands");
+
+	int blankMarginLeft = props.GetInt("blank.margin.left", 1);
+	int blankMarginRight = props.GetInt("blank.margin.right", 1);
+	SendEditor(SCI_SETMARGINLEFT, 0, blankMarginLeft);
+	SendEditor(SCI_SETMARGINRIGHT, 0, blankMarginRight);
+	SendOutput(SCI_SETMARGINLEFT, 0, blankMarginLeft);
+	SendOutput(SCI_SETMARGINRIGHT, 0, blankMarginRight);
+
+	SendEditor(SCI_SETMARGINWIDTHN, 1, margin ? marginWidth : 0);
+
+	SString lineMarginProp = props.Get("line.margin.width");
+	lineNumbersWidth = lineMarginProp.value();
+	if (lineNumbersWidth == 0)
+		lineNumbersWidth = lineNumbersWidthDefault;
+	lineNumbersExpand = lineMarginProp.contains('+');
+
+	SetLineNumberWidth();
+
+	bufferedDraw = props.GetInt("buffered.draw", 1);
+	SendEditor(SCI_SETBUFFEREDDRAW, bufferedDraw);
+
+	twoPhaseDraw = props.GetInt("two.phase.draw", 1);
+	SendEditor(SCI_SETTWOPHASEDRAW, twoPhaseDraw);
+
+	SendEditor(SCI_SETLAYOUTCACHE, props.GetInt("cache.layout"));
+	SendOutput(SCI_SETLAYOUTCACHE, props.GetInt("output.cache.layout"));
+
+	bracesCheck = props.GetInt("braces.check");
+	bracesSloppy = props.GetInt("braces.sloppy");
+
+	SendEditor(SCI_SETCHARSDEFAULT);
+	wordCharacters = props.GetNewExpand("word.characters.", fileNameForExtension.c_str());
+	if (wordCharacters.length()) {
+		SendEditorString(SCI_SETWORDCHARS, 0, wordCharacters.c_str());
+	} else {
+		wordCharacters = "_abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ";
+	}
+
+	whitespaceCharacters = props.GetNewExpand("whitespace.characters.", fileNameForExtension.c_str());
+	if (whitespaceCharacters.length()) {
+		SendEditorString(SCI_SETWHITESPACECHARS, 0, whitespaceCharacters.c_str());
+	}
+
+	SendEditor(SCI_SETTABINDENTS, props.GetInt("tab.indents", 1));
+	SendEditor(SCI_SETBACKSPACEUNINDENTS, props.GetInt("backspace.unindents", 1));
+
+	indentOpening = props.GetInt("indent.opening");
+	indentClosing = props.GetInt("indent.closing");
+	indentMaintain = props.GetNewExpand("indent.maintain.", fileNameForExtension.c_str()).value();
+
+	SString lookback = props.GetNewExpand("statement.lookback.", fileNameForExtension.c_str());
+	statementLookback = lookback.value();
+	statementIndent = GetStyleAndWords("statement.indent.");
+	statementEnd = GetStyleAndWords("statement.end.");
+	blockStart = GetStyleAndWords("block.start.");
+	blockEnd = GetStyleAndWords("block.end.");
+
+	SString list;
+	list = props.GetNewExpand("preprocessor.symbol.", fileNameForExtension.c_str());
+	preprocessorSymbol = list[0];
+	list = props.GetNewExpand("preprocessor.start.", fileNameForExtension.c_str());
+	preprocCondStart.Clear();
+	preprocCondStart.Set(list.c_str());
+	list = props.GetNewExpand("preprocessor.middle.", fileNameForExtension.c_str());
+	preprocCondMiddle.Clear();
+	preprocCondMiddle.Set(list.c_str());
+	list = props.GetNewExpand("preprocessor.end.", fileNameForExtension.c_str());
+	preprocCondEnd.Clear();
+	preprocCondEnd.Set(list.c_str());
+
+	memFiles.AppendList(props.GetNewExpand("find.files"));
+
+	SendEditor(SCI_SETWRAPVISUALFLAGS, props.GetInt("wrap.visual.flags"));
+	SendEditor(SCI_SETWRAPVISUALFLAGSLOCATION, props.GetInt("wrap.visual.flags.location"));
+ 	SendEditor(SCI_SETWRAPSTARTINDENT, props.GetInt("wrap.visual.startindent"));
+
+	if (props.GetInt("wrap.aware.home.end.keys",0)) {
+		if (props.GetInt("vc.home.key", 1)) {
+			AssignKey(SCK_HOME, 0, SCI_VCHOMEWRAP);
+			AssignKey(SCK_HOME, SCMOD_SHIFT, SCI_VCHOMEWRAPEXTEND);
+			AssignKey(SCK_HOME, SCMOD_SHIFT | SCMOD_ALT, SCI_VCHOMERECTEXTEND);
+		} else {
+			AssignKey(SCK_HOME, 0, SCI_HOMEWRAP);
+			AssignKey(SCK_HOME, SCMOD_SHIFT, SCI_HOMEWRAPEXTEND);
+			AssignKey(SCK_HOME, SCMOD_SHIFT | SCMOD_ALT, SCI_HOMERECTEXTEND);
+		}
+		AssignKey(SCK_END, 0, SCI_LINEENDWRAP);
+		AssignKey(SCK_END, SCMOD_SHIFT, SCI_LINEENDWRAPEXTEND);
+	} else {
+		if (props.GetInt("vc.home.key", 1)) {
+			AssignKey(SCK_HOME, 0, SCI_VCHOME);
+			AssignKey(SCK_HOME, SCMOD_SHIFT, SCI_VCHOMEEXTEND);
+			AssignKey(SCK_HOME, SCMOD_SHIFT | SCMOD_ALT, SCI_VCHOMERECTEXTEND);
+		} else {
+			AssignKey(SCK_HOME, 0, SCI_HOME);
+			AssignKey(SCK_HOME, SCMOD_SHIFT, SCI_HOMEEXTEND);
+			AssignKey(SCK_HOME, SCMOD_SHIFT | SCMOD_ALT, SCI_HOMERECTEXTEND);
+		}
+		AssignKey(SCK_END, 0, SCI_LINEEND);
+		AssignKey(SCK_END, SCMOD_SHIFT, SCI_LINEENDEXTEND);
+	}
+
+	AssignKey('L', SCMOD_SHIFT | SCMOD_CTRL, SCI_LINEDELETE);
+
+	scrollOutput = props.GetInt("output.scroll", 1);
+
+	tabHideOne = props.GetInt("tabbar.hide.one");
+
+	SetToolsMenu();
+
+	SendEditor(SCI_SETFOLDFLAGS, props.GetInt("fold.flags"));
+
+	// To put the folder markers in the line number region
+	//SendEditor(SCI_SETMARGINMASKN, 0, SC_MASK_FOLDERS);
+
+	SendEditor(SCI_SETMODEVENTMASK, SC_MOD_CHANGEFOLD);
+
+	if (0==props.GetInt("undo.redo.lazy")) {
+		// Trap for insert/delete notifications (also fired by undo
+		// and redo) so that the buttons can be enabled if needed.
+		SendEditor(SCI_SETMODEVENTMASK, SC_MOD_INSERTTEXT | SC_MOD_DELETETEXT
+			| SC_LASTSTEPINUNDOREDO | SendEditor(SCI_GETMODEVENTMASK, 0));
+
+		//SC_LASTSTEPINUNDOREDO is probably not needed in the mask; it
+		//doesn't seem to fire as an event of its own; just modifies the
+		//insert and delete events.
+	}
+
+	// Create a margin column for the folding symbols
+	SendEditor(SCI_SETMARGINTYPEN, 2, SC_MARGIN_SYMBOL);
+
+	SendEditor(SCI_SETMARGINWIDTHN, 2, foldMargin ? foldMarginWidth : 0);
+
+	SendEditor(SCI_SETMARGINMASKN, 2, SC_MASK_FOLDERS);
+	SendEditor(SCI_SETMARGINSENSITIVEN, 2, 1);
+
+	switch (props.GetInt("fold.symbols")) {
+	case 0:
+		// Arrow pointing right for contracted folders, arrow pointing down for expanded
+		DefineMarker(SC_MARKNUM_FOLDEROPEN, SC_MARK_ARROWDOWN,
+		             ColourDesired(0, 0, 0), ColourDesired(0, 0, 0));
+		DefineMarker(SC_MARKNUM_FOLDER, SC_MARK_ARROW,
+		             ColourDesired(0, 0, 0), ColourDesired(0, 0, 0));
+		DefineMarker(SC_MARKNUM_FOLDERSUB, SC_MARK_EMPTY,
+		             ColourDesired(0, 0, 0), ColourDesired(0, 0, 0));
+		DefineMarker(SC_MARKNUM_FOLDERTAIL, SC_MARK_EMPTY,
+		             ColourDesired(0, 0, 0), ColourDesired(0, 0, 0));
+		DefineMarker(SC_MARKNUM_FOLDEREND, SC_MARK_EMPTY,
+		             ColourDesired(0xff, 0xff, 0xff), ColourDesired(0, 0, 0));
+		DefineMarker(SC_MARKNUM_FOLDEROPENMID, SC_MARK_EMPTY,
+		             ColourDesired(0xff, 0xff, 0xff), ColourDesired(0, 0, 0));
+		DefineMarker(SC_MARKNUM_FOLDERMIDTAIL, SC_MARK_EMPTY, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0, 0, 0));
+		break;
+	case 1:
+		// Plus for contracted folders, minus for expanded
+		DefineMarker(SC_MARKNUM_FOLDEROPEN, SC_MARK_MINUS, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0, 0, 0));
+		DefineMarker(SC_MARKNUM_FOLDER, SC_MARK_PLUS, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0, 0, 0));
+		DefineMarker(SC_MARKNUM_FOLDERSUB, SC_MARK_EMPTY, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0, 0, 0));
+		DefineMarker(SC_MARKNUM_FOLDERTAIL, SC_MARK_EMPTY, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0, 0, 0));
+		DefineMarker(SC_MARKNUM_FOLDEREND, SC_MARK_EMPTY, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0, 0, 0));
+		DefineMarker(SC_MARKNUM_FOLDEROPENMID, SC_MARK_EMPTY, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0, 0, 0));
+		DefineMarker(SC_MARKNUM_FOLDERMIDTAIL, SC_MARK_EMPTY, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0, 0, 0));
+		break;
+	case 2:
+		// Like a flattened tree control using circular headers and curved joins
+		DefineMarker(SC_MARKNUM_FOLDEROPEN, SC_MARK_CIRCLEMINUS, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0x40, 0x40, 0x40));
+		DefineMarker(SC_MARKNUM_FOLDER, SC_MARK_CIRCLEPLUS, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0x40, 0x40, 0x40));
+		DefineMarker(SC_MARKNUM_FOLDERSUB, SC_MARK_VLINE, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0x40, 0x40, 0x40));
+		DefineMarker(SC_MARKNUM_FOLDERTAIL, SC_MARK_LCORNERCURVE, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0x40, 0x40, 0x40));
+		DefineMarker(SC_MARKNUM_FOLDEREND, SC_MARK_CIRCLEPLUSCONNECTED, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0x40, 0x40, 0x40));
+		DefineMarker(SC_MARKNUM_FOLDEROPENMID, SC_MARK_CIRCLEMINUSCONNECTED, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0x40, 0x40, 0x40));
+		DefineMarker(SC_MARKNUM_FOLDERMIDTAIL, SC_MARK_TCORNERCURVE, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0x40, 0x40, 0x40));
+		break;
+	case 3:
+		// Like a flattened tree control using square headers
+		DefineMarker(SC_MARKNUM_FOLDEROPEN, SC_MARK_BOXMINUS, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0x80, 0x80, 0x80));
+		DefineMarker(SC_MARKNUM_FOLDER, SC_MARK_BOXPLUS, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0x80, 0x80, 0x80));
+		DefineMarker(SC_MARKNUM_FOLDERSUB, SC_MARK_VLINE, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0x80, 0x80, 0x80));
+		DefineMarker(SC_MARKNUM_FOLDERTAIL, SC_MARK_LCORNER, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0x80, 0x80, 0x80));
+		DefineMarker(SC_MARKNUM_FOLDEREND, SC_MARK_BOXPLUSCONNECTED, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0x80, 0x80, 0x80));
+		DefineMarker(SC_MARKNUM_FOLDEROPENMID, SC_MARK_BOXMINUSCONNECTED, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0x80, 0x80, 0x80));
+		DefineMarker(SC_MARKNUM_FOLDERMIDTAIL, SC_MARK_TCORNER, ColourDesired(0xff, 0xff, 0xff), ColourDesired(0x80, 0x80, 0x80));
+		break;
+	}
+
+	SendEditor(SCI_MARKERSETFORE, SciTE_MARKER_BOOKMARK,
+	           ColourOfProperty(props, "bookmark.fore", ColourDesired(0, 0, 0x7f)));
+	SendEditor(SCI_MARKERSETBACK, SciTE_MARKER_BOOKMARK,
+	           ColourOfProperty(props, "bookmark.back", ColourDesired(0x80, 0xff, 0xff)));
+	SString bookMarkXPM = props.Get("bookmark.pixmap");
+	if (bookMarkXPM.length()) {
+		SendEditorString(SCI_MARKERDEFINEPIXMAP, SciTE_MARKER_BOOKMARK,
+			bookMarkXPM.c_str());
+	} else {
+		SendEditor(SCI_MARKERDEFINE, SciTE_MARKER_BOOKMARK, SC_MARK_CIRCLE);
+	}
+
+	SendEditor(SCI_SETSCROLLWIDTH, props.GetInt("horizontal.scroll.width", 2000));
+	SendOutput(SCI_SETSCROLLWIDTH, props.GetInt("output.horizontal.scroll.width", 2000));
+
+	// Do these last as they force a style refresh
+	SendEditor(SCI_SETHSCROLLBAR, props.GetInt("horizontal.scrollbar", 1));
+	SendOutput(SCI_SETHSCROLLBAR, props.GetInt("output.horizontal.scrollbar", 1));
+
+	SendEditor(SCI_SETENDATLASTLINE, props.GetInt("end.at.last.line", 1));
+
+	if (extender) {
+		char defaultDir[MAX_PATH];
+		GetDefaultDirectory(defaultDir, sizeof(defaultDir));
+		char scriptPath[MAX_PATH];
+
+		// Check for an extension script
+		SString extensionFile = props.GetNewExpand("extension.", fileNameForExtension.c_str());
+		if (extensionFile.length()) {
+			// find file in local directory
+			char docDir[MAX_PATH];
+			GetDocumentDirectory(docDir, sizeof(docDir));
+			if (Exists(docDir, extensionFile.c_str(), scriptPath)) {
+				// Found file in document directory
+				extender->Load(scriptPath);
+			} else if (Exists(defaultDir, extensionFile.c_str(), scriptPath)) {
+				// Found file in global directory
+				extender->Load(scriptPath);
+			} else if (Exists("", extensionFile.c_str(), scriptPath)) {
+				// Found as completely specified file name
+				extender->Load(scriptPath);
+			}
+		}
+	}
+	firstPropertiesRead = false;
+	needReadProperties = false;
+}
+
+void SciTEBase::ReadFontProperties() {
+	char key[200];
+	SString sval;
+
+	// Set styles
+	// For each window set the global default style, then the language default style, then the other global styles, then the other language styles
+
+	SendEditor(SCI_STYLERESETDEFAULT, 0, 0);
+	SendOutput(SCI_STYLERESETDEFAULT, 0, 0);
+
+	sprintf(key, "style.%s.%0d", "*", STYLE_DEFAULT);
+	sval = props.GetNewExpand(key);
+	SetOneStyle(wEditor, STYLE_DEFAULT, sval.c_str());
+	SetOneStyle(wOutput, STYLE_DEFAULT, sval.c_str());
+
+	sprintf(key, "style.%s.%0d", language.c_str(), STYLE_DEFAULT);
+	sval = props.GetNewExpand(key);
+	SetOneStyle(wEditor, STYLE_DEFAULT, sval.c_str());
+
+	SendEditor(SCI_STYLECLEARALL, 0, 0);
+
+	SetStyleFor(wEditor, "*");
+	SetStyleFor(wEditor, language.c_str());
+
+	SendOutput(SCI_STYLECLEARALL, 0, 0);
+
+	sprintf(key, "style.%s.%0d", "errorlist", STYLE_DEFAULT);
+	sval = props.GetNewExpand(key);
+	SetOneStyle(wOutput, STYLE_DEFAULT, sval.c_str());
+
+	SendOutput(SCI_STYLECLEARALL, 0, 0);
+
+	SetStyleFor(wOutput, "*");
+	SetStyleFor(wOutput, "errorlist");
+
+	if (useMonoFont) {
+		sval = props.GetExpanded("font.monospace");
+		StyleDefinition sd(sval.c_str());
+		for (int style = 0; style <= STYLE_MAX; style++) {
+			if (style != STYLE_LINENUMBER) {
+				if (sd.specified & StyleDefinition::sdFont) {
+					SendEditorString(SCI_STYLESETFONT, style, sd.font.c_str());
+				}
+				if (sd.specified & StyleDefinition::sdSize) {
+					SendEditor(SCI_STYLESETSIZE, style, sd.size);
+				}
+			}
+		}
+	}
+}
+
+// Properties that are interactively modifiable are only read from the properties file once.
+void SciTEBase::SetPropertiesInitial() {
+	splitVertical = props.GetInt("split.vertical");
+	openFilesHere = props.GetInt("check.if.already.open");
+	wrap = props.GetInt("wrap");
+	wrapOutput = props.GetInt("output.wrap");
+	indentationWSVisible = props.GetInt("view.indentation.whitespace", 1);
+	sbVisible = props.GetInt("statusbar.visible");
+	tbVisible = props.GetInt("toolbar.visible");
+	tabVisible = props.GetInt("tabbar.visible");
+	tabMultiLine = props.GetInt("tabbar.multiline");
+	lineNumbers = props.GetInt("line.margin.visible");
+	marginWidth = 0;
+	SString margwidth = props.Get("margin.width");
+	if (margwidth.length())
+		marginWidth = margwidth.value();
+	margin = marginWidth;
+	if (marginWidth == 0)
+		marginWidth = marginWidthDefault;
+	foldMarginWidth = props.GetInt("fold.margin.width", foldMarginWidthDefault);
+	foldMargin = foldMarginWidth;
+	if (foldMarginWidth == 0)
+		foldMarginWidth = foldMarginWidthDefault;
+
+	matchCase = props.GetInt("find.replace.matchcase");
+	regExp = props.GetInt("find.replace.regexp");
+	unSlash = props.GetInt("find.replace.escapes");
+	wrapFind = props.GetInt("find.replace.wrap", 1);
+}
+
+SString SciTEBase::LocaliseString(const char *s, bool retainIfNotFound) {
+	SString translation = s;
+	int ellipseIndicator = translation.remove("...");
+	int accessKeyPresent = translation.remove(menuAccessIndicator);
+	translation.lowercase();
+	translation.substitute("\n", "\\n");
+	translation = propsUI.Get(translation.c_str());
+	if (translation.length()) {
+		if (ellipseIndicator)
+			translation += "...";
+		if (0 == accessKeyPresent)
+			translation.remove("&");
+		translation.substitute("&", menuAccessIndicator);
+		translation.substitute("\\n", "\n");
+	} else {
+		translation = props.Get("translation.missing");
+	}
+	if ((translation.length() > 0) || !retainIfNotFound) {
+		return translation;
+	}
+	return s;
+}
+
+SString SciTEBase::LocaliseMessage(const char *s, const char *param0, const char *param1, const char *param2) {
+	SString translation = LocaliseString(s);
+	if (param0)
+		translation.substitute("^0", param0);
+	if (param1)
+		translation.substitute("^1", param1);
+	if (param2)
+		translation.substitute("^2", param2);
+	return translation;
+}
+
+void SciTEBase::ReadLocalisation() {
+	char propfile[MAX_PATH + 20];
+	char propdir[MAX_PATH + 20];
+	propsUI.Clear();
+	const char *title = "locale.properties";
+	SString localeProps = props.GetExpanded(title);
+	if (localeProps.length()) {
+		title = localeProps.c_str();
+	}
+	if (GetSciteDefaultHome(propdir, sizeof propdir)
+	    && BuildPath(propfile, propdir, title, sizeof propfile)) {
+		strcat(propdir, pathSepString);
+		propsUI.Read(propfile, propdir, importFiles, importMax);
+	}
+	localisationRead = true;
+}
+
+void SciTEBase::ReadPropertiesInitial() {
+	SetPropertiesInitial();
+	int sizeHorizontal = props.GetInt("output.horizontal.size", 0);
+	int sizeVertical = props.GetInt("output.vertical.size", 0);
+	if ((!splitVertical && (sizeVertical > 0) && (heightOutput < sizeVertical)) ||
+		(splitVertical && (sizeHorizontal > 0) && (heightOutput < sizeHorizontal))) {
+		heightOutput = NormaliseSplit(splitVertical ? sizeHorizontal : sizeVertical);
+		SizeSubWindows();
+		Redraw();
+	}
+	ViewWhitespace(props.GetInt("view.whitespace"));
+	SendEditor(SCI_SETINDENTATIONGUIDES, props.GetInt("view.indentation.guides"));
+	SendEditor(SCI_SETVIEWEOL, props.GetInt("view.eol"));
+	SendEditor(SCI_SETZOOM, props.GetInt("magnification"));
+	SendOutput(SCI_SETZOOM, props.GetInt("output.magnification"));
+	SendEditor(SCI_SETWRAPMODE, wrap ? SC_WRAP_WORD : SC_WRAP_NONE);
+	SendOutput(SCI_SETWRAPMODE, wrapOutput ? SC_WRAP_WORD : SC_WRAP_NONE);
+
+	useMonoFont = false;
+
+	SString menuLanguageProp = props.GetNewExpand("menu.language");
+	languageItems = 0;
+	for (unsigned int i = 0; i < menuLanguageProp.length(); i++) {
+		if (menuLanguageProp[i] == '|')
+			languageItems++;
+	}
+	languageItems /= 3;
+	languageMenu = new LanguageMenuItem[languageItems];
+
+	menuLanguageProp.substitute('|', '\0');
+	const char *sMenuLanguage = menuLanguageProp.c_str();
+	for (int item = 0; item < languageItems; item++) {
+		languageMenu[item].menuItem = sMenuLanguage;
+		sMenuLanguage += strlen(sMenuLanguage) + 1;
+		languageMenu[item].extension = sMenuLanguage;
+		sMenuLanguage += strlen(sMenuLanguage) + 1;
+		languageMenu[item].menuKey = sMenuLanguage;
+		sMenuLanguage += strlen(sMenuLanguage) + 1;
+	}
+	SetLanguageMenu();
+
+	// load the user defined short cut props
+	SString shortCutProp = props.GetNewExpand("user.shortcuts");
+	if ( shortCutProp.length() ) {
+		shortCutItems = 0;
+		for (unsigned int i = 0; i < shortCutProp.length(); i++) {
+			if (shortCutProp[i] == '|')
+				shortCutItems++;
+		}
+		shortCutItems /= 2;
+		shortCutItemList = new ShortcutItem[shortCutItems];
+		shortCutProp.substitute('|', '\0');
+		const char *sShortCutProp = shortCutProp.c_str();
+		for (int item = 0; item < shortCutItems; item++) {
+			shortCutItemList[item].menuKey = sShortCutProp;
+			sShortCutProp += strlen(sShortCutProp) + 1;
+			shortCutItemList[item].menuCommand = sShortCutProp;
+			sShortCutProp += strlen(sShortCutProp) + 1;
+		}
+	}
+	// end load the user defined short cut props
+
+
+#if PLAT_WIN
+
+	if (tabMultiLine) {	// Windows specific!
+		long wl = ::GetWindowLong(reinterpret_cast<HWND>(wTabBar.GetID()), GWL_STYLE);
+		::SetWindowLong(reinterpret_cast<HWND>(wTabBar.GetID()), GWL_STYLE, wl | TCS_MULTILINE);
+	}
+#endif
+
+	char homepath[MAX_PATH + 20];
+	if (GetSciteDefaultHome(homepath, sizeof(homepath))) {
+		props.Set("SciteDefaultHome", homepath);
+	}
+	if (GetSciteUserHome(homepath, sizeof(homepath))) {
+		props.Set("SciteUserHome", homepath);
+	}
+}
+
+bool SciTEBase::GetDefaultPropertiesFileName(char *pathDefaultProps,
+        char *pathDefaultDir, unsigned int lenPath) {
+	if (!GetSciteDefaultHome(pathDefaultDir, lenPath)) {
+		return false;
+	}
+	return BuildPath(pathDefaultProps, pathDefaultDir, propGlobalFileName, lenPath);
+}
+
+bool SciTEBase::GetAbbrevPropertiesFileName(char *pathAbbrevProps,
+        char *pathDefaultDir, unsigned int lenPath) {
+	if (!GetSciteUserHome(pathDefaultDir, lenPath)) {
+		return false;
+	}
+	return BuildPath(pathAbbrevProps, pathDefaultDir, propAbbrevFileName, lenPath);
+}
+
+bool SciTEBase::GetUserPropertiesFileName(char *pathUserProps,
+        char *pathUserDir, unsigned int lenPath) {
+	if (!GetSciteUserHome(pathUserDir, lenPath)) {
+		return false;
+	}
+	return BuildPath(pathUserProps, pathUserDir, propUserFileName, lenPath);
+}
+
+void SciTEBase::OpenProperties(int propsFile) {
+	char propfile[MAX_PATH + 20];
+	char propdir[MAX_PATH + 20];
+	if (propsFile == IDM_OPENLOCALPROPERTIES) {
+		GetDocumentDirectory(propfile, sizeof(propfile));
+#ifdef __vms
+
+		strcpy(propfile, VMSToUnixStyle(propfile));
+#endif
+
+		strcat(propfile, pathSepString);
+		strcat(propfile, propFileName);
+		Open(propfile, ofQuiet);
+	} else if (propsFile == IDM_OPENUSERPROPERTIES) {
+		if (GetUserPropertiesFileName(propfile, propdir, sizeof(propfile))) {
+			Open(propfile, ofQuiet);
+		}
+	} else if (propsFile == IDM_OPENABBREVPROPERTIES) {
+		if (GetAbbrevPropertiesFileName(propfile, propdir, sizeof(propfile))) {
+			Open(propfile, ofQuiet);
+		}
+	} else if (propsFile == IDM_OPENGLOBALPROPERTIES) {
+		if (GetDefaultPropertiesFileName(propfile, propdir, sizeof(propfile))) {
+			Open(propfile, ofQuiet);
+		}
+	} else if (propsFile == IDM_OPENLUAEXTERNALFILE) {
+		SString extlua = props.GetExpanded("ext.lua.startup.script");
+		if (extlua.length()) {
+			Open(extlua.c_str(), ofQuiet);
+		}
+	}
+}
+
+// return the int value of the command name passed in.
+int SciTEBase::GetMenuCommandAsInt(SString commandName) {
+	struct {
+		const char *name;
+		int id;
+	} idmTable[] = {
+//++Autogenerated -- run ../scintilla/src/LexGen.py to regenerate
+//**\(\t\t{"\*",\t\*},\n\)
+		{"IDM_MRUFILE",	IDM_MRUFILE},
+		{"IDM_TOOLS",	IDM_TOOLS},
+		{"IDM_BUFFER",	IDM_BUFFER},
+		{"IDM_IMPORT",	IDM_IMPORT},
+		{"IDM_LANGUAGE",	IDM_LANGUAGE},
+		{"IDM_NEW",	IDM_NEW},
+		{"IDM_OPEN",	IDM_OPEN},
+		{"IDM_OPENSELECTED",	IDM_OPENSELECTED},
+		{"IDM_REVERT",	IDM_REVERT},
+		{"IDM_CLOSE",	IDM_CLOSE},
+		{"IDM_SAVE",	IDM_SAVE},
+		{"IDM_SAVEAS",	IDM_SAVEAS},
+		{"IDM_SAVEASHTML",	IDM_SAVEASHTML},
+		{"IDM_SAVEASRTF",	IDM_SAVEASRTF},
+		{"IDM_SAVEASPDF",	IDM_SAVEASPDF},
+		{"IDM_FILER",	IDM_FILER},
+		{"IDM_SAVEASTEX",	IDM_SAVEASTEX},
+		{"IDM_SAVEACOPY",	IDM_SAVEACOPY},
+		{"IDM_SAVEASXML",	IDM_SAVEASXML},
+		{"IDM_MRU_SEP",	IDM_MRU_SEP},
+		{"IDM_PRINTSETUP",	IDM_PRINTSETUP},
+		{"IDM_PRINT",	IDM_PRINT},
+		{"IDM_LOADSESSION",	IDM_LOADSESSION},
+		{"IDM_SAVESESSION",	IDM_SAVESESSION},
+		{"IDM_QUIT",	IDM_QUIT},
+		{"IDM_ENCODING_DEFAULT",	IDM_ENCODING_DEFAULT},
+		{"IDM_ENCODING_UCS2BE",	IDM_ENCODING_UCS2BE},
+		{"IDM_ENCODING_UCS2LE",	IDM_ENCODING_UCS2LE},
+		{"IDM_ENCODING_UTF8",	IDM_ENCODING_UTF8},
+		{"IDM_ENCODING_UCOOKIE",	IDM_ENCODING_UCOOKIE},
+		{"IDM_UNDO",	IDM_UNDO},
+		{"IDM_REDO",	IDM_REDO},
+		{"IDM_CUT",	IDM_CUT},
+		{"IDM_COPY",	IDM_COPY},
+		{"IDM_PASTE",	IDM_PASTE},
+		{"IDM_CLEAR",	IDM_CLEAR},
+		{"IDM_SELECTALL",	IDM_SELECTALL},
+		{"IDM_PASTEANDDOWN",	IDM_PASTEANDDOWN},
+		{"IDM_FIND",	IDM_FIND},
+		{"IDM_FINDNEXT",	IDM_FINDNEXT},
+		{"IDM_FINDNEXTBACK",	IDM_FINDNEXTBACK},
+		{"IDM_FINDNEXTSEL",	IDM_FINDNEXTSEL},
+		{"IDM_FINDNEXTBACKSEL",	IDM_FINDNEXTBACKSEL},
+		{"IDM_FINDINFILES",	IDM_FINDINFILES},
+		{"IDM_REPLACE",	IDM_REPLACE},
+		{"IDM_GOTO",	IDM_GOTO},
+		{"IDM_BOOKMARK_NEXT",	IDM_BOOKMARK_NEXT},
+		{"IDM_BOOKMARK_TOGGLE",	IDM_BOOKMARK_TOGGLE},
+		{"IDM_BOOKMARK_PREV",	IDM_BOOKMARK_PREV},
+		{"IDM_BOOKMARK_CLEARALL",	IDM_BOOKMARK_CLEARALL},
+		{"IDM_BOOKMARK_NEXT_SELECT",	IDM_BOOKMARK_NEXT_SELECT},
+		{"IDM_BOOKMARK_PREV_SELECT",	IDM_BOOKMARK_PREV_SELECT},
+		{"IDM_MATCHBRACE",	IDM_MATCHBRACE},
+		{"IDM_SELECTTOBRACE",	IDM_SELECTTOBRACE},
+		{"IDM_SHOWCALLTIP",	IDM_SHOWCALLTIP},
+		{"IDM_COMPLETE",	IDM_COMPLETE},
+		{"IDM_COMPLETEWORD",	IDM_COMPLETEWORD},
+		{"IDM_EXPAND",	IDM_EXPAND},
+		{"IDM_TOGGLE_FOLDALL",	IDM_TOGGLE_FOLDALL},
+		{"IDM_UPRCASE",	IDM_UPRCASE},
+		{"IDM_LWRCASE",	IDM_LWRCASE},
+		{"IDM_ABBREV",	IDM_ABBREV},
+		{"IDM_BLOCK_COMMENT",	IDM_BLOCK_COMMENT},
+		{"IDM_STREAM_COMMENT",	IDM_STREAM_COMMENT},
+		{"IDM_COPYASRTF",	IDM_COPYASRTF},
+		{"IDM_BOX_COMMENT",	IDM_BOX_COMMENT},
+		{"IDM_INS_ABBREV",	IDM_INS_ABBREV},
+		{"IDM_JOIN",	IDM_JOIN},
+		{"IDM_SPLIT",	IDM_SPLIT},
+		{"IDM_INCSEARCH",	IDM_INCSEARCH},
+		{"IDM_ENTERSELECTION",	IDM_ENTERSELECTION},
+		{"IDM_PREVMATCHPPC",	IDM_PREVMATCHPPC},
+		{"IDM_SELECTTOPREVMATCHPPC",	IDM_SELECTTOPREVMATCHPPC},
+		{"IDM_NEXTMATCHPPC",	IDM_NEXTMATCHPPC},
+		{"IDM_SELECTTONEXTMATCHPPC",	IDM_SELECTTONEXTMATCHPPC},
+		{"IDM_COMPILE",	IDM_COMPILE},
+		{"IDM_BUILD",	IDM_BUILD},
+		{"IDM_GO",	IDM_GO},
+		{"IDM_STOPEXECUTE",	IDM_STOPEXECUTE},
+		{"IDM_FINISHEDEXECUTE",	IDM_FINISHEDEXECUTE},
+		{"IDM_NEXTMSG",	IDM_NEXTMSG},
+		{"IDM_PREVMSG",	IDM_PREVMSG},
+		{"IDM_MACRO_SEP",	IDM_MACRO_SEP},
+		{"IDM_MACRORECORD",	IDM_MACRORECORD},
+		{"IDM_MACROSTOPRECORD",	IDM_MACROSTOPRECORD},
+		{"IDM_MACROPLAY",	IDM_MACROPLAY},
+		{"IDM_MACROLIST",	IDM_MACROLIST},
+		{"IDM_ACTIVATE",	IDM_ACTIVATE},
+		{"IDM_SRCWIN",	IDM_SRCWIN},
+		{"IDM_RUNWIN",	IDM_RUNWIN},
+		{"IDM_TOOLWIN",	IDM_TOOLWIN},
+		{"IDM_STATUSWIN",	IDM_STATUSWIN},
+		{"IDM_TABWIN",	IDM_TABWIN},
+		{"IDM_SPLITVERTICAL",	IDM_SPLITVERTICAL},
+		{"IDM_VIEWSPACE",	IDM_VIEWSPACE},
+		{"IDM_VIEWEOL",	IDM_VIEWEOL},
+		{"IDM_VIEWGUIDES",	IDM_VIEWGUIDES},
+		{"IDM_SELMARGIN",	IDM_SELMARGIN},
+		{"IDM_FOLDMARGIN",	IDM_FOLDMARGIN},
+		{"IDM_LINENUMBERMARGIN",	IDM_LINENUMBERMARGIN},
+		{"IDM_VIEWTOOLBAR",	IDM_VIEWTOOLBAR},
+		{"IDM_TOGGLEOUTPUT",	IDM_TOGGLEOUTPUT},
+		{"IDM_VIEWTABBAR",	IDM_VIEWTABBAR},
+		{"IDM_VIEWSTATUSBAR",	IDM_VIEWSTATUSBAR},
+		{"IDM_TOGGLEPARAMETERS",	IDM_TOGGLEPARAMETERS},
+		{"IDM_OPENFILESHERE",	IDM_OPENFILESHERE},
+		{"IDM_WRAP",	IDM_WRAP},
+		{"IDM_WRAPOUTPUT",	IDM_WRAPOUTPUT},
+		{"IDM_READONLY",	IDM_READONLY},
+		{"IDM_CLEAROUTPUT",	IDM_CLEAROUTPUT},
+		{"IDM_SWITCHPANE",	IDM_SWITCHPANE},
+		{"IDM_EOL_CRLF",	IDM_EOL_CRLF},
+		{"IDM_EOL_CR",	IDM_EOL_CR},
+		{"IDM_EOL_LF",	IDM_EOL_LF},
+		{"IDM_EOL_CONVERT",	IDM_EOL_CONVERT},
+		{"IDM_TABSIZE",	IDM_TABSIZE},
+		{"IDM_MONOFONT",	IDM_MONOFONT},
+		{"IDM_OPENLOCALPROPERTIES",	IDM_OPENLOCALPROPERTIES},
+		{"IDM_OPENUSERPROPERTIES",	IDM_OPENUSERPROPERTIES},
+		{"IDM_OPENGLOBALPROPERTIES",	IDM_OPENGLOBALPROPERTIES},
+		{"IDM_OPENABBREVPROPERTIES",	IDM_OPENABBREVPROPERTIES},
+		{"IDM_OPENLUAEXTERNALFILE",	IDM_OPENLUAEXTERNALFILE},
+		{"IDM_PREVFILE",	IDM_PREVFILE},
+		{"IDM_NEXTFILE",	IDM_NEXTFILE},
+		{"IDM_CLOSEALL",	IDM_CLOSEALL},
+		{"IDM_SAVEALL",	IDM_SAVEALL},
+		{"IDM_BUFFERSEP",	IDM_BUFFERSEP},
+		{"IDM_HELP",	IDM_HELP},
+		{"IDM_ABOUT",	IDM_ABOUT},
+		{"IDM_HELP_SCITE",	IDM_HELP_SCITE},
+		{"IDM_ONTOP",	IDM_ONTOP},
+		{"IDM_FULLSCREEN",	IDM_FULLSCREEN},
+
+//--Autogenerated -- end of automatically generated section
+		{0, 0},
+	};
+
+	for (int i=0; idmTable[i].id; i++) {
+		if (commandName == idmTable[i].name) {
+			return idmTable[i].id;
+		}
+	}
+	// Otherwise we might have entered a number as command to access a "SCI_" command
+	return commandName.value();
+}
diff -u -r -N scite-1.62-clean/scite/src/renpy.properties scite-1.62/scite/src/renpy.properties
--- scite-1.62-clean/scite/src/renpy.properties	1969-12-31 19:00:00.000000000 -0500
+++ scite-1.62/scite/src/renpy.properties	2005-03-17 23:29:29.102226553 -0500
@@ -0,0 +1,74 @@
+# Define SciTE settings for Python files.
+
+filter.renpy=RenPy (rpy)|*.rpy|
+
+file.patterns.renpy=*.rpy
+
+# lexer.*.rpy=renpy
+lexer.$(file.patterns.renpy)=renpy
+
+keywordclass.renpy=and assert break class continue def del elif \
+else except exec finally for from global if import in is lambda None \
+not or pass print raise return try while yield
+
+keywords.$(file.patterns.renpy)=$(keywordclass.renpy)
+
+statement.indent.*.renpy=10 :
+statement.end.*.renpy=
+statement.lookback.*.renpy=0
+block.start.*.renpy=
+block.end.*.renpy=
+
+tab.timmy.whinge.level=1
+
+#fold.comment.renpy=1
+fold.quotes.renpy=1
+
+comment.block.python=#~
+
+# Python styles
+# White space
+style.renpy.0=fore:#808080
+# Comment
+style.renpy.1=fore:#007F00,$(font.comment)
+# Number
+style.renpy.2=fore:#007F7F
+# String
+style.renpy.3=fore:#7F007F,$(font.monospace)
+# Single quoted string
+style.renpy.4=fore:#7F007F,$(font.monospace)
+# Keyword
+style.renpy.5=fore:#00007F,bold
+# Triple quotes
+style.renpy.6=fore:#7F0000
+# Triple double quotes
+style.renpy.7=fore:#7F0000
+# Class name definition
+style.renpy.8=fore:#0000FF,bold
+# Function or method name definition
+style.renpy.9=fore:#007F7F,bold
+# Operators
+style.renpy.10=bold
+# Identifiers
+style.renpy.11=
+# Comment-blocks
+style.renpy.12=fore:#7F7F7F
+# End of line where string is not closed
+style.renpy.13=fore:#000000,$(font.monospace),back:#E0C0E0,eolfilled
+# Matched Operators
+style.renpy.34=fore:#0000FF,bold
+style.renpy.35=fore:#FF0000,bold
+# Braces are only matched in operator style
+braces.renpy.style=10
+
+# if PLAT_WIN
+#	command.go.*.py=pythonw -u "$(FileNameExt)"
+#	command.go.subsystem.*.py=1
+#	command.go.*.pyw=pythonw -u "$(FileNameExt)"
+#	command.go.subsystem.*.pyw=1
+
+# if PLAT_GTK
+#	command.go.*.py=python -u $(FileNameExt)
+
+# command.name.1.*.py=Syntax Check
+# command.1.*.py=python -c "import py_compile; py_compile.compile(r'$(FilePath)')"
diff -u -r -N scite-1.62-clean/scite/src/renpy.properties~ scite-1.62/scite/src/renpy.properties~
--- scite-1.62-clean/scite/src/renpy.properties~	1969-12-31 19:00:00.000000000 -0500
+++ scite-1.62/scite/src/renpy.properties~	2005-03-17 23:17:31.067467924 -0500
@@ -0,0 +1,73 @@
+# Define SciTE settings for Python files.
+
+filter.python=Python (py pyw)|*.py;*.pyw|
+
+file.patterns.py=*.py;*.pyw
+
+lexer.$(file.patterns.py)=python
+
+keywordclass.python=and assert break class continue def del elif \
+else except exec finally for from global if import in is lambda None \
+not or pass print raise return try while yield
+
+keywords.$(file.patterns.py)=$(keywordclass.python)
+
+statement.indent.*.py=10 :
+statement.end.*.py=
+statement.lookback.*.py=0
+block.start.*.py=
+block.end.*.py=
+
+tab.timmy.whinge.level=1
+
+#fold.comment.python=1
+#fold.quotes.python=1
+
+comment.block.python=#~
+
+# Python styles
+# White space
+style.python.0=fore:#808080
+# Comment
+style.python.1=fore:#007F00,$(font.comment)
+# Number
+style.python.2=fore:#007F7F
+# String
+style.python.3=fore:#7F007F,$(font.monospace)
+# Single quoted string
+style.python.4=fore:#7F007F,$(font.monospace)
+# Keyword
+style.python.5=fore:#00007F,bold
+# Triple quotes
+style.python.6=fore:#7F0000
+# Triple double quotes
+style.python.7=fore:#7F0000
+# Class name definition
+style.python.8=fore:#0000FF,bold
+# Function or method name definition
+style.python.9=fore:#007F7F,bold
+# Operators
+style.python.10=bold
+# Identifiers
+style.python.11=
+# Comment-blocks
+style.python.12=fore:#7F7F7F
+# End of line where string is not closed
+style.python.13=fore:#000000,$(font.monospace),back:#E0C0E0,eolfilled
+# Matched Operators
+style.python.34=fore:#0000FF,bold
+style.python.35=fore:#FF0000,bold
+# Braces are only matched in operator style
+braces.python.style=10
+
+if PLAT_WIN
+	command.go.*.py=pythonw -u "$(FileNameExt)"
+	command.go.subsystem.*.py=1
+	command.go.*.pyw=pythonw -u "$(FileNameExt)"
+	command.go.subsystem.*.pyw=1
+
+if PLAT_GTK
+	command.go.*.py=python -u $(FileNameExt)
+
+command.name.1.*.py=Syntax Check
+command.1.*.py=python -c "import py_compile; py_compile.compile(r'$(FilePath)')"
diff -u -r -N scite-1.62-clean/scite/src/script.rpy scite-1.62/scite/src/script.rpy
--- scite-1.62-clean/scite/src/script.rpy	1969-12-31 19:00:00.000000000 -0500
+++ scite-1.62/scite/src/script.rpy	2005-03-17 23:20:48.913835375 -0500
@@ -0,0 +1,1014 @@
+# This script, but not the artwork associated with it, is in the
+# public domain. Feel free to use it as the basis for your own
+# game.
+
+# If you're trying to understand this script, I recommend skipping
+# down to the line beginning with 'label start:', at least on your
+# first read-through.
+
+# This init block runs first, and sets up all sorts of things that
+# are used by the rest of the game. Variables that are set in init
+# blocks are _not_ saved, unless they are changed later on in the
+# program.
+
+init:
+
+    # Set up the size of the screen, and the window title.
+    $ config.screen_width = 800
+    $ config.screen_height = 600
+    $ config.window_title = "The Ren'Py Demo Game"
+
+    # Change some styles, to add images in the background of
+    # the menus and windows.
+    $ style.mm_root_window.background = Image("mainmenu.jpg")
+    $ style.gm_root_window.background = Image("gamemenu.jpg")
+    $ style.window.background = Frame("frame.png", 125, 25)
+
+    # Interface sounds, just for the heck of it.
+    $ style.button.activate_sound = 'click.wav'
+    $ style.imagemap.activate_sound = 'click.wav'
+    $ library.enter_sound = 'click.wav'
+    $ library.exit_sound = 'click.wav'
+
+    # These are positions that can be used inside at clauses. We set
+    # them up here so that they can be used throughout the program.
+    $ left = Position(xpos=0.0, xanchor='left')
+    $ right = Position(xpos=1.0, xanchor='right')
+    $ center = Position()
+
+    # Likewise, we set up some transitions that we can use in with
+    # clauses and statements.
+    $ fade = Fade(.5, 0, .5) # Fade to black and back.
+    $ dissolve = Dissolve(0.5)
+    
+    $ wiperight = CropMove(1.0, "wiperight")
+    $ wipeleft = CropMove(1.0, "wipeleft")
+    $ wipeup = CropMove(1.0, "wipeup")
+    $ wipedown = CropMove(1.0, "wipedown")
+
+    $ slideright = CropMove(1.0, "slideright")
+    $ slideleft = CropMove(1.0, "slideleft")
+    $ slideup = CropMove(1.0, "slideup")
+    $ slidedown = CropMove(1.0, "slidedown")
+
+    $ slideawayright = CropMove(1.0, "slideawayright")
+    $ slideawayleft = CropMove(1.0, "slideawayleft")
+    $ slideawayup = CropMove(1.0, "slideawayup")
+    $ slideawaydown = CropMove(1.0, "slideawaydown")
+
+    $ irisout = CropMove(1.0, "irisout")
+    $ irisin = CropMove(1.0, "irisin")
+
+    # Select the transitions that are used when entering and exiting
+    # the game menu.
+    $ library.enter_transition = dissolve
+    $ library.exit_transition = dissolve
+
+    # Now, we declare the images that are used in the program.
+
+    # Backgrounds.
+    image carillon = Image("carillon.jpg")
+    image whitehouse = Image("whitehouse.jpg")
+    image washington = Image("washington.jpg")
+    image black = Solid((0, 0, 0, 255))
+
+    # Character pictures.
+    image eileen happy = Image("9a_happy.png")
+    image eileen vhappy = Image("9a_vhappy.png")
+    image eileen concerned = Image("9a_concerned.png")
+
+    # Finally, the character object. This object lets us have the
+    # character say dialogue without us having to repeatedly type
+    # her name. It also lets us change the color of her name.
+    
+    # Character objects.
+    $ e = Character('Eileen', color=(200, 255, 200, 255))
+
+# The splashscreen is called, if it exists, before the main menu is
+# shown the first time. It is not called if the game has restarted.
+
+# We'll comment it out for now.
+#
+# label splashscreen:
+#     scene black
+#     show text "American Bishoujo Presents..." with fade
+#     $ renpy.pause(1.0)
+#     hide text with fade
+#
+#     return
+
+# The start label marks the place where the main menu jumps to to
+# begin the actual game.
+
+label start:
+
+    # The save_name variable sets the name of the save game. Like all
+    # variables declared outside of init blocks, this variable is
+    # saved and restored with a save file.
+    $ save_name = "Introduction"
+
+    # This variable is only used by our game. If it's true, it means
+    # that we won the date.
+    $ date = False
+
+    # Clear the game runtime timer, so it doesn't reflect time spent
+    # sitting at the main menu.
+    $ renpy.clear_game_runtime()
+
+    # Start some music playing in the background.
+    $ renpy.music_start('sun-flower-slow-drag.mid')
+
+    # Now, set up the first scene. We first fade in our washington
+    # background, and then we dissolve in the image of Eileen on top
+    # of it.
+    scene washington with fade
+    show eileen vhappy with dissolve
+
+    # Store the current version of Ren'Py into a variable, so we can
+    # interpolate it into the next line.
+    $ version = renpy.version()
+
+    # Display a line of dialogue. In this case, we manually specify
+    # who's saying the line of dialogue. We also interpolate in the
+    # version of Ren'Py we're using.
+    "Girl" "Hi, and welcome to the %(version)s demo program."
+
+    # This instantly replaces the very happy picture of Eileen with
+    # one showing her merely happy. It demonstrates how the show
+    # statement lets characters change emotions.
+    show eileen happy
+
+    # Another line of dialogue.
+    "Girl" "My name is Eileen, and while I plan to one day star in a
+            real game, for now I'm here to tell you about Ren'Py."
+
+    # This line used the e character object, which displays Eileen's
+    # name in green. The use of a short name for a character object
+    # lets us save typing when writing the bulk of the dialogue.
+    e "Ren'Py is a language and engine for writing and playing visual
+       novel games."
+
+    e "Our goal is to allow people to be able to write the script for
+       a game, and with very little effort, turn that script into
+       a working game."
+
+    e "I can tell you about the features of Ren'Py games, or how to write
+       your own game. What do you want to know about?"
+
+    # This variable is used to save the choices that have been made in
+    # the main menu.
+    $ seen_set = [ ]
+
+label choices:
+
+    # We change the save name here.
+    $ save_name = "Question Menu"
+
+    # This is the main menu, that lets the user decide what he wants
+    # to hear about.
+    menu:
+
+        # The set menu clause ensures that each menu choice can only
+        # be chosen once.
+        set seen_set
+
+        # This is a menu choice. When chosen, the statements in its
+        # block are executed.
+        "What are some features of Ren'Py games?":
+
+            # We call the features label. The from clause needs to be
+            # here to ensure that save games work, even after we
+            # change the script. It was added automatically.
+            call features from _call_features_1
+
+            # When we're done talking about features, jump back up
+            # to choices.
+            jump choices
+
+        # Another choice. 
+        "How do I write my own games with it?":
+            call writing from _call_writing_1
+            jump choices
+
+        "What's new with Ren'Py?":
+            call whatsnew from _call_whatsnew_1
+            jump choices
+
+        # This choice has a condition associated with it. It is only
+        # displayed if the condition is true (in this case, if we have
+        # selected at least one other choice has been chosen.) 
+        "Where can I find out more?" if seen_set:
+            call find_out_more from _call_find_out_more_1
+            jump choices
+
+        "Why are we in Washington, DC?":
+            call washington from _call_washington_1
+            jump choices
+
+        "I think I've heard enough." if seen_set:
+            jump ending
+
+
+# This is the section on writing games.
+label writing:
+
+    # Change the title of the save games.
+    $ save_name = "Writing Games"
+
+    # We start off with a bunch of dialogue.
+    e "If you want to write a game, I recommend that you read the
+       Ren'Py tutorial, which you can get from our web page,
+       http://www.bishoujo.us/renpy/."
+
+    e "But here, we'll go over some of the basics of writing Ren'Py
+       scripts. It might make sense if you open the source for this
+       game."
+
+    e "The source for this game can be found in the file
+       game/script.rpy."
+
+    e "The goal of Ren'Py is to make writing the game similar to
+       typing up the script on the computer."
+
+    e "For example, a line of dialogue is expressed by putting the
+       character's name next to the dialogue string."
+
+    # A string by itself like this displays without a name associated
+    # with it. So it's useful for dialogue and narration.
+    "I somehow remember that strings by themselves are displayed as
+     thoughts or narration."
+    
+    e "The menu statement makes it easy to create menus."
+
+    e "A number of statements let you control what is shown on the
+       screen."
+
+    # This scene statement has a with clause associated with it. In
+    # this case (based on what is defined in the init clause at the
+    # top of this script), it causes a fade to black, and then back
+    # to the new scene.
+    scene whitehouse with fade
+
+    e "The scene statement clears the scene list, which is the list of
+       things that are shown on the screen."
+
+    # This shows an image, and dissolves it in.
+    show eileen happy with dissolve
+
+    e "The show statement shows another image on the screen."
+
+    # The at clause here, displays the character on the left side of
+    # the screen.
+    show eileen happy at left with dissolve
+
+    e "Images can take at clauses that specify where on the screen
+       they are shown."
+
+    show eileen vhappy at left
+
+    e "Showing a new image with the same first part of the name
+       replaces the image in the scene list."
+
+    hide eileen with dissolve
+
+    e "Finally, the hide statement hides an image, which is useful
+       when a character leaves the scene."
+
+    show eileen happy with dissolve
+
+    e "Don't worry, I'm not going anywhere."
+
+    e "The with statement is used to cause transitions to
+       happen. Transitions like fade..."
+
+    # This statement hides the transient stuff from being included
+    # in the next fade.
+    with None
+
+    # This with statement causes things to fade without changing the
+    # scene.
+    with fade
+
+    e "... or dissolve ..."
+
+    # In this block, the scene statement clears the scene list. So we
+    # have to reshow the eileen happy image, so that it appears that
+    # just the background is dissolving. Sneaky.
+    with None
+    scene washington
+    show eileen happy
+    with dissolve
+
+    e "... are easily invoked."
+
+    e "As of version 4.2, Ren'Py supports image maps, which are like
+       another form of menu. Let's try one."
+
+    # This is an imagemap. It consists of two images, and a list of
+    # hotspots. For each hotspot we give the coordinates of the left,
+    # top, right, and bottom sides, and the value to return if it is
+    # picked.
+
+    $ result = renpy.imagemap("ground.png", "selected.png", [
+        (100, 100, 300, 400, "eileen"),
+        (500, 100, 700, 400, "lucy")
+        ])
+
+    # We've assigned the chosen result from the imagemap to the
+    # result variable. We can use an if statement to vary what
+    # happens based on the user's choice.
+
+    if result == "eileen":
+        show eileen vhappy
+        e "You picked me!"
+
+    elif result == "lucy":
+        show eileen concerned
+        e "It looks like you picked Lucy."
+
+        # Eileen is being a bit possesive here. :-P
+        if date:
+            e "You can forget about Saturday."
+            $ date = False
+
+    show eileen happy
+
+    e "Ren'Py supports music, such as what's playing in the
+       background..."
+
+    # This plays a sound effect.
+    $ renpy.play("18005551212.wav")
+    
+    e "... and sound effects, like the one that just played."
+
+    e "We now provide a series of user-interface functions, that allow
+       the programmer to create fairly complex interfaces."
+
+    e "For example, try the following scheduling and stats screen,
+       which could be used by a stat-based dating simulation."
+
+    $ day_planner()
+    
+    e "Ren'Py also includes a number of control statements, and even
+       lets you include python code."
+
+    e "Rather than go into this here, you can read all about it in the
+       tutorial."
+
+    e "If you want to make changes, you can edit the script for this
+       game by editing game/script.rpy"
+
+    e "When you've made a change, just re-run the game to see your
+       change in action."
+
+    e "Would you like to know about something else?"
+
+    # We return back up to the menu that lets the user pick a topic.
+    return
+
+# This ends the well-commented portion of this script.
+
+label features:
+
+    $ save_name = "Features"
+
+    e "By providing a range of useful features, we let game authors
+       focus on writing their games."
+
+    e "What are some of these features? Well, first of all, we take
+       care of displaying the screen, as well as dialogue and menus."
+
+    e "You can navigate through the game using the keyboard or the
+       mouse. If you've gotten this far, you've probably figured that
+       out already."
+
+    e "If you press 'f', you can toggle fullscreen mode. Pressing 'm'
+       will toggle music on and off."
+
+    e "Right-clicking or pressing escape will bring you to the game
+       menu."
+
+    e "The game menu lets you save or load the game. Ren'Py doesn't
+       limit the number of save slots available. You can create as
+       many slots as you can stand."
+
+    e "The game menu also lets you restart or quit the game. But you
+       wouldn't want to do that, would you?"
+
+    e "Finally, the game menu lets you set up the game
+       preferences. These preferences are saved between games."
+
+    show eileen vhappy
+
+    e "The next feature is really neat."
+
+    show eileen happy
+
+    menu rollback_menu:
+        "Would you like to hear about rollback?"
+        
+        "Yes.":
+            pass
+
+        "No.":
+            jump after_rollback
+
+
+    e "Rollback is a feature that only Ren'Py has. It lets you go back
+       in time in a game."
+
+    e "For example, you can go back to a menu and save or make a
+       different choice."
+
+    e "You can access it by pressing page up or scrolling up on your
+       mouse wheel."
+
+    e "Why don't you try it by going back to the last menu and
+       choosing 'No.' instead of 'Yes.'"
+
+    e "Press page up or scroll up the mouse wheel."
+
+    show eileen concerned
+
+    e "Well, are you going to try it?"
+
+    e "Your loss."
+
+    e "Moving on."
+
+label after_rollback:
+
+    show eileen happy
+    
+    e "Ren'Py gives you a few ways of skipping dialogue. Pressing
+       control quickly skips dialogue you've seen at least once."
+
+    e "Pressing Tab toggles the skipping of dialogue you've seen at
+       least once."
+
+    e "Pressing page down or scrolling the mouse wheel down will let
+       you skip dialogue you've seen this session. This is useful
+       after a rollback."
+
+    e "If you want to try these, you might want to rollback a bit
+       first, so you can skip over something you've seen already."
+
+    e "Finally, Ren'Py has predictive image loading, so you rarely
+       have to wait for a new image to load."
+
+    e "Remember, all these features are built into the engine or
+       standard library. So every game written with Ren'Py has them."
+
+    e "Is there anything else you'd like to know about?"
+    
+    return
+
+
+label find_out_more:
+
+    $ save_name = "Find Out More"
+
+    e "There are a few places you can go to find out more about
+       Ren'Py."
+
+    e "The Ren'Py homepage, http://www.bishoujo.us/renpy/, is probably
+       the best place to start."
+
+    e "There, you can download new versions of Ren'Py, and read the
+       tutorial online."
+
+    e "If you have questions, the best place to ask them is the Ren'Py
+       forum of the Lemmasoft forums."
+
+    e "Just go to http://lemmasoft.renai.us/forums/, and click on
+       Ren'Py."
+
+    e "We thank Blue Lemma for hosting our forum."
+
+    e "Finally, feel free to email or IM us if you need help. You can
+       get the addresses to use from http://www.bishoujo.us/renpy/."
+
+    e "We really want people to make their own games with Ren'Py, and
+       if there's anything we can do to help, just tell us."
+
+    e "Is there anything I can help you with now?"
+
+    return
+
+label washington:
+
+    $ save_name = "Washington, DC"
+
+    e "We're in Washington, DC because over Summer 2004 American
+       Bishoujo's home base was just outside of DC."
+
+    scene whitehouse
+    show eileen happy at left
+    with fade
+
+    e "Even though we've moved back to New York, we took a bunch of
+       pictures, and decided to use them."
+
+    show eileen concerned at left
+
+    e "It was easier than drawing new pictures for this demo."
+
+    show eileen happy at left
+    
+    e "Do you have a favorite landmark in or around DC?"
+
+    menu:
+
+        "The White House.":
+
+            e "I was supposed to go on a tour of the West Wing, once."
+
+            show eileen concerned
+
+            e "They wouldn't let us in."
+
+            e "The secret service guy who was supposed to show us
+               around was out of town that day."
+
+            e "Too bad."
+
+        "The National Mall.":
+
+            e "It's always fun to go down to the national mall."
+
+            e "You can visit the monuments, or see one of the
+               museums."
+
+            e "I guess you could run out of things to do after a while
+               but I didn't over the course of a summer."
+            
+        "The Netherlands Carillon.":
+            jump netherlands
+            
+    jump post_netherlands
+
+label netherlands:
+
+    show eileen vhappy at left
+
+    e "You've been to the Netherlands Carillon?"
+
+    scene carillon
+    show eileen vhappy at left
+    with dissolve
+
+    e "It may not be much to look at but the sound of the bells is
+       really neat."
+
+    e "I love going there. Saturdays during the summer, they have
+       these recitals in the park where a guy comes and plays the 
+       bells live."
+
+    e "You can climb to the top and talk to him, if you're not afraid
+       of heights."
+
+    e "Once, I saw a little girl there, maybe three or four years old.
+       The guy played the bumblebee song for here, and he even let her play the last
+       note. It was so cute!"
+
+    e "I haven't been there for so long."
+
+    menu:
+        "Would you like to go there sometime?":
+
+            e "You mean, together?"
+
+            e "Sure, why not. How does next Saturday sound?"
+            
+            e "It's a date."
+
+            $ date = True
+
+        "That sounds nice.":
+
+            show eileen happy at left
+
+            e "Well, it is."
+        
+label post_netherlands:
+
+    scene washington
+    show eileen happy
+    with fade
+
+    e "Anyway, is there anything else you want to know about Ren'Py?"
+
+    return
+
+label ending:
+
+    $ save_name = "Ending"
+
+    e "Well, that's okay."
+
+    e "I hope you'll consider using Ren'Py for your next game
+       project."
+
+    show eileen vhappy
+
+    e "Thanks for viewing this demo!"
+
+    if date:
+        e "And I'll see you on Saturday."
+    
+    scene black with fade
+
+    "Ren'Py and the Ren'Py demo were written by PyTom."
+
+    'The background music is "Sun Flower Slow Drag" by S. Joplin
+     (1868-1917). Thanks to the Mutopia project for making it
+       available.'
+
+    'The author would like to thank everyone who makes original
+     English-language bishoujo games, and the people on the Lemmasoft forums
+     who encouraged him.'
+
+    "We can't wait to see what you do with this. Good luck!"
+
+    $ minutes, seconds = divmod(int(renpy.get_game_runtime()), 60)
+    "It took you %(minutes)d minutes and %(seconds)d seconds to
+     finish this demo."
+       
+    $ renpy.full_restart()
+
+
+label speedtest:
+
+    with None
+    scene whitehouse
+    show eileen happy
+    with dissolve
+
+    e "Okay, I'm going to run the speedtest on your system."
+
+    e "I'll only be testing the performance of the dissolve
+       transition. It taxes your system the most, as it needs to
+       redraw the entire screen each frame."
+
+    $ frames = config.frames
+
+    with None
+    scene washington
+    show eileen happy
+    with Dissolve(5.0)
+
+    $ frames = config.frames - frames
+    $ fps = frames / 5.0
+
+    e "Well, your system displayed %(frames)d frames in five
+       seconds. That's %(fps).1f fps."
+
+    e "Remember, this is the worst-case speed, as usually we can just
+       draw the parts of the screen that have changed."
+
+    e "Thanks for viewing the secret speed test."
+
+    return
+    
+# Setup the secret key for the speedtest.
+init:
+    python:
+        config.keymap['speedtest'] = [ 'S' ]
+        config.underlay.append(renpy.Keymap(speedtest=renpy.curried_call_in_new_context('speedtest')))
+
+
+init:
+
+    # This is just some example code to show the ui functions in
+    # action. You probably want to delete this (and the call to
+    # day_planner above) from your game. This code isn't really all
+    # that useful except as an example.
+    
+    python:
+        def day_planner():
+
+            periods = [ 'Morning', 'Afternoon', 'Evening' ]
+            choices = [ 'Study', 'Exercise',
+                        'Eat', 'Drink', 'Be Merry' ]
+
+            plan = { 'Morning' : 'Eat',
+                     'Afternoon' : 'Drink',
+                     'Evening' : 'Be Merry' }
+
+            day = 'March 25th'
+
+            stats = [
+                ('Strength', 100, 10),
+                ('Intelligence', 100, 25),
+                ('Moxie', 100, 100),
+                ('Chutzpah', 100, 75),
+                ]
+
+            editing = None
+
+            def button(text, selected, returns, **properties):
+                style = 'button'
+                style_text = 'button_text'
+
+                if selected:
+                    style='selected_button'
+                    style_text='selected_button_text'
+
+                ui.button(clicked=ui.returns(returns),
+                          style=style, **properties)
+                ui.text(text, style=style_text)
+
+
+            while True:
+
+                # Stats Window
+                ui.window(xpos=0,
+                          ypos=0,
+                          xanchor='left',
+                          yanchor='top',
+                          xfill=True,
+                          yminimum=200,
+                          )
+
+                ui.vbox()
+
+                ui.text('Statistics')
+                ui.null(height=20)
+
+
+                for name, range, value in stats:
+
+                    ui.hbox()
+                    ui.text(name, minwidth=150)
+                    ui.bar(600, 20, range, value, ypos=0.5, yanchor=center)
+                    ui.close()
+
+                ui.close()
+                
+                
+
+            
+                # Period Selection Window.
+                ui.window(xpos=0,
+                          ypos=200,
+                          xanchor='left',
+                          yanchor='top',
+                          xfill=False,
+                          xminimum=300
+                          )
+                
+                ui.vbox(xpos=0.5, xanchor='center')
+                ui.text(day, xpos=0.5, xanchor='center', textalign=0.5)
+                ui.null(height=20)
+                
+                for i in periods:
+                    face = i + ": " + plan[i]
+                    button(face, editing == i, ("edit", i))
+
+                ui.null(height=20)
+                ui.textbutton("Continue", clicked=ui.returns(("done", True)))
+                ui.null(height=20)
+                ui.close()
+
+
+                # Choice window.
+                if editing:
+                    ui.window(xpos=300,
+                              ypos=200,
+                              xanchor='left',
+                              yanchor='top',
+                              xfill=False,
+                              xminimum=500
+                              )
+                
+                    ui.vbox()
+                    ui.text("What will you do in the %s?" % editing.lower())
+                    ui.null(height=20)
+
+                    for i in choices:
+                        button(i, plan[editing] == i, ("set", i),
+                               xpos=0, xanchor='left')
+
+                    ui.close()
+
+                # Window at the bottom.
+                ui.window()
+                ui.vbox()
+                ui.text("To get to the next screen, click the 'Continue' button.")
+                ui.close()
+                
+                type, value = ui.interact()
+
+                if type == "done":
+                    break
+
+                if type == "edit":
+                    editing = value
+
+                if type == "set":
+                    plan[editing] = value
+                    editing = None
+
+            return plan
+
+init:
+    image movie = Movie()
+
+    python:
+        style.create('odd_window', 'say_window')
+        style.odd_window.left_margin = 50
+        style.odd_window.right_margin = 150
+        style.odd_window.bottom_margin = 25
+
+        eodd = Character('Eileen', color=(200, 255, 200, 255), window_style='odd_window')
+    
+
+label whatsnew:
+
+    show washington
+    show eileen happy
+
+    e "I can give you a demonstration of some of the new features in
+       Ren'Py, but you'll have to tell me what version you want to
+       start with."
+
+    menu:
+        "I'd like to start with 4.5.":
+            jump whatsnew45
+
+        "I'd like to start with 4.6.":
+            jump whatsnew46
+
+        "I'd like to start with 4.7.":
+            jump whatsnew47
+
+label whatsnew45:
+
+    show washington
+    show eileen happy
+
+    e "While most of the improvements in Ren'Py 4.5 were behind the scenes,
+       we can give you a demonstration of one of the new features."
+
+    e "There is now a new transition, CropMove, that can be used to
+       provide a whole range of transition effects."
+
+    hide eileen with dissolve
+
+    e "I'll stand offscreen, so you can see some of its modes. I'll read
+       out the mode name after each transiton."
+
+    scene whitehouse with wiperight
+
+    e "We first have wiperight..."
+
+    scene washington with wipeleft
+
+    e "...followed by wipeleft... "    
+
+    scene whitehouse with wipeup
+
+    e "...wipeup..."
+
+    scene washington with wipedown
+
+    e "...and wipedown."
+
+    e "Next, the slides."
+
+    scene whitehouse with slideright
+
+    e "Slideright..."
+
+    scene washington with slideleft
+
+    e "...slideleft..."
+
+    scene whitehouse with slideup
+
+    e "...slideup..."
+
+    scene washington with slidedown
+
+    e "and slidedown."
+
+    e "We also have a couple of transitions that use a rectangular iris."
+
+    scene whitehouse with irisout
+
+    e "There's irisout..."
+
+    with None
+    scene washington
+    show eileen happy
+    with irisin
+
+    e "... and irisin."
+
+    e "There are other transitions, such as various forms of
+       slideaway. And if you can't find the transition for you, you
+       can write a custom one."
+    
+    e "It's enough to make you feel a bit dizzy."
+
+    e "Ren'Py 4.5 also includes the ability to show MPEG-1 movies as
+       cutscenes or even backgrounds."
+
+label ike:
+
+    if renpy.exists('Eisenhow1952.mpg'):
+
+        e "Since you downloaded the Eisenhower commercial, I can show
+           it to you as a cutscene."
+
+        e "You can click to continue if it gets on your nerves too
+           much."
+
+        $ renpy.movie_cutscene('Eisenhow1952.mpg', 63.0)
+        
+        hide eileen
+        show movie at Position(xpos=420, ypos=25, xanchor='left', yanchor='top')
+        show eileen happy
+
+        $ renpy.movie_start_displayable('Eisenhow1952.mpg', (352, 240))
+
+        e "Ren'Py can even overlay rendered images on top of a movie,
+           although that's more taxing for your CPU."
+
+        e "It's like I'm some sort of newscaster or something."
+           
+        $ renpy.movie_stop()
+        hide movie
+
+    else:
+
+        e "You haven't downloaded the Eisenhower commercial, so we
+           can't demonstrate it."
+
+label whatsnew46:
+
+    eodd "As of 4.6, we now support separate padding and margin for the
+          left, right, top, and bottom sides of a window."
+
+    eodd "This means that a game can have oddly shaped windows without
+          having to go beyond the style system."
+
+    e "We also introduced a new layer system, and the ability to have
+       transitions affect only one layer."
+
+    e "Because of this we can do things like slide away a window..."
+
+    $ renpy.transition(slideawayup, 'transient')
+    $ renpy.pause(1.5)
+    $ renpy.transition(slidedown, 'transient')
+    
+    e "... and slide it back in again."
+
+    e "Also new in this release is the ability to specify transitions
+       that occur when you enter and exit the game menu."
+
+    e "Right click to see them, if you want."
+
+    e "A few more obscure features involving things like overlays and
+       activated widgets round out the 4.6 release."
+
+label whatsnew47:
+
+    e "Ren'Py 4.7 brought with it a total rewrite of the way text is
+       rendered to the screen."
+
+    e "It introduced text tags, which let a script writer control how
+       text is shown on the screen."
+
+    e "Text tags can make text {b}bold{/b}, {i}italic{/i}, or even
+       {u}underlined{/u}."
+
+    e "They can make the font size {size=+12}bigger{/size} or
+       {size=-8}smaller{/size}."
+
+    e "They can even change the
+       {color=#f00}color{/color}
+       {color=#ff0}of{/color}
+       {color=#0f0}the{/color}
+       {color=#0ff}text{/color}."
+
+    e "We also added bold, italic, and underline style properties, which can
+       be styled onto any text."
+
+    e "Used with care, text tags can enhance {b}your{/b} game."
+
+    e "{u}Used{/u} with {i}abandon,{/i} they {b}can{/b} make {b}your{/b}
+       game {color=#333}hard{/color} {color=#888}to{/color} {color=#ccc}read{/color}."
+
+    e "With great power comes great responsibility, after all."
+
+    e "And we want to give you all the power you need."
+
+label whatsnewend:
+
+    e "Anyway, now that you've heard about some of the new features, is there anything
+       else I can help you with?"
+
+    return
+
+
diff -u -r -N scite-1.62-clean/scite/win32/makefile scite-1.62/scite/win32/makefile
--- scite-1.62-clean/scite/win32/makefile	2004-07-26 08:23:26.000000000 -0400
+++ scite-1.62/scite/win32/makefile	2005-03-17 23:21:30.835954298 -0500
@@ -91,7 +91,8 @@
 ..\bin\pov.properties ..\bin\ps.properties ..\bin\python.properties \
 ..\bin\ruby.properties ..\bin\scriptol.properties ..\bin\specman.properties \
 ..\bin\sql.properties ..\bin\tcl.properties ..\bin\tex.properties \
-..\bin\vb.properties ..\bin\verilog.properties ..\bin\yaml.properties
+..\bin\vb.properties ..\bin\verilog.properties ..\bin\vhdl.properties \
+..\bin\yaml.properties ..\bin\renpy.properties
 #--Autogenerated -- end of automatically generated section
 
 PROPS=..\bin\SciTEGlobal.properties ..\bin\abbrev.properties $(LEXPROPS)
@@ -199,8 +200,12 @@
 	$(COPY) $^ $@
 ..\bin\verilog.properties:	..\src\verilog.properties
 	$(COPY) $^ $@
+..\bin\vhdl.properties:	..\src\vhdl.properties
+	$(COPY) $^ $@
 ..\bin\yaml.properties:	..\src\yaml.properties
 	$(COPY) $^ $@
+..\bin\renpy.properties:	..\src\renpy.properties
+	$(COPY) $^ $@
 
 #--Autogenerated -- end of automatically generated section
 
diff -u -r -N scite-1.62-clean/scite/win32/scite.mak scite-1.62/scite/win32/scite.mak
--- scite-1.62-clean/scite/win32/scite.mak	2004-10-15 19:41:28.000000000 -0400
+++ scite-1.62/scite/win32/scite.mak	2005-03-17 23:21:30.850950764 -0500
@@ -109,23 +109,23 @@
 #++Autogenerated -- run src/LexGen.py to regenerate
 #**LEXOBJS=\\\n\(\t..\\..\\scintilla\\win32\\\*.obj \\\n\)
 LEXOBJS=\
-	..\..\scintilla\win32\LexAda.obj \
 	..\..\scintilla\win32\LexAPDL.obj \
-	..\..\scintilla\win32\LexAsm.obj \
-	..\..\scintilla\win32\LexAsn1.obj \
 	..\..\scintilla\win32\LexAU3.obj \
 	..\..\scintilla\win32\LexAVE.obj \
+	..\..\scintilla\win32\LexAda.obj \
+	..\..\scintilla\win32\LexAsm.obj \
+	..\..\scintilla\win32\LexAsn1.obj \
 	..\..\scintilla\win32\LexBaan.obj \
 	..\..\scintilla\win32\LexBash.obj \
 	..\..\scintilla\win32\LexBullant.obj \
 	..\..\scintilla\win32\LexCLW.obj \
-	..\..\scintilla\win32\LexConf.obj \
 	..\..\scintilla\win32\LexCPP.obj \
-	..\..\scintilla\win32\LexCrontab.obj \
 	..\..\scintilla\win32\LexCSS.obj \
+	..\..\scintilla\win32\LexConf.obj \
+	..\..\scintilla\win32\LexCrontab.obj \
+	..\..\scintilla\win32\LexEScript.obj \
 	..\..\scintilla\win32\LexEiffel.obj \
 	..\..\scintilla\win32\LexErlang.obj \
-	..\..\scintilla\win32\LexEScript.obj \
 	..\..\scintilla\win32\LexForth.obj \
 	..\..\scintilla\win32\LexFortran.obj \
 	..\..\scintilla\win32\LexGui4Cli.obj \
@@ -134,28 +134,29 @@
 	..\..\scintilla\win32\LexLisp.obj \
 	..\..\scintilla\win32\LexLout.obj \
 	..\..\scintilla\win32\LexLua.obj \
-	..\..\scintilla\win32\LexMatlab.obj \
-	..\..\scintilla\win32\LexMetapost.obj \
 	..\..\scintilla\win32\LexMMIXAL.obj \
 	..\..\scintilla\win32\LexMPT.obj \
 	..\..\scintilla\win32\LexMSSQL.obj \
+	..\..\scintilla\win32\LexMatlab.obj \
+	..\..\scintilla\win32\LexMetapost.obj \
 	..\..\scintilla\win32\LexNsis.obj \
 	..\..\scintilla\win32\LexOthers.obj \
-	..\..\scintilla\win32\LexPascal.obj \
 	..\..\scintilla\win32\LexPB.obj \
-	..\..\scintilla\win32\LexPerl.obj \
 	..\..\scintilla\win32\LexPOV.obj \
 	..\..\scintilla\win32\LexPS.obj \
+	..\..\scintilla\win32\LexPascal.obj \
+	..\..\scintilla\win32\LexPerl.obj \
 	..\..\scintilla\win32\LexPython.obj \
 	..\..\scintilla\win32\LexRuby.obj \
+	..\..\scintilla\win32\LexSQL.obj \
 	..\..\scintilla\win32\LexScriptol.obj \
 	..\..\scintilla\win32\LexSpecman.obj \
-	..\..\scintilla\win32\LexSQL.obj \
 	..\..\scintilla\win32\LexTeX.obj \
 	..\..\scintilla\win32\LexVB.obj \
-	..\..\scintilla\win32\LexVerilog.obj \
 	..\..\scintilla\win32\LexVHDL.obj \
+	..\..\scintilla\win32\LexVerilog.obj \
 	..\..\scintilla\win32\LexYAML.obj \
+	..\..\scintilla\win32\LexRenpy.obj \
 
 #--Autogenerated -- end of automatically generated section
 
@@ -218,7 +219,8 @@
 $(DIR_BIN)\scriptol.properties $(DIR_BIN)\specman.properties \
 $(DIR_BIN)\sql.properties $(DIR_BIN)\tcl.properties $(DIR_BIN)\tex.properties \
 $(DIR_BIN)\vb.properties $(DIR_BIN)\verilog.properties \
-$(DIR_BIN)\yaml.properties
+$(DIR_BIN)\vhdl.properties $(DIR_BIN)\yaml.properties \
+$(DIR_BIN)\renpy.properties
 #--Autogenerated -- end of automatically generated section
 
 PROPS=$(DIR_BIN)\SciTEGlobal.properties $(DIR_BIN)\abbrev.properties $(LEXPROPS)
@@ -345,8 +347,12 @@
 	copy ..\src\vb.properties $@
 $(DIR_BIN)\verilog.properties:	..\src\verilog.properties
 	copy ..\src\verilog.properties $@
+$(DIR_BIN)\vhdl.properties:	..\src\vhdl.properties
+	copy ..\src\vhdl.properties $@
 $(DIR_BIN)\yaml.properties:	..\src\yaml.properties
 	copy ..\src\yaml.properties $@
+$(DIR_BIN)\renpy.properties:	..\src\renpy.properties
+	copy ..\src\renpy.properties $@
 
 #--Autogenerated -- end of automatically generated section
 
