dp.sh.Brushes.Batch = function()
{
var builtins =
'append arp assoc at atmadm attrib auditusr break cacls cd chcp chdir chkdsk chkntfs cls ' + 
'cmd color comp compact convert copy cscript date debug defrag del diantz dir diskcomp diskcopy ' + 
'diskpart diskperf doskey edlin erase exe2bin exit expand extrac32 fc find ' +
'findstr forcedos format fsutil ftp ftype graftabl help hostname ipconfig ipsec6 ' +
'ipv6 ipxroute label lodctr logman logoff lpq lpr makecab md mem mkdir mode more mountvol ' +'move mrinfo msg nbtstat net net1 netsh netstat nlsfunc nslookup path pathping pentnt ' +'ping ping6 popd powercfg print prompt proxycfg pushd qappsrv qprocess qwinsta rasdial rcp ' +'rd recover reg regedit ren rename replace reset rexec rmdir route routemon rsh rsm runas ' +'rwinsta sc scardsvr setver sfc shadow shutdown smbinst sort subst ' +'tftp time title tracert tracert6 tree tscon tsdiscon tskill tsshutdn type unlodctr ver verifier ' +'verify vol w32tm xcopy';
 
    var keywords =  'DO ELSE FOR IN CALL CHOICE GOTO SHIFT PAUSE ERRORLEVEL ' +
      'IF NOT EXIST LFNFOR START SETLOCAL ENDLOCAL ECHO SET';

    this.regexList = [
 {regex: new RegExp('REM.*$', 'igm'), css: 'comment'},
 {regex: new RegExp('::.*$', 'gm'), css: 'comment'},
 {regex: dp.sh.RegexLib.DoubleQuotedString, css: 'string'},
 {regex: dp.sh.RegexLib.SingleQuotedString, css: 'string'},
 {regex: new RegExp('[()[\\]{}]', 'g'), css: 'delim'},
 {regex: new RegExp('%\\w+%', 'g'), css: 'vars'},
 {regex: new RegExp('%%\\w+', 'g'), css: 'vars'},
 {regex: new RegExp('\\w+=', 'g'), css: 'vars'},
 {regex: new RegExp('@\\w+', 'g'), css: 'keyword'},
 {regex: new RegExp(':\\w+', 'g'), css: 'keyword'},
 {regex: new RegExp('\\s/\\w+', 'g'), css: 'flag'},
 {regex: new RegExp(this.GetKeywords(builtins), 'igm'), css: 'builtin'},
 {regex: new RegExp(this.GetKeywords(keywords), 'igm'), css: 'keyword'}
 ];

    this.CssClass = 'dp-batch';

    this.Style =    '.dp-batch .builtin {color: #10c; font-weight: bold;}' +
                    '.dp-batch .comment {color: #484; font-style: italic;}' +
                    '.dp-batch .delim {font-weight: bold;}' +
                    '.dp-batch .flag {color: green;}' +
                    '.dp-batch .string {color: #44f;}' +
                    '.dp-batch .vars {color: #fa4;font-weight: bold;}';

}

dp.sh.Brushes.Batch.prototype = new dp.sh.Highlighter();
dp.sh.Brushes.Batch.Aliases = ['batch', 'dos'];