var nCho= [1,1,1,1,1, 1,1,1,1,1, 1,1,1,1,1, 1,1,1,1]; var nJung=[1,1,1,1,1, 1,1,1,1,2, 2,2,1,1,2, 2,2,1,1,2, 1]; var nJong=[0,1,1,2,1, 2,2,1,1,2, 2,2,2,2,2, 2,1,1,2,1, 1,1,1,1,1, 1,1,1]; var dv=21*28; var start=false, dt=0, avt=0, topt=0, avp=0, exn=0; var exrn=3, oItv=""; var tStrs, tStrs_n=50; function gId(id) { return document.getElementById(id); } function sId(id,s) { document.getElementById(id).innerHTML=s; } function xHDiv(hg) { var hc,cho,jung,jong; hc=hg.charCodeAt(0)-0xAC00;//ubase1; if(hc<0) return 1; cho=Math.floor(hc/dv); hc=hc%dv; jung=Math.floor(hc/28); jong=hc%28; var tn=nCho[cho]+nJung[jung]+nJong[jong]; return tn; } function xCalN(s) { var l=s.length; var i=0, tn=0, c; while(i=tStrs_n) { xSend(Math.floor(avt)); if(confirm("선택한 글을 모두 끝냈습니다!\n현재글로 다시 연습하시겠습니까?")) { xReset(); } else { //글선택 화면으로... window.history.back(); return; } } document.getElementById("id_err").innerText=""; sId('t3', exn+"/"+tStrs_n); fe['t1'].value=tStrs[exn]; gId("id_next").innerText=(exn+1200) s+="."+k; else s+=k; } if(ontopt) { topt=t; //dc.getElementById("id_g2").innerText=sgrp1.substr(0,Math.floor(t*0.07)); dc.getElementById("id_g2").style.width=Math.floor((t/10)*(w/100))+'px'; dc.getElementById("id_s2").innerText=t; } dc.getElementById("id_s1").innerText=t; dc.getElementById("id_s2").innerText=topt; avt=((avt*exn)+t)/(exn+1); dc.getElementById("id_s3").innerText=Math.floor(avt); var p=on*100/l1; dc.getElementById("id_s4").innerText=Math.floor(p); avp=(avp*exn+p)/(exn+1); dc.getElementById("id_s5").innerText=Math.floor(avp); gId("id_g1").style.width=Math.floor((t/10)*(w/100))+'px'; gId("id_g3").style.width=Math.floor((avt/10)*(w/100))+'px';; gId("id_g4").style.width=Math.floor(p*(w/100))+'px'; gId("id_g5").style.width=Math.floor(avp*(w/100))+'px';//innerText=sgrp1.substr(0,Math.floor(avp*0.4)); /* dc.getElementById("id_g1").innerText=sgrp1.substr(0,Math.floor(t*0.07)); dc.getElementById("id_g3").innerText=sgrp1.substr(0,Math.floor(avt*0.07)); dc.getElementById("id_g4").innerText=sgrp1.substr(0,Math.floor(p*0.4)); dc.getElementById("id_g5").innerText=sgrp1.substr(0,Math.floor(avp*0.4)); */ exn++; xNextStr(); fe['t2'].focus(); } function xKeyDown() { if(start==false) { dt=(new Date).getTime(); start=true; } if(event.keyCode==13) { xCkStr(); xStartItv(); } } function xStartItv() { if(oItv) clearInterval(oItv); if(start) return; oItv=setInterval("xItv()",500); } function xItv() { if(start) { clearInterval(oItv); return; } if(document.forms['f1'].elements['t2'].value.length>0) {dt=(new Date).getTime(); start=true; clearInterval(oItv); } } extime=0; function xItv2() { sId('t4', extime); extime++; } oItv2=""; function xStart() { xReset(); xNextStr(); document.forms['f1'].elements['t2'].focus(); if(!oItv2) oItv2=setInterval("xItv2()",60000); }