this.isStartWith = function(str,code,index){
if(typeof(str)!="undefined"&&str.length>0){
for(var i=0;i<str.length;i++){
if(this._caseSensitive){
if(str.charAt(i)!=code[index+i]||(index+i>=code.length)){
return false;
}
} else {
if(str.charAt(i).toLowerCase()!=code[index+i].toLowerCase()||(index+i>=code.length)){
return false;
}
}
}
return true;
} else {
return false;
}
}
this.isKeyword = function(val){
return this._keywords.contains(this._caseSensitive?val:val.toLowerCase());
}
this.isCommonObject = function(val){
return this._commonObjects.contains(this._caseSensitive?val:val.toLowerCase());
}
this.isTag = function(val){
return this._tags.contains(val.toLowerCase());
}
}
function doHighlight(o, syntax){
var htmltxt = "";
if(o == null){
alert("domNode is null!");
return;
}
var _codetxt = "";