diff --git a/fhem/www/codemirror/fhem.js b/fhem/www/codemirror/fhem.js index 0975c2601..f78ee691c 100644 --- a/fhem/www/codemirror/fhem.js +++ b/fhem/www/codemirror/fhem.js @@ -1,3 +1 @@ -/* $Id$ */ - -CodeMirror.defineMode("fhem",function(){var e={"->":4,"++":4,"--":4,"**":4,"=~":4,"!~":4,"*":4,"/":4,"%":4,x:4,"+":4,"-":4,".":4,"<<":4,">>":4,"<":4,">":4,"<=":4,">=":4,lt:4,gt:4,le:4,ge:4,"==":4,"!=":4,"<=>":4,eq:4,ne:4,cmp:4,"~~":4,"&":4,"|":4,"^":4,"&&":4,"||":4,"//":4,"..":4,"...":4,"?":4,":":4,"=":4,"+=":4,"-=":4,"*=":4,",":4,"=>":4,"::":4,not:4,and:4,or:4,xor:4,BEGIN:[5,1],END:[5,1],PRINT:[5,1],PRINTF:[5,1],GETC:[5,1],READ:[5,1],READLINE:[5,1],DESTROY:[5,1],TIE:[5,1],TIEHANDLE:[5,1],UNTIE:[5,1],STDIN:5,STDIN_TOP:5,STDOUT:5,STDOUT_TOP:5,STDERR:5,STDERR_TOP:5,$ARG:5,$_:5,"@ARG":5,"@_":5,$LIST_SEPARATOR:5,'$"':5,$PROCESS_ID:5,$PID:5,$$:5,$REAL_GROUP_ID:5,$GID:5,"$(":5,$EFFECTIVE_GROUP_ID:5,$EGID:5,"$)":5,$PROGRAM_NAME:5,$0:5,$SUBSCRIPT_SEPARATOR:5,$SUBSEP:5,"$;":5,$REAL_USER_ID:5,$UID:5,"$<":5,$EFFECTIVE_USER_ID:5,$EUID:5,"$>":5,$a:5,$b:5,$COMPILING:5,"$^C":5,$DEBUGGING:5,"$^D":5,"${^ENCODING}":5,$ENV:5,"%ENV":5,$SYSTEM_FD_MAX:5,"$^F":5,"@F":5,"${^GLOBAL_PHASE}":5,"$^H":5,"%^H":5,"@INC":5,"%INC":5,$INPLACE_EDIT:5,"$^I":5,"$^M":5,$OSNAME:5,"$^O":5,"${^OPEN}":5,$PERLDB:5,"$^P":5,$SIG:5,"%SIG":5,$BASETIME:5,"$^T":5,"${^TAINT}":5,"${^UNICODE}":5,"${^UTF8CACHE}":5,"${^UTF8LOCALE}":5,$PERL_VERSION:5,"$^V":5,"${^WIN32_SLOPPY_STAT}":5,$EXECUTABLE_NAME:5,"$^X":5,$1:5,$MATCH:5,"$&":5,"${^MATCH}":5,$PREMATCH:5,"$`":5,"${^PREMATCH}":5,$POSTMATCH:5,"$'":5,"${^POSTMATCH}":5,$LAST_PAREN_MATCH:5,"$+":5,$LAST_SUBMATCH_RESULT:5,"$^N":5,"@LAST_MATCH_END":5,"@+":5,"%LAST_PAREN_MATCH":5,"%+":5,"@LAST_MATCH_START":5,"@-":5,"%LAST_MATCH_START":5,"%-":5,$LAST_REGEXP_CODE_RESULT:5,"$^R":5,"${^RE_DEBUG_FLAGS}":5,"${^RE_TRIE_MAXBUF}":5,$ARGV:5,"@ARGV":5,ARGV:5,ARGVOUT:5,$OUTPUT_FIELD_SEPARATOR:5,$OFS:5,"$,":5,$INPUT_LINE_NUMBER:5,$NR:5,"$.":5,$INPUT_RECORD_SEPARATOR:5,$RS:5,"$/":5,$OUTPUT_RECORD_SEPARATOR:5,$ORS:5,"$\\":5,$OUTPUT_AUTOFLUSH:5,"$|":5,$ACCUMULATOR:5,"$^A":5,$FORMAT_FORMFEED:5,"$^L":5,$FORMAT_PAGE_NUMBER:5,"$%":5,$FORMAT_LINES_LEFT:5,"$-":5,$FORMAT_LINE_BREAK_CHARACTERS:5,"$:":5,$FORMAT_LINES_PER_PAGE:5,"$=":5,$FORMAT_TOP_NAME:5,"$^":5,$FORMAT_NAME:5,"$~":5,"${^CHILD_ERROR_NATIVE}":5,$EXTENDED_OS_ERROR:5,"$^E":5,$EXCEPTIONS_BEING_CAUGHT:5,"$^S":5,$WARNING:5,"$^W":5,"${^WARNING_BITS}":5,$OS_ERROR:5,$ERRNO:5,"$!":5,"%OS_ERROR":5,"%ERRNO":5,"%!":5,$CHILD_ERROR:5,"$?":5,$EVAL_ERROR:5,"$@":5,$OFMT:5,"$#":5,"$*":5,$ARRAY_BASE:5,"$[":5,$OLD_PERL_VERSION:5,"$]":5,$_blockingcalls:5,$SELF:5,$cmd:5,$DEVICE:5,$device:5,$EVENT:5,$event:5,$EVENTS:5,$events:5,$number:5,$name:5,$TYPE:5,$STATE:5,$room:5,$group:5,$week:5,$hm:5,$md:5,$ymd:5,$twe:5,$TABLE:5,$TD:5,$TR:5,$TC:5,$TPL:5,$ATTRIBUTESFIRST:5,$SHOWNOSTATE:5,$SHOWNODEVICELINE:5,$SHOWNODEVICELINK:5,if:[1,1],elsif:[1,1],else:[1,1],while:[1,1],unless:[1,1],for:[1,1],foreach:[1,1],abs:1,accept:1,alarm:1,atan2:1,bind:1,binmode:1,bless:1,bootstrap:1,break:1,caller:1,chdir:1,chmod:1,chomp:1,chop:1,chown:1,chr:1,chroot:1,close:1,closedir:1,connect:1,continue:[1,1],cos:1,crypt:1,dbmclose:1,dbmopen:1,default:1,defined:1,delete:1,die:1,do:1,dump:1,each:1,endgrent:1,endhostent:1,endnetent:1,endprotoent:1,endpwent:1,endservent:1,eof:1,eval:1,exec:1,exists:1,exit:1,exp:1,fcntl:1,fileno:1,flock:1,fork:1,format:1,formline:1,getc:1,getgrent:1,getgrgid:1,getgrnam:1,gethostbyaddr:1,gethostbyname:1,gethostent:1,getlogin:1,getnetbyaddr:1,getnetbyname:1,getnetent:1,getpeername:1,getpgrp:1,getppid:1,getpriority:1,getprotobyname:1,getprotobynumber:1,getprotoent:1,getpwent:1,getpwnam:1,getpwuid:1,getservbyname:1,getservbyport:1,getservent:1,getsockname:1,getsockopt:1,given:1,glob:1,gmtime:1,goto:1,grep:1,hex:1,import:1,index:1,int:1,ioctl:1,join:1,keys:1,kill:1,last:1,lc:1,lcfirst:1,length:1,link:1,listen:1,local:2,localtime:1,lock:1,log:1,lstat:1,m:null,map:1,mkdir:1,msgctl:1,msgget:1,msgrcv:1,msgsnd:1,my:2,new:1,next:1,no:1,oct:1,open:1,opendir:1,ord:1,our:2,pack:1,package:1,pipe:1,pop:1,pos:1,print:1,printf:1,prototype:1,push:1,q:null,qq:null,qr:null,quotemeta:null,qw:null,qx:null,rand:1,read:1,readdir:1,readline:1,readlink:1,readpipe:1,recv:1,redo:1,ref:1,rename:1,require:1,reset:1,return:1,reverse:1,rewinddir:1,rindex:1,rmdir:1,s:null,say:1,scalar:1,seek:1,seekdir:1,select:1,semctl:1,semget:1,semop:1,send:1,setgrent:1,sethostent:1,setnetent:1,setpgrp:1,setpriority:1,setprotoent:1,setpwent:1,setservent:1,setsockopt:1,shift:1,shmctl:1,shmget:1,shmread:1,shmwrite:1,shutdown:1,sin:1,sleep:1,socket:1,socketpair:1,sort:1,splice:1,split:1,sprintf:1,sqrt:1,srand:1,stat:1,state:1,study:1,sub:1,substr:1,symlink:1,syscall:1,sysopen:1,sysread:1,sysseek:1,system:1,syswrite:1,tell:1,telldir:1,tie:1,tied:1,time:1,times:1,tr:null,truncate:1,uc:1,ucfirst:1,umask:1,undef:1,unlink:1,unpack:1,unshift:1,untie:1,use:1,utime:1,values:1,vec:1,wait:1,waitpid:1,wantarray:1,warn:1,when:1,write:1,define:2,defmod:2,attr:2,at:2,notify:2,set:2,ReadingsVal:1,OldReadingsVal:1,ReadingsNum:1,OldReadingsNum:1,ReadingsTimestamp:1,OldReadingsTimestamp:1,Value:1,fhem:1,IF:2,DOIF:2,DOELSE:2,DOELSEIF:2,y:null};keywords.foreach(function(t,r){e[r]=2});var t="string-2",r=/[goseximacplud]/;function i(e,t,r,i,n){return t.chain=null,t.style=null,t.tail=null,t.tokenize=function(e,t){for(var a,o=!1,_=0;a=e.next();){if(a===r[_]&&!o){void 0!==r[++_]?(t.chain=r[_],t.style=i,t.tail=n):n&&e.eatWhile(n),t.tokenize=s;break}o=!o&&"\\"==a}return i},t.tokenize(e,t)}function n(e,t,r){return t.tokenize=function(e,t){return e.string==r&&(t.tokenize=s),e.skipToEnd(),"string"},t.tokenize(e,t)}function s(s,a){if(s.eatSpace())return null;if(a.chain)return i(s,a,a.chain,a.style,a.tail);if(s.match(/^\-?[\d\.]/,!1)&&s.match(/^(\-?(\d*\.\d+(e[+-]?\d+)?|\d+\.\d*)|0x[\da-fA-F]+|0b[01]+|\d+(e[+-]?\d+)?)/))return"number";if(s.match(/^<<(?=\w)/))return s.eatWhile(/\w/),n(s,a,s.current().substr(2));if(s.sol()&&s.match(/^\=item(?!\w)/))return n(s,a,"=cut");var o=s.next();if('"'==o||"'"==o){if(s.prefix(3)=="<<"+o){var _=s.pos;s.eatWhile(/\w/);var l=s.current().substr(1);if(l&&s.eat(o))return n(s,a,l);s.pos=_}return i(s,a,[o],"string")}if("q"==o){var f=s.look(-2);if(!(f&&/\w/.test(f))){if("x"==(f=s.look(0))){if("("==(f=s.look(1)))return s.eatSuffix(2),i(s,a,[")"],t,r);if("["==f)return s.eatSuffix(2),i(s,a,["]"],t,r);if("{"==f)return s.eatSuffix(2),i(s,a,["}"],t,r);if("<"==f)return s.eatSuffix(2),i(s,a,[">"],t,r);if(/[\^'"!~\/]/.test(f))return s.eatSuffix(1),i(s,a,[s.eat(f)],t,r)}else if("q"==f){if("("==(f=s.look(1)))return s.eatSuffix(2),i(s,a,[")"],"string");if("["==f)return s.eatSuffix(2),i(s,a,["]"],"string");if("{"==f)return s.eatSuffix(2),i(s,a,["}"],"string");if("<"==f)return s.eatSuffix(2),i(s,a,[">"],"string");if(/[\^'"!~\/]/.test(f))return s.eatSuffix(1),i(s,a,[s.eat(f)],"string")}else if("w"==f){if("("==(f=s.look(1)))return s.eatSuffix(2),i(s,a,[")"],"bracket");if("["==f)return s.eatSuffix(2),i(s,a,["]"],"bracket");if("{"==f)return s.eatSuffix(2),i(s,a,["}"],"bracket");if("<"==f)return s.eatSuffix(2),i(s,a,[">"],"bracket");if(/[\^'"!~\/]/.test(f))return s.eatSuffix(1),i(s,a,[s.eat(f)],"bracket")}else if("r"==f){if("("==(f=s.look(1)))return s.eatSuffix(2),i(s,a,[")"],t,r);if("["==f)return s.eatSuffix(2),i(s,a,["]"],t,r);if("{"==f)return s.eatSuffix(2),i(s,a,["}"],t,r);if("<"==f)return s.eatSuffix(2),i(s,a,[">"],t,r);if(/[\^'"!~\/]/.test(f))return s.eatSuffix(1),i(s,a,[s.eat(f)],t,r)}else if(/[\^'"!~\/(\[{<]/.test(f)){if("("==f)return s.eatSuffix(1),i(s,a,[")"],"string");if("["==f)return s.eatSuffix(1),i(s,a,["]"],"string");if("{"==f)return s.eatSuffix(1),i(s,a,["}"],"string");if("<"==f)return s.eatSuffix(1),i(s,a,[">"],"string");if(/[\^'"!~\/]/.test(f))return i(s,a,[s.eat(f)],"string")}}}if("m"==o){var f=s.look(-2);if(!(f&&/\w/.test(f))&&(f=s.eat(/[(\[{<\^'"!~\/]/))){if(/[\^'"!~\/]/.test(f))return i(s,a,[f],t,r);if("("==f)return i(s,a,[")"],t,r);if("["==f)return i(s,a,["]"],t,r);if("{"==f)return i(s,a,["}"],t,r);if("<"==f)return i(s,a,[">"],t,r)}}if("s"==o||"y"==o){var f=/[\/>\]})\w]/.test(s.look(-2));if(!f&&(f=s.eat(/[(\[{<\^'"!~\/]/)))return"["==f?i(s,a,["]","]"],t,r):"{"==f?i(s,a,["}","}"],t,r):"<"==f?i(s,a,[">",">"],t,r):"("==f?i(s,a,[")",")"],t,r):i(s,a,[f,f],t,r)}if("t"==o){var f=/[\/>\]})\w]/.test(s.look(-2));if(!f&&(f=s.eat("r"))&&(f=s.eat(/[(\[{<\^'"!~\/]/)))return"["==f?i(s,a,["]","]"],t,r):"{"==f?i(s,a,["}","}"],t,r):"<"==f?i(s,a,[">",">"],t,r):"("==f?i(s,a,[")",")"],t,r):i(s,a,[f,f],t,r)}if("`"==o)return i(s,a,[o],"variable-2");if("/"==o)return/~\s*$/.test(s.prefix())?i(s,a,[o],t,r):"operator";if("$"==o){var _=s.pos;if(s.eatWhile(/\d/)||s.eat("{")&&s.eatWhile(/\d/)&&s.eat("}"))return"variable-2";s.pos=_}if(/[$@%]/.test(o)){var _=s.pos;if(s.eat("^")&&s.eat(/[A-Z]/)||!/[@$%&]/.test(s.look(-2))&&s.eat(/[=|\\\-#?@;:&`~\^!\[\]*'"$+.,\/<>()]/)){var f=s.current();if(e[f])return"variable-2"}s.pos=_}if(/[$@%&]/.test(o)&&(s.eatWhile(/[\w$\[\]]/)||s.eat("{")&&s.eatWhile(/[\w$\[\]]/)&&s.eat("}"))){var f=s.current();return e[f]?"variable-2":"variable"}if("#"==o&&"$"!=s.look(-2))return s.skipToEnd(),"comment";if(/[:+\-\^*$&%@=<>!?|\/~\.]/.test(o)){var _=s.pos;if(s.eatWhile(/[:+\-\^*$&%@=<>!?|\/~\.]/),e[s.current()])return"operator";s.pos=_}if("_"==o&&1==s.pos){if("_END__"==s.suffix(6))return i(s,a,["\0"],"comment");if("_DATA__"==s.suffix(7))return i(s,a,["\0"],"variable-2");if("_C__"==s.suffix(7))return i(s,a,["\0"],"string")}if(/\w/.test(o)){var _=s.pos;if("{"==s.look(-2)&&("}"==s.look(0)||s.eatWhile(/\w/)&&"}"==s.look(0)))return"string";s.pos=_}if(/[A-Z]/.test(o)){var u=s.look(-2),_=s.pos;if(s.eatWhile(/[A-Z_]/),/[\da-z]/.test(s.look(0)))s.pos=_;else{var f=e[s.current()];if(!f||(f[1]&&(f=f[0]),":"==u))return"meta";if(1==f)return"keyword";if(2==f)return"def";if(3==f)return"atom";else if(4==f)return"operator";else if(5==f)return"variable-2";else return"meta"}}if(/[a-zA-Z_]/.test(o)){var u=s.look(-2);s.eatWhile(/\w/);var f=e[s.current()];if(!f||(f[1]&&(f=f[0]),":"==u))return"meta";if(1==f)return"keyword";if(2==f)return"def";if(3==f)return"atom";else if(4==f)return"operator";else if(5==f)return"variable-2";else return"meta"}return null}return{startState:function(){return{tokenize:s,chain:null,style:null,tail:null}},token:function(e,t){return(t.tokenize||s)(e,t)},fold:"brace",electricChars:"{}"}}),CodeMirror.defineMIME("text/x-fhem","fhem"),CodeMirror.StringStream.prototype.look=function(e){return this.string.charAt(this.pos+(e||0))},CodeMirror.StringStream.prototype.prefix=function(e){if(!e)return this.string.substr(0,this.pos-1);var t=this.pos-e;return this.string.substr(t>=0?t:0,e)},CodeMirror.StringStream.prototype.suffix=function(e){var t=this.string.length,r=t-this.pos+1;return this.string.substr(this.pos,e&&e=(t=this.string.length-1)?this.pos=t:this.pos=r},Array.prototype.foreach=function(e){for(var t=0;ts&&(r=n+1),n=Math.floor((i+r)/2);return s!=t?null:e[n]}n=l,s=u,a=f,o=c,_=[],n.foreach(function(e,t){0==t.lastIndexOf(o,0)&&_.push({text:t,className:"hintkeyword"})}),s.foreach(function(e,t){0==t.Name.lastIndexOf(o,0)&&(t.Attributes&&null!=t.Attributes.alias?_.push({text:t.Name,displayText:t.Name+" # "+t.Attributes.alias}):_.push(t.Name))}),a.foreach(function(e,t){0==t.lastIndexOf(o,0)&&_.push({text:t,className:"hintvariable"})}),r({list:_,from:CodeMirror.Pos(d.line,g),to:CodeMirror.Pos(d.line,m)})}); +CodeMirror.defineMode("fhem",function(){var o={"->":4,"++":4,"--":4,"**":4,"=~":4,"!~":4,"*":4,"/":4,"%":4,x:4,"+":4,"-":4,".":4,"<<":4,">>":4,"<":4,">":4,"<=":4,">=":4,lt:4,gt:4,le:4,ge:4,"==":4,"!=":4,"<=>":4,eq:4,ne:4,cmp:4,"~~":4,"&":4,"|":4,"^":4,"&&":4,"||":4,"//":4,"..":4,"...":4,"?":4,":":4,"=":4,"+=":4,"-=":4,"*=":4,",":4,"=>":4,"::":4,not:4,and:4,or:4,xor:4,BEGIN:[5,1],END:[5,1],PRINT:[5,1],PRINTF:[5,1],GETC:[5,1],READ:[5,1],READLINE:[5,1],DESTROY:[5,1],TIE:[5,1],TIEHANDLE:[5,1],UNTIE:[5,1],STDIN:5,STDIN_TOP:5,STDOUT:5,STDOUT_TOP:5,STDERR:5,STDERR_TOP:5,$ARG:5,$_:5,"@ARG":5,"@_":5,$LIST_SEPARATOR:5,'$"':5,$PROCESS_ID:5,$PID:5,$$:5,$REAL_GROUP_ID:5,$GID:5,"$(":5,$EFFECTIVE_GROUP_ID:5,$EGID:5,"$)":5,$PROGRAM_NAME:5,$0:5,$SUBSCRIPT_SEPARATOR:5,$SUBSEP:5,"$;":5,$REAL_USER_ID:5,$UID:5,"$<":5,$EFFECTIVE_USER_ID:5,$EUID:5,"$>":5,$a:5,$b:5,$COMPILING:5,"$^C":5,$DEBUGGING:5,"$^D":5,"${^ENCODING}":5,$ENV:5,"%ENV":5,$SYSTEM_FD_MAX:5,"$^F":5,"@F":5,"${^GLOBAL_PHASE}":5,"$^H":5,"%^H":5,"@INC":5,"%INC":5,$INPLACE_EDIT:5,"$^I":5,"$^M":5,$OSNAME:5,"$^O":5,"${^OPEN}":5,$PERLDB:5,"$^P":5,$SIG:5,"%SIG":5,$BASETIME:5,"$^T":5,"${^TAINT}":5,"${^UNICODE}":5,"${^UTF8CACHE}":5,"${^UTF8LOCALE}":5,$PERL_VERSION:5,"$^V":5,"${^WIN32_SLOPPY_STAT}":5,$EXECUTABLE_NAME:5,"$^X":5,$1:5,$MATCH:5,"$&":5,"${^MATCH}":5,$PREMATCH:5,"$`":5,"${^PREMATCH}":5,$POSTMATCH:5,"$'":5,"${^POSTMATCH}":5,$LAST_PAREN_MATCH:5,"$+":5,$LAST_SUBMATCH_RESULT:5,"$^N":5,"@LAST_MATCH_END":5,"@+":5,"%LAST_PAREN_MATCH":5,"%+":5,"@LAST_MATCH_START":5,"@-":5,"%LAST_MATCH_START":5,"%-":5,$LAST_REGEXP_CODE_RESULT:5,"$^R":5,"${^RE_DEBUG_FLAGS}":5,"${^RE_TRIE_MAXBUF}":5,$ARGV:5,"@ARGV":5,ARGV:5,ARGVOUT:5,$OUTPUT_FIELD_SEPARATOR:5,$OFS:5,"$,":5,$INPUT_LINE_NUMBER:5,$NR:5,"$.":5,$INPUT_RECORD_SEPARATOR:5,$RS:5,"$/":5,$OUTPUT_RECORD_SEPARATOR:5,$ORS:5,"$\\":5,$OUTPUT_AUTOFLUSH:5,"$|":5,$ACCUMULATOR:5,"$^A":5,$FORMAT_FORMFEED:5,"$^L":5,$FORMAT_PAGE_NUMBER:5,"$%":5,$FORMAT_LINES_LEFT:5,"$-":5,$FORMAT_LINE_BREAK_CHARACTERS:5,"$:":5,$FORMAT_LINES_PER_PAGE:5,"$=":5,$FORMAT_TOP_NAME:5,"$^":5,$FORMAT_NAME:5,"$~":5,"${^CHILD_ERROR_NATIVE}":5,$EXTENDED_OS_ERROR:5,"$^E":5,$EXCEPTIONS_BEING_CAUGHT:5,"$^S":5,$WARNING:5,"$^W":5,"${^WARNING_BITS}":5,$OS_ERROR:5,$ERRNO:5,"$!":5,"%OS_ERROR":5,"%ERRNO":5,"%!":5,$CHILD_ERROR:5,"$?":5,$EVAL_ERROR:5,"$@":5,$OFMT:5,"$#":5,"$*":5,$ARRAY_BASE:5,"$[":5,$OLD_PERL_VERSION:5,"$]":5,$_blockingcalls:5,$SELF:5,$cmd:5,$DEVICE:5,$device:5,$EVENT:5,$event:5,$EVENTS:5,$events:5,$number:5,$name:5,$TYPE:5,$STATE:5,$room:5,$group:5,$week:5,$hm:5,$md:5,$ymd:5,$twe:5,$TABLE:5,$TD:5,$TR:5,$TC:5,$TPL:5,$ATTRIBUTESFIRST:5,$SHOWNOSTATE:5,$SHOWNODEVICELINE:5,$SHOWNODEVICELINK:5,if:[1,1],elsif:[1,1],else:[1,1],while:[1,1],unless:[1,1],for:[1,1],foreach:[1,1],abs:1,accept:1,alarm:1,atan2:1,bind:1,binmode:1,bless:1,bootstrap:1,break:1,caller:1,chdir:1,chmod:1,chomp:1,chop:1,chown:1,chr:1,chroot:1,close:1,closedir:1,connect:1,continue:[1,1],cos:1,crypt:1,dbmclose:1,dbmopen:1,default:1,defined:1,delete:1,die:1,do:1,dump:1,each:1,endgrent:1,endhostent:1,endnetent:1,endprotoent:1,endpwent:1,endservent:1,eof:1,eval:1,exec:1,exists:1,exit:1,exp:1,fcntl:1,fileno:1,flock:1,fork:1,format:1,formline:1,getc:1,getgrent:1,getgrgid:1,getgrnam:1,gethostbyaddr:1,gethostbyname:1,gethostent:1,getlogin:1,getnetbyaddr:1,getnetbyname:1,getnetent:1,getpeername:1,getpgrp:1,getppid:1,getpriority:1,getprotobyname:1,getprotobynumber:1,getprotoent:1,getpwent:1,getpwnam:1,getpwuid:1,getservbyname:1,getservbyport:1,getservent:1,getsockname:1,getsockopt:1,given:1,glob:1,gmtime:1,goto:1,grep:1,hex:1,import:1,index:1,int:1,ioctl:1,join:1,keys:1,kill:1,last:1,lc:1,lcfirst:1,length:1,link:1,listen:1,local:2,localtime:1,lock:1,log:1,lstat:1,m:null,map:1,mkdir:1,msgctl:1,msgget:1,msgrcv:1,msgsnd:1,my:2,new:1,next:1,no:1,oct:1,open:1,opendir:1,ord:1,our:2,pack:1,package:1,pipe:1,pop:1,pos:1,print:1,printf:1,prototype:1,push:1,q:null,qq:null,qr:null,quotemeta:null,qw:null,qx:null,rand:1,read:1,readdir:1,readline:1,readlink:1,readpipe:1,recv:1,redo:1,ref:1,rename:1,require:1,reset:1,return:1,reverse:1,rewinddir:1,rindex:1,rmdir:1,s:null,say:1,scalar:1,seek:1,seekdir:1,select:1,semctl:1,semget:1,semop:1,send:1,setgrent:1,sethostent:1,setnetent:1,setpgrp:1,setpriority:1,setprotoent:1,setpwent:1,setservent:1,setsockopt:1,shift:1,shmctl:1,shmget:1,shmread:1,shmwrite:1,shutdown:1,sin:1,sleep:1,socket:1,socketpair:1,sort:1,splice:1,split:1,sprintf:1,sqrt:1,srand:1,stat:1,state:1,study:1,sub:1,substr:1,symlink:1,syscall:1,sysopen:1,sysread:1,sysseek:1,system:1,syswrite:1,tell:1,telldir:1,tie:1,tied:1,time:1,times:1,tr:null,truncate:1,uc:1,ucfirst:1,umask:1,undef:1,unlink:1,unpack:1,unshift:1,untie:1,use:1,utime:1,values:1,vec:1,wait:1,waitpid:1,wantarray:1,warn:1,when:1,write:1,define:2,defmod:2,attr:2,at:2,notify:2,set:2,ReadingsVal:1,OldReadingsVal:1,ReadingsNum:1,OldReadingsNum:1,ReadingsTimestamp:1,OldReadingsTimestamp:1,Value:1,fhem:1,IF:2,DOIF:2,DOELSE:2,DOELSEIF:2,y:null};keywords.foreach(function(e,t){o[t]=2});var l="string-2",u=/[goseximacplud]/;function f(e,t,s,a,o){return t.chain=null,t.style=null,t.tail=null,t.tokenize=function(e,t){for(var r,i=!1,n=0;r=e.next();){if(r===s[n]&&!i)return void 0!==s[++n]?(t.chain=s[n],t.style=a,t.tail=o):o&&e.eatWhile(o),t.tokenize=d,a;i=!i&&"\\"==r}return a},t.tokenize(e,t)}function $(e,t,r){return t.tokenize=function(e,t){return e.string==r&&(t.tokenize=d),e.skipToEnd(),"string"},t.tokenize(e,t)}function d(e,t){if(e.eatSpace())return null;if(t.chain)return f(e,t,t.chain,t.style,t.tail);if(e.match(/^\-?[\d\.]/,!1)&&e.match(/^(\-?(\d*\.\d+(e[+-]?\d+)?|\d+\.\d*)|0x[\da-fA-F]+|0b[01]+|\d+(e[+-]?\d+)?)/))return"number";if(e.match(/^<<(?=\w)/))return e.eatWhile(/\w/),$(e,t,e.current().substr(2));if(e.sol()&&e.match(/^\=item(?!\w)/))return $(e,t,"=cut");var r=e.next();if('"'==r||"'"==r){if(e.prefix(3)=="<<"+r){var i=e.pos;e.eatWhile(/\w/);var n=e.current().substr(1);if(n&&e.eat(r))return $(e,t,n);e.pos=i}return f(e,t,[r],"string")}if("q"==r&&(!(s=e.look(-2))||!/\w/.test(s)))if("x"==(s=e.look(0))){if("("==(s=e.look(1)))return e.eatSuffix(2),f(e,t,[")"],l,u);if("["==s)return e.eatSuffix(2),f(e,t,["]"],l,u);if("{"==s)return e.eatSuffix(2),f(e,t,["}"],l,u);if("<"==s)return e.eatSuffix(2),f(e,t,[">"],l,u);if(/[\^'"!~\/]/.test(s))return e.eatSuffix(1),f(e,t,[e.eat(s)],l,u)}else if("q"==s){if("("==(s=e.look(1)))return e.eatSuffix(2),f(e,t,[")"],"string");if("["==s)return e.eatSuffix(2),f(e,t,["]"],"string");if("{"==s)return e.eatSuffix(2),f(e,t,["}"],"string");if("<"==s)return e.eatSuffix(2),f(e,t,[">"],"string");if(/[\^'"!~\/]/.test(s))return e.eatSuffix(1),f(e,t,[e.eat(s)],"string")}else if("w"==s){if("("==(s=e.look(1)))return e.eatSuffix(2),f(e,t,[")"],"bracket");if("["==s)return e.eatSuffix(2),f(e,t,["]"],"bracket");if("{"==s)return e.eatSuffix(2),f(e,t,["}"],"bracket");if("<"==s)return e.eatSuffix(2),f(e,t,[">"],"bracket");if(/[\^'"!~\/]/.test(s))return e.eatSuffix(1),f(e,t,[e.eat(s)],"bracket")}else if("r"==s){if("("==(s=e.look(1)))return e.eatSuffix(2),f(e,t,[")"],l,u);if("["==s)return e.eatSuffix(2),f(e,t,["]"],l,u);if("{"==s)return e.eatSuffix(2),f(e,t,["}"],l,u);if("<"==s)return e.eatSuffix(2),f(e,t,[">"],l,u);if(/[\^'"!~\/]/.test(s))return e.eatSuffix(1),f(e,t,[e.eat(s)],l,u)}else if(/[\^'"!~\/(\[{<]/.test(s)){if("("==s)return e.eatSuffix(1),f(e,t,[")"],"string");if("["==s)return e.eatSuffix(1),f(e,t,["]"],"string");if("{"==s)return e.eatSuffix(1),f(e,t,["}"],"string");if("<"==s)return e.eatSuffix(1),f(e,t,[">"],"string");if(/[\^'"!~\/]/.test(s))return f(e,t,[e.eat(s)],"string")}if("m"==r){var s=e.look(-2);if((!s||!/\w/.test(s))&&(s=e.eat(/[(\[{<\^'"!~\/]/))){if(/[\^'"!~\/]/.test(s))return f(e,t,[s],l,u);if("("==s)return f(e,t,[")"],l,u);if("["==s)return f(e,t,["]"],l,u);if("{"==s)return f(e,t,["}"],l,u);if("<"==s)return f(e,t,[">"],l,u)}}if("s"==r){s=/[\/>\]})\w]/.test(e.look(-2));if(!s&&(s=e.eat(/[(\[{<\^'"!~\/]/)))return f(e,t,"["==s?["]","]"]:"{"==s?["}","}"]:"<"==s?[">",">"]:"("==s?[")",")"]:[s,s],l,u)}if("y"==r){s=/[\/>\]})\w]/.test(e.look(-2));if(!s&&(s=e.eat(/[(\[{<\^'"!~\/]/)))return f(e,t,"["==s?["]","]"]:"{"==s?["}","}"]:"<"==s?[">",">"]:"("==s?[")",")"]:[s,s],l,u)}if("t"==r){s=/[\/>\]})\w]/.test(e.look(-2));if(!s&&(s=e.eat("r"),s=s&&e.eat(/[(\[{<\^'"!~\/]/)))return f(e,t,"["==s?["]","]"]:"{"==s?["}","}"]:"<"==s?[">",">"]:"("==s?[")",")"]:[s,s],l,u)}if("`"==r)return f(e,t,[r],"variable-2");if("/"==r)return/~\s*$/.test(e.prefix())?f(e,t,[r],l,u):"operator";if("$"==r){i=e.pos;if(e.eatWhile(/\d/)||e.eat("{")&&e.eatWhile(/\d/)&&e.eat("}"))return"variable-2";e.pos=i}if(/[$@%]/.test(r)){i=e.pos;if(e.eat("^")&&e.eat(/[A-Z]/)||!/[@$%&]/.test(e.look(-2))&&e.eat(/[=|\\\-#?@;:&`~\^!\[\]*'"$+.,\/<>()]/)){s=e.current();if(o[s])return"variable-2"}e.pos=i}if(/[$@%&]/.test(r)&&(e.eatWhile(/[\w$\[\]]/)||e.eat("{")&&e.eatWhile(/[\w$\[\]]/)&&e.eat("}"))){s=e.current();return o[s]?"variable-2":"variable"}if("#"==r&&"$"!=e.look(-2))return e.skipToEnd(),"comment";if(/[:+\-\^*$&%@=<>!?|\/~\.]/.test(r)){i=e.pos;if(e.eatWhile(/[:+\-\^*$&%@=<>!?|\/~\.]/),o[e.current()])return"operator";e.pos=i}if("_"==r&&1==e.pos){if("_END__"==e.suffix(6))return f(e,t,["\0"],"comment");if("_DATA__"==e.suffix(7))return f(e,t,["\0"],"variable-2");if("_C__"==e.suffix(7))return f(e,t,["\0"],"string")}if(/\w/.test(r)){i=e.pos;if("{"==e.look(-2)&&("}"==e.look(0)||e.eatWhile(/\w/)&&"}"==e.look(0)))return"string";e.pos=i}if(/[A-Z]/.test(r)){var a=e.look(-2),i=e.pos;if(e.eatWhile(/[A-Z_]/),!/[\da-z]/.test(e.look(0)))return(s=o[e.current()])?(s[1]&&(s=s[0]),":"!=a?1==s?"keyword":2==s?"def":3==s?"atom":4==s?"operator":5==s?"variable-2":"meta":"meta"):"meta";e.pos=i}if(/[a-zA-Z_]/.test(r)){a=e.look(-2);return e.eatWhile(/\w/),(s=o[e.current()])?(s[1]&&(s=s[0]),":"!=a?1==s?"keyword":2==s?"def":3==s?"atom":4==s?"operator":5==s?"variable-2":"meta":"meta"):"meta"}return null}return{startState:function(){return{tokenize:d,chain:null,style:null,tail:null}},token:function(e,t){return(t.tokenize||d)(e,t)},fold:"brace",electricChars:"{}"}}),CodeMirror.defineMIME("text/x-fhem","fhem"),CodeMirror.StringStream.prototype.look=function(e){return this.string.charAt(this.pos+(e||0))},CodeMirror.StringStream.prototype.prefix=function(e){if(e){var t=this.pos-e;return this.string.substr(0<=t?t:0,e)}return this.string.substr(0,this.pos-1)},CodeMirror.StringStream.prototype.suffix=function(e){var t=this.string.length,r=t-this.pos+1;return this.string.substr(this.pos,e&&e=(e=this.string.length-1)?this.pos=e:this.pos=t},Array.prototype.foreach=function(e){for(var t=0;t