1;(function() 2{ 3 // CommonJS 4 SyntaxHighlighter = SyntaxHighlighter || (typeof require !== 'undefined'? require('shCore').SyntaxHighlighter : null); 5 6 function Brush() 7 { 8 var keywords = 'AddHandler AddressOf AndAlso Alias And Ansi As Assembly Auto ' + 9 'Boolean ByRef Byte ByVal Call Case Catch CBool CByte CChar CDate ' + 10 'CDec CDbl Char CInt Class CLng CObj Const CShort CSng CStr CType ' + 11 'Date Decimal Declare Default Delegate Dim DirectCast Do Double Each ' + 12 'Else ElseIf End Enum Erase Error Event Exit False Finally For Friend ' + 13 'Function Get GetType GoSub GoTo Handles If Implements Imports In ' + 14 'Inherits Integer Interface Is Let Lib Like Long Loop Me Mod Module ' + 15 'MustInherit MustOverride MyBase MyClass Namespace New Next Not Nothing ' + 16 'NotInheritable NotOverridable Object On Option Optional Or OrElse ' + 17 'Overloads Overridable Overrides ParamArray Preserve Private Property ' + 18 'Protected Public RaiseEvent ReadOnly ReDim REM RemoveHandler Resume ' + 19 'Return Select Set Shadows Shared Short Single Static Step Stop String ' + 20 'Structure Sub SyncLock Then Throw To True Try TypeOf Unicode Until ' + 21 'Variant When While With WithEvents WriteOnly Xor'; 22 23 this.regexList = [ 24 { regex: /'.*$/gm, css: 'comments' }, // one line comments 25 { regex: SyntaxHighlighter.regexLib.doubleQuotedString, css: 'string' }, // strings 26 { regex: /^\s*#.*$/gm, css: 'preprocessor' }, // preprocessor tags like #region and #endregion 27 { regex: new RegExp(this.getKeywords(keywords), 'gm'), css: 'keyword' } // vb keyword 28 ]; 29 30 this.forHtmlScript(SyntaxHighlighter.regexLib.aspScriptTags); 31 }; 32 33 Brush.prototype = new SyntaxHighlighter.Highlighter(); 34 Brush.aliases = ['vb', 'vbnet']; 35 36 SyntaxHighlighter.brushes.Vb = Brush; 37 38 // CommonJS 39 typeof(exports) != 'undefined' ? exports.Brush = Brush : null; 40})(); 41