/**
 * Code Syntax Highlighter for C++(Windows Platform).
 * Version 0.0.2
 * Copyright (C) 2006 Shin, YoungJin.
 * http://www.jiniya.net/lecture/techbox/test.html
 * 
 * This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General 
 * Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option) 
 * any later version.
 *
 * This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied 
 * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more 
 * details.
 *
 * You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to 
 * the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 
 */

dp.sh.Brushes.MultiLang = function()
{

	var datatypes = 
	'abstract bool break case catch char CHAR WCHAR class const ' +
	'const_cast continue default delete deprecated dllexport dllimport do ' +
	'double dynamic_cast else enum explicit extern false float for For friend ' +
	'goto GoTo if If inline int long Long LONG mutable naked namespace new noinline noreturn ' +
	'nothrow novtable on On operator private property protected public register ' +
	'reinterpret_cast return selectany short signed sizeof static ' +
	'static_cast struct switch template this then Then thread throw to To true try typedef ' +
	'typeid typename union unsigned using declaration, directive uuid ' +
	'virtual void volatile while typeof ' +
	'Pointer Short Object uint16 UInt16 uint32 UInt32 IntPtr LPTSTR LPCSTR LPCTSTR ' +
	'ULONG Cardinal as base by byte checked decimal delegate descending ' +
	'event finally fixed foreach procedure from group implicit in interface internal ' +
	'into is lock null object out override orderby params readonly ref sbyte ' +
	'sealed stackalloc string String select uint ulong unchecked unsafe ushort var ' +
	'package synchronized boolean implements import throws ' +
	'instanceof transient extends final strictfp native super ' +
	'debugger export function with NaN Infinity ' +
	'require sub Sub unless until use elsif BEGIN END ' +
	'and assert def del elif except exec global lambda ' +
	'not or pass print raise yield False True None ' +
	'then end begin rescue ensure module when undef next ' +
	'redo retry alias defined As Dim done End fi MsgBox Next Set ' +
        'BOOL char BYTE void UINT USHORT DWORD LONG Long CString ' +
        'BYTE ARRAY VARIANT_BOOL VARIANT _bstr_t size_t Boolean Byte Word String ' +
        'THandle array of Byte Pointer Short Object TObject uint16 UInt16 uint32 ' +
        'UInt32 IntPtr LPTSTR LPWSTR LPCSTR LPCTSTR LPVOID ULONG ULONG_PTR LONG_PTR Cardinal integer cardinal include import Function ByRef ByVal ' +
        'Exit Integer';

	if(undefined===window.CUSTOM_KEYWORDS){
		window.CUSTOM_KEYWORDS = [];
	}
	var datatypes = datatypes + CUSTOM_KEYWORDS;
	var keywords = 'XXX';

	this.regexList = [
		{ regex: dp.sh.RegexLib.SingleLineCComments,			css: 'comment' },			// one line comments
		{ regex: dp.sh.RegexLib.SingleLineVbComments,			css: 'comment' },			// one line comments
		{ regex: dp.sh.RegexLib.MultiLineCComments,			css: 'comment' },			// multiline comments
		{ regex: dp.sh.RegexLib.DoubleQuotedString,			css: 'string' },			// strings
		{ regex: dp.sh.RegexLib.SingleQuotedString,			css: 'string' },			// strings
		{ regex: new RegExp('#.* ', 'gm'),				css: 'keyword' },
		{ regex: new RegExp(this.GetKeywords(datatypes), 'gm'),		css: 'datatypes' },
		{ regex: new RegExp(this.GetKeywords(keywords), 'gm'),		css: 'keyword' }
		];

	this.CssClass = 'dp-multilang';
	this.Style =	'.dp-multilang .datatypes { color: #2E8B57; font-weight: bold; }';
}

dp.sh.Brushes.MultiLang.prototype	= new dp.sh.Highlighter();
dp.sh.Brushes.MultiLang.Aliases	= ['multilang', 'all'];

