¾Ö´Ï¸ÞÀ̼ÇÀÌ ´Ù¸¥ ¾Ö´Ï¸ÞÀ̼ǵéÀÇ Ãß°¡»çÇ×Àΰ¡¸¦ ³ªÅ¸³»´Â °ªÀ» ¹ÝȯÇϰųª ¼³Á¤ÇÑ´Ù.

Àμö
: (¼Ó¼º ¹®ÀÚ¿­)
¼Ó¼º°ªÀº ´ÙÀ½ Áß ÇϳªÀÇ ¹®ÀÚ¿­ÀÌ´Ù.

replace µðÆúÆ®À̸ç, ¾Ö´Ï¸ÞÀ̼ÇÀÌ Çö ¾ÖÆ®¸®ºäÆ® °ª°ú ´Ù¸¥ ¿ì¼± ¼øÀ§°¡ ³·Àº ´Ù¸¥ ¾Ö´Ï¸ÞÀ̼ÇÀ» µ¤¾î¾º¿î´Ù.
sum ¾Ö´Ï¸ÞÀ̼ÇÀÌ ÇöÀçÀÇ °ª°ú ´Ù¸¥ ¿ì¼± ¼øÀ§°¡ ³·Àº ¾Ö´Ï¸ÞÀ̼ǿ¡ Ãß°¡µÈ´Ù.

ÀÌ ¼Ó¼ºÀº Àбâ/¾²±â·Î µðÆúÆ®°ªÀº replaceÀÌ´Ù.

Ư±â

additive ¼Ó¼ºÀº ¹®ÀÚ¿­À̳ª ºÎ¿ï°ª °°Àº °ÍÀº Àû¿ëµÇÁö ¾Ê°í Áö¿øÇÏÁö ¸øÇÑ´Ù.

to¿Í by ¼Ó¼ºÀ¸·Î ¾Ö´Ï¸ÞÀÌ¼Ç ±â´ÉÀ» ¼³Á¤ÇÒ ¼ö Àִµ¥, ÀϺÎÀÇ °æ¿ì¿¡ additive ¾ÖÆ®¸®ºäÆ® °ªÀ» µ¤¾î¾º¿î´Ù.

from ¾øÀÌ by¸¦ »ç¿ëÇϸé, ¾Ö´Ï¸ÞÀ̼ÇÀÌ Ãß°¡µÈ´Ù. ÀÌ´Â additive="sum"¿¡ ÇØ´çµÈ´Ù. ±×·¯³ª °°Àº ¹æ½ÄÀ¸·Î to¸¦ »ç¿ëÇÏ°í ¾ÖÆ®¸®ºäÆ®°¡ additive ¼Ó¼ºÀ» Áö¿øÇÏ°í ÀÖÀ¸¸é, ¾Ö´Ï¸ÞÀ̼ÇÀÌ Á¶ÇյǾî Ãß°¡µÇ°Å³ª Ãß°¡µÇÁö ¾Ê´Â´Ù. ÇöÀçÀÇ °ªÀº ½ÃÀÛÇÏ´Â ½ËÁ¡¿¡¼­ »ç¿ëµÇ°í Áö¼ÓµÇÁö³² Á¾·á°ªÀº to ¾ÖÆ®¸®ºäÆ®°ªÀ» µ¤¾î¾º¿ö ¾Ö´Ï¸ÞÀÌ¼Ç Ãß°¡°¡ µÇÁö ¾ÊÀº °Íó·³ µÈ´Ù.

additive ¼Ó¼ºÀ» accumulate ¾ÖÆ®¸®ºäÆ®¿Í È¥Á¾ÇÏÁö ¸»¾Æ¾ß ÇÑ´Ù. additive ¼Ó¼ºÀº ±âÃÊ°ªÀ» °®°í ´Ù¸¥ ¾Ö´Ï¸ÞÀ̼ǵé°ú ¾î¶»°Ô °áÇÕÇϴ°¡¸¦ Á¤ÀÇÇÏ°í, accumulate´Â À̴ϸÞÀÌ¼Ç ±â´ÉÀÌ ¹Ýº¹°úÁ¤¿¡¼­ ÀÚüÀûÀ¸·Î ¾î¶»°Ô ÀÛ¿ëÇϴ°¡ ¸¸À» Á¤ÀÇÇÑ´Ù.

Àû¿ë
°³Ã¼scriptHTML±Ô°ÝIE
Âü°í

HTML+time2

ÀÌ ¼Ó¼ºÀº (¿µ¹®) W3C SMIL 2.0(Synchronized Multimedia Integration Language)¿¡¼­ Á¤ÀǵǾú´Ù.


È®Àå DIV
additive=
Ƚ¼ö : 1
 

<HTML xmlns:t="urn:schemas-microsoft-com:time">
<HEAD>
<IMPORT namespace="t" implementation="#default#time2">
<STYLE>.time{ behavior: url(#default#time2);}</STYLE>
<SCRIPT>
function beginreplace(){
    count.innerText='1';
    aniObj.additive=additive1.innerText='replace';
    aniObj.beginElement();
    showW.innerText=showH.innerText='';
}
function beginSum(){
    count.innerText='1';
    aniObj.additive=additive1.innerText='sum';
    aniObj.beginElement();
    showW.innerText=showH.innerText='';
}
function displayDimension(){
  if(aniObj.additive=='sum'){
    showH.innerText='³ôÀÌ:'+divObj.style.height;
    showW.innerHTML='ÃÑ ³Êºñ:250px=('+aniObj.by+'+'+divObj.style.width+')<HR width=250>';
  }else{
    showH.innerText='³ôÀÌ:'+divObj.style.height;
    showW.innerHTML='ÃÑ ³Êºñ:'+aniObj.by+'px<HR width=150>';
  }
}
</SCRIPT>
</HEAD>

<BODY>
<T:ANIMATE id="aniObj" targetElement="divObj" attributeName="width" by="150" dur="3" repeatCount="3" begin="indefinite"
  onend="displayDimension();" onrepeat="count.innerText=aniObj.currTimeState.repeatCount+1" fill="freeze" />
<DIV id="divObj" style="position:ralative;top:0;left:0;height:50;width:100;padding:9;
  background-color:aqua;text-align:center;font-size:20;border:solid 2 blue;">È®Àå DIV</DIV>
additive=<SPAN id="additive1" style=color:blue></SPAN><BR>

Ƚ¼ö : <SPAN id="count" style=color:blue>1</SPAN><BR>
<SPAN id="showH"></SPAN> <SPAN id="showW"></SPAN>

<P>
<BUTTON onclick="beginreplace()"><B>additive</B>=replace</BUTTON>
<BUTTON onclick="beginSum()"><B>additive</B>=sum</BUTTON></P>
</BODY>
</HTML>