/*--Keyoti js--*/ //Version 1.4 (RapidSpell Web assembly version 3.4.0 onwards) //Copyright Keyoti Inc. 2005-2007 //This code is not to be modified, copied or used without a license in any form. var rsS51=new Array("", "popup", "", "undefined", "<", "<", ">", ">", "
", "", "", "script TYPE='text/javascript'", ">\n", "function getPageCoords (el) {\n", " var coords = {x: 0, y: 0};\n", " do {\n", " coords.x += el.offsetLeft;\n", " coords.y += el.offsetTop;\n", " }\n", " while ((el = el.offsetParent));\n", " return coords;\n", "}\n", "function scrollIntoView(el) {\n", " var coords = getPageCoords(el);\n", " window.scrollTo (coords.x, coords.y);\n", "/script", "", "", "", "", "highlight", "", "?fMessage=addWord&UserDictionaryFile=", "&word=", "&GuiLanguage=", "", "", "(<([^>])*)on(([^ |^=)*([ |=])*=([ |=])*([^ |^>])*(([^>])*>))", "$1$3", "(<([^>])*)([ |=])*=([ |=])*([^ |^>])*javascript:([^ |^>])*(([^>])*>)", "$1$7", "", ""); var rs_s2=window;var rs_s3=document; var spellCheckFinished=false; var duplicateWord=false; var showXMLTags=true; var userDicFile=rsS51[0]; var mode=rsS51[1]; var callBack=rsS51[0]; var currentWordIndex=0; var ignoreWordIndexes=new Object(); var documentTextBoxStyle=rsS51[2]; var hist = new Array(); var histPtr=0; var addingWord = false; function onWordAdded(){ addingWord = false; } function updateHistory(){ if(enableUndo){ var curChecking = -1; if(openerWindow != null && typeof (openerWindow.currentlyChecking) != rsS51[3]) curChecking = openerWindow.currentlyChecking; var fieldDisEl = rs_s3.getElementById(rsw_fieldDisplayTextLabelID); var elHTML = rsS51[0]; if(fieldDisEl)elHTML = fieldDisEl.innerHTML; hist[histPtr] = [cp(ignoreWordIndexes), currentWordIndex, text, cp(badWords), interfaceObject, curChecking, getIndices(badWords), elHTML]; histPtr++; } } function undoChange(){ activateButtons(); if(histPtr>0){ histPtr--; if(hist[histPtr][4]!=interfaceObject)interfaceObject.setText(text); ignoreWordIndexes = hist[histPtr][0]; currentWordIndex = hist[histPtr][1]; text = hist[histPtr][2]; badWords = hist[histPtr][3]; interfaceObject = hist[histPtr][4]; var curChecking = hist[histPtr][5]; if(typeof (openerWindow != null && openerWindow.currentlyChecking) != rsS51[3] && curChecking>-1)openerWindow.currentlyChecking = curChecking; setIndices(badWords, hist[histPtr][6]); var elHTML = hist[histPtr][7]; var fieldDisEl = rs_s3.getElementById(rsw_fieldDisplayTextLabelID); if(fieldDisEl) fieldDisEl.innerHTML = elHTML; hist.length = histPtr+1; refresh(); } } function cp(ary){ var bry = new Array(); for(var i=0; i=badWords.length){ deactivateButtons(); } else { } refresh(); } function textToHtml(t){ if(showXMLTags){ var ltexp = new RegExp(rsS51[4]); while(ltexp.test(t)) t = t.replace(ltexp, rsS51[5]); var gtexp = new RegExp(rsS51[6]); while(gtexp.test(t)) t = t.replace(gtexp, rsS51[7]); } else { } var newlineexp = new RegExp(newlineRule); while(newlineexp.test(t)) t = t.replace(newlineexp, rsS51[8]); return t; } function refresh(){ if(currentWordIndex0){ finishedMessageJS(); } else { noErrorsMessageJS(); } spellCheckFinished=true; finish(); } } function changeWord(index){ changeNotifyCode(index); var newText=rsS51[0]; if(duplicateWord && rs_s3.forms[0].word.value==rsS51[0]){ badWords[index].start--; } newText+=text.substring(0,badWords[index].start); newText+=document.forms[0].word.value; newText+=text.substring(badWords[index].end,text.length); moveWordOffsets(rs_s3.forms[0].word.value.length-text.substring(badWords[index].start,badWords[index].end).length,index+1); text=newText; } function moveWordOffsets(delta,start){ for(i=start;i