Changeset 1337

Show
Ignore:
Timestamp:
03/23/08 06:34:57 (3 months ago)
Author:
cederberg@gmail.com
Message:

Updated API docs for MochiKit.Visual.grow() and shrink().

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • mochikit/trunk/doc/html/MochiKit/Visual.html

    r1336 r1337  
    487487<a class="mochidef reference" href="#fn-grow">grow(element [, options])</a>:</p> 
    488488<blockquote> 
    489 <p>Restore the size of an element.</p> 
    490 <dl class="docutils"> 
    491 <dt>element:</dt> 
    492 <dd>An element ID string or a DOM node (see 
    493 <a class="mochiref reference" href="DOM.html#fn-getelement">MochiKit.DOM.getElement</a>).</dd> 
     489<p>Grows an <tt class="docutils literal"><span class="pre">element</span></tt> size using <a class="mochiref reference" href="#fn-scale">Scale</a>, <a class="mochiref reference" href="#fn-move">Move</a> 
     490and <a class="mochiref reference" href="#fn-opacity">Opacity</a> effects in parallel. The <tt class="docutils literal"><span class="pre">element</span></tt> should 
     491have fixed width, height and top-left position. Before the effect 
     492starts, the <tt class="docutils literal"><span class="pre">element</span></tt> will be shown with 
     493<a class="mochiref reference" href="Style.html#fn-showelement">MochiKit.Style.showElement</a> and the size and position 
     494values will be read.</p> 
     495<dl class="docutils"> 
     496<dt>element:</dt> 
     497<dd>An element ID string or a DOM node (see 
     498<a class="mochiref reference" href="DOM.html#fn-getelement">MochiKit.DOM.getElement</a>).</dd> 
     499<dt>options:</dt> 
     500<dd><p class="first">The following options and default values controls this 
     501effect. Note that the <a class="mochiref reference" href="#fn-opacity">Opacity</a> effect is turned 
     502off by default. See also the <a class="mochiref reference" href="#fn-defaultoptions">DefaultOptions</a>.</p> 
     503<table border="1" class="last docutils"> 
     504<colgroup> 
     505<col width="34%" /> 
     506<col width="66%" /> 
     507</colgroup> 
     508<tbody valign="top"> 
     509<tr><td><tt class="docutils literal"><span class="pre">direction</span></tt></td> 
     510<td><tt class="docutils literal"><span class="pre">center</span></tt></td> 
     511</tr> 
     512<tr><td><tt class="docutils literal"><span class="pre">moveTransition</span></tt></td> 
     513<td><tt class="docutils literal"><span class="pre">MochiKit.Visual.Transitions.sinoidal</span></tt></td> 
     514</tr> 
     515<tr><td><tt class="docutils literal"><span class="pre">scaleTransition</span></tt></td> 
     516<td><tt class="docutils literal"><span class="pre">MochiKit.Visual.Transitions.sinoidal</span></tt></td> 
     517</tr> 
     518<tr><td><tt class="docutils literal"><span class="pre">opacityTransition</span></tt></td> 
     519<td><tt class="docutils literal"><span class="pre">MochiKit.Visual.Transitions.full</span></tt></td> 
     520</tr> 
     521</tbody> 
     522</table> 
     523</dd> 
     524</dl> 
     525<p>The <tt class="docutils literal"><span class="pre">direction</span></tt> option controls the origin point of the effect. 
     526The following values are allowed:</p> 
     527<blockquote> 
     528<table border="1" class="docutils"> 
     529<colgroup> 
     530<col width="34%" /> 
     531<col width="66%" /> 
     532</colgroup> 
     533<tbody valign="top"> 
     534<tr><td><tt class="docutils literal"><span class="pre">center</span></tt></td> 
     535<td>Grows from the center</td> 
     536</tr> 
     537<tr><td><tt class="docutils literal"><span class="pre">top-left</span></tt></td> 
     538<td>Grows from the top left corner</td> 
     539</tr> 
     540<tr><td><tt class="docutils literal"><span class="pre">top-right</span></tt></td> 
     541<td>Grows from the top right corner</td> 
     542</tr> 
     543<tr><td><tt class="docutils literal"><span class="pre">bottom-left</span></tt></td> 
     544<td>Grows from the bottom left corner</td> 
     545</tr> 
     546<tr><td><tt class="docutils literal"><span class="pre">bottom-right</span></tt></td> 
     547<td>Grows from the bottom right corner</td> 
     548</tr> 
     549</tbody> 
     550</table> 
     551</blockquote> 
     552<dl class="docutils"> 
    494553<dt><em>Availability</em>:</dt> 
    495554<dd>Available in MochiKit 1.4+</dd> 
     
    500559<a class="mochidef reference" href="#fn-shrink">shrink(element [, options])</a>:</p> 
    501560<blockquote> 
    502 <p>Shrinks an <tt class="docutils literal"><span class="pre">element</span></tt> to its center using <a class="mochiref reference" href="#fn-scale">Scale</a>, 
    503 <a class="mochiref reference" href="#fn-move">Move</a> and <a class="mochiref reference" href="#fn-opacity">Opacity</a> effects in parallel. 
    504 The <tt class="docutils literal"><span class="pre">element</span></tt> should have fixed width, height and top-left 
    505 position. Once the effect has completed, the <tt class="docutils literal"><span class="pre">element</span></tt> will 
    506 be hidden with <a class="mochiref reference" href="Style.html#fn-hideelement">MochiKit.Style.hideElement</a> and the 
    507 original size and position will be restored.</p> 
     561<p>Shrinks an <tt class="docutils literal"><span class="pre">element</span></tt> using <a class="mochiref reference" href="#fn-scale">Scale</a>, <a class="mochiref reference" href="#fn-move">Move</a> 
     562and <a class="mochiref reference" href="#fn-opacity">Opacity</a> effects in parallel. The <tt class="docutils literal"><span class="pre">element</span></tt> should 
     563have fixed width, height and top-left position. Once the effect has 
     564completed, the <tt class="docutils literal"><span class="pre">element</span></tt> will be hidden with 
     565<a class="mochiref reference" href="Style.html#fn-hideelement">MochiKit.Style.hideElement</a> and the original size and 
     566position will be restored.</p> 
    508567<dl class="docutils"> 
    509568<dt>element:</dt> 
     
    513572<dd><p class="first">The following options and default values controls this 
    514573effect. Note that the <a class="mochiref reference" href="#fn-opacity">Opacity</a> effect is turned 
    515 off by default. See also the <a class="mochiref reference" href="#fn-defaultoptions">DefaultOptions</a>:</p> 
     574off by default. See also the <a class="mochiref reference" href="#fn-defaultoptions">DefaultOptions</a>.</p> 
    516575<table border="1" class="last docutils"> 
    517576<colgroup> 
     
    537596</dl> 
    538597<p>The <tt class="docutils literal"><span class="pre">direction</span></tt> option controls the destination point of the 
    539 shrink effect. The following values are allowed:</p> 
     598effect. The following values are allowed:</p> 
    540599<blockquote> 
    541600<table border="1" class="docutils"> 
  • mochikit/trunk/doc/rst/MochiKit/Visual.rst

    r1336 r1337  
    408408:mochidef:`grow(element [, options])`: 
    409409 
    410     Restore the size of an element. 
    411  
    412     element: 
    413         An element ID string or a DOM node (see 
    414         :mochiref:`MochiKit.DOM.getElement`). 
     410    Grows an ``element`` size using :mochiref:`Scale`, :mochiref:`Move` 
     411    and :mochiref:`Opacity` effects in parallel. The ``element`` should 
     412    have fixed width, height and top-left position. Before the effect 
     413    starts, the ``element`` will be shown with 
     414    :mochiref:`MochiKit.Style.showElement` and the size and position 
     415    values will be read. 
     416 
     417    element: 
     418        An element ID string or a DOM node (see 
     419        :mochiref:`MochiKit.DOM.getElement`). 
     420 
     421    options: 
     422        The following options and default values controls this 
     423        effect. Note that the :mochiref:`Opacity` effect is turned 
     424        off by default. See also the :mochiref:`DefaultOptions`. 
     425 
     426        ===================== ======================================== 
     427        ``direction``         ``center`` 
     428        ``moveTransition``    ``MochiKit.Visual.Transitions.sinoidal``     
     429        ``scaleTransition``   ``MochiKit.Visual.Transitions.sinoidal``     
     430        ``opacityTransition`` ``MochiKit.Visual.Transitions.full``     
     431        ===================== ======================================== 
     432 
     433    The ``direction`` option controls the origin point of the effect. 
     434    The following values are allowed: 
     435 
     436        ===================== ======================================== 
     437        ``center``            Grows from the center 
     438        ``top-left``          Grows from the top left corner 
     439        ``top-right``         Grows from the top right corner 
     440        ``bottom-left``       Grows from the bottom left corner 
     441        ``bottom-right``      Grows from the bottom right corner 
     442        ===================== ======================================== 
    415443 
    416444    *Availability*: 
     
    420448:mochidef:`shrink(element [, options])`: 
    421449 
    422     Shrinks an ``element`` to its center using :mochiref:`Scale`, 
    423     :mochiref:`Move` and :mochiref:`Opacity` effects in parallel. 
    424     The ``element`` should have fixed width, height and top-left 
    425     position. Once the effect has completed, the ``element`` will 
    426     be hidden with :mochiref:`MochiKit.Style.hideElement` and the 
    427     original size and position will be restored. 
     450    Shrinks an ``element`` using :mochiref:`Scale`, :mochiref:`Move` 
     451    and :mochiref:`Opacity` effects in parallel. The ``element`` should 
     452    have fixed width, height and top-left position. Once the effect has 
     453    completed, the ``element`` will be hidden with 
     454    :mochiref:`MochiKit.Style.hideElement` and the original size and 
     455    position will be restored. 
    428456 
    429457    element: 
     
    444472 
    445473    The ``direction`` option controls the destination point of the 
    446     shrink effect. The following values are allowed: 
     474    effect. The following values are allowed: 
    447475 
    448476        ===================== ========================================