Print Friendly

# Class YAHOO.ext.Actor

Package: | YAHOO.ext
Class: | Actor
Extends: | Element
Defined In: | Actor.js

Provides support for syncing and chaining of Element Yahoo! UI based animation and some common effects. Actors support "self-play" without an Animator.
Note: Along with the animation methods defined below, this class inherits and captures all of the "set" or animation methods of YAHOO.ext.Element. "get" methods are not captured and execute immediately.
Usage:

    var actor = new YAHOO.ext.Actor('myElementId');
    actor.startCapture(true);
    actor.moveTo(100, 100, true);
    actor.squish();
    actor.play();

    // or to start capturing immediately, with no Animator (the null second param)

    var actor = new YAHOO.ext.Actor('myElementId', null, true);
    actor.moveTo(100, 100, true);
    actor.squish();
    actor.play();

## Public Properties

Property | Defined By
--- | ---
| DISPLAY<static> : Number | Element
<static> Visibility mode constant - Use display to hide element
| VISIBILITY<static> : Number | Element
<static> Visibility mode constant - Use visibility to hide element
| autoBoxAdjust : Object | Element
true to automatically adjust width and height settings for box-model issues (default to true)
| autoDisplayMode : Object | Element
true to automatically detect display mode and use display instead of visibility with show()/hide() (defaults to false...
| capturing : Object | Actor
Whether this actor is currently capturing
| defaultUnit : String | Element
The default unit to append to CSS values where a unit isn't provided (Defaults to px).
| dom : HTMLElement | Element
The DOM element
| id : String | Element
The DOM element ID
| originalDisplay : String | Element
The element's default display mode

## Public Methods

Method | Defined By
--- | ---
| Actor(`String/HTMLElement el`, [`YAHOO.ext.Animator animator`], [`Boolean selfCapture`]) | Actor
Create new Actor.
| addAsyncCall(`Function fcn`, `Number callbackIndex`, [`Array args`], [`Object scope`]) : void | Actor
Capture an async function call.
| addCall(`Function fcn`, [`Array args`], [`Object scope`]) : void | Actor
Capture a function call.
| addClass() : void | Actor
Capturing override - See YAHOO.ext.Element.addClass for method details.
| addClassOnOver(`String className`) : YAHOO.ext.Element | Element
Sets up event handlers to add and remove a css class when the mouse is over this element
| addHandler(`String eventName`, `Boolean stopPropagation`, `Function handler`, [`Object scope`], [`boolean override`]) : YAHOO.ext.Element | Element
Appends an event handler to this element. The difference between this function and addListener is this function preve...
| addKeyListener(`Number/Array/Object/String key`, `Function fn`, [`Object scope`]) : YAHOO.ext.KeyMap | Element
Convenience method for constructing a KeyMap
| addKeyMap(`Object config`) : YAHOO.ext.KeyMap | Element
Creates a KeyMap for this element
| addListener(`String eventName`, `Function handler`, [`Object scope`], [`boolean override`]) : YAHOO.ext.Element | Element
Appends an event handler to this element
| addManagedListener(`String eventName`, `Function fn`, [`Object scope`], [`boolean override`]) : Function | Element
Append a managed listener - See YAHOO.ext.EventObject for more details. Use mon() for a shorter version.
| alignTo() : void | Actor
Capturing and animation syncing override - See YAHOO.ext.Element.alignTo for method details.
| animate() : void | Actor
Capturing and animation syncing override - See YAHOO.ext.Element.animate for method details.
| appear([`Float duration`]) : void | Actor
Fade an element in
| appendChild(`String/HTMLElement/Array/Element/CompositeElement el`) : YAHOO.ext.Element | Element
Appends the passed element(s) to this element
| appendTo(`String/HTMLElement/Element el`) : YAHOO.ext.Element | Element
Appends this element to the passed element
| applyStyles(`String/Object/Function styles`) : YAHOO.ext.Element | Element
More flexible version of setStyle for setting style properties.
| autoHeight() : void | Actor
Capturing and animation syncing override - See YAHOO.ext.Element.autoHeight for method details.
| beginMeasure() : YAHOO.ext.Element | Element
Temporarily enables offsets (width,height,x,y) for an element with display:none, use endMeasure() when done.
| blindHide(`String anchor`, [`Float duration`], [`Function easing`]) : void | Actor
Hide the element using a "blinds" effect
| blindShow(`String anchor`, [`Number newSize`], [`Float duration`], [`Function easing`]) : void | Actor
Show the element using a "blinds" effect
| blur() : YAHOO.ext.Element | Element
Tries to blur the element. Any exceptions are caught.
| bounce() : void | Actor
Bounce this element from up and down
| bufferedListener(`String eventName`, `Function handler`, [`Object scope`], [`Number millis`]) : Function | Element
Appends an event handler to this element that is buffered. If the event is triggered more than once in the specified ...
| capture(`YAHOO.ext.Actor.Action action`) : void | Actor
Captures an action for this actor. Generally called internally but can be called directly.
| center([`String/HTMLElement/YAHOO.ext.Element centerIn`]) : void | Element
Centers the Element in either the viewport, or another Element.
| clear() : void | Actor
Clears any calls that have been self captured.
| clearOpacity() : void | Actor
Capturing override - See YAHOO.ext.Element.clearOpacity for method details.
| clearPositioning() : void | Actor
Capturing override - See YAHOO.ext.Element.clearPositioning for method details.
| clip() : void | Actor
Capturing override - See YAHOO.ext.Element.clip for method details.
| createChild(`Object config`, [`HTMLElement insertBefore`]) : YAHOO.ext.Element | Element
Creates the passed DomHelper config and appends it to this element or optionally inserts it before the passed child e...
| createProxy(`String/Object config`, [`String/HTMLElement renderTo`], [`Boolean matchBox`]) : YAHOO.ext.Element | Element
Creates a proxy element of this element
| createShim() : YAHOO.ext.Element | Element
Creates an iframe shim for this element to keep selects and other windowed objects from showing through.
| dropOut([`Float duration`]) : void | Actor
Fade the element as it is falling from it's current position
| enableDisplayMode() : void | Actor
Capturing override - See YAHOO.ext.Element.enableDisplayMode for method details.
| endMeasure() : YAHOO.ext.Element | Element
Restores displays to before beginMeasure was called
| fade([`Float duration`]) : void | Actor
Fade an element out
| fitToParent([`Boolean monitorResize`]) : YAHOO.ext.Element | Element
Sizes this element to it's parent element's dimensions performing neccessary box adjustments.
| focus() : void | Actor
Capturing override - See YAHOO.ext.Element.focus for method details.
| frame([`Number color`], [`Number count`], [`Float duration`]) : void | Actor
Show a ripple of exploding, attenuating borders to draw attention to an Element.
| get<static>(`String/HTMLElement/Element el`, [`Boolean autoGenerateId`]) : Element | Element
<static> Static method to retreive Element objects. Uses simple caching to consistently return the same object....
| getBorderWidth(`String side`) : Number | Element
Gets the width of the border(s) for the specified side(s)
| getBottom(`Boolean local`) : Number | Element
Gets the bottom Y coordinate of the element (element Y position + element height)
| getBox([`Boolean contentBox`], [`Boolean local`]) : Object | Element
Return a box {x, y, width, height} that can be used to set another elements size/location to match this element.
| getCenterXY(`Boolean offsetScroll`) : Array | Element
Calculates the x, y to center this element on the screen
| getChildrenByClassName(`String className`, [`String tagName`]) : Array | Element
Gets an array of child YAHOO.ext.Element objects by class name and optional tagName
| getChildrenByTagName(`String tagName`) : Array | Element
Gets an array of child YAHOO.ext.Element objects by tag name
| getHeight([`Boolean contentHeight`]) : Number | Element
Returns the offset height of the element
| getLeft(`Boolean local`) : Number | Element
Gets the left X coordinate
| getMargins([`String sides`]) : Object/Number | Element
Returns an object with properties top, left, right and bottom representing the margins of this element unless sides i...
| getNextSibling() : HTMLElement | Element
Gets the next sibling, skipping text nodes
| getPadding(`String side`) : Number | Element
Gets the width of the padding(s) for the specified side(s)
| getPositioning() : Object | Element
Gets an object with all CSS positioning properties. Useful along with setPostioning to get snapshot before performin...
| getPrevSibling() : HTMLElement | Element
Gets the previous sibling, skipping text nodes
| getRegion() : Region | Element
Returns the region of the given element. The element must be part of the DOM tree to have a region (display:none or e...
| getRight(`Boolean local`) : Number | Element
Gets the right X coordinate of the element (element X position + element width)
| getSize([`Boolean contentSize`]) : Object | Element
Returns the size of the element
| getStyle(`String property`) : String | Element
Normalizes currentStyle and ComputedStyle.
| getTop(`Boolean local`) : Number | Element
Gets the top Y coordinate
| getUpdateManager() : YAHOO.ext.UpdateManager | Element
Gets this elements UpdateManager
| getWidth([`Boolean contentWidth`]) : Number | Element
Returns the offset width of the element
| getX() : void | Element
Gets the current X position of the element based on page coordinates. Element must be part of the DOM tree to have p...
| getXY() : void | Element
Gets the current position of the element based on page coordinates. Element must be part of the DOM tree to have pag...
| getY() : void | Element
Gets the current Y position of the element based on page coordinates. Element must be part of the DOM tree to have p...
| hasClass(`String className`) : Boolean | Element
Checks if a CSS class is in use by the element.
| hide() : void | Actor
Capturing and animation syncing override - See YAHOO.ext.Element.hide for method details.
| highlight([`String color`], [`String fromColor`], [`Float duration`], [`String attribute`]) : void | Actor
Highlight the element using a background color (or passed attribute) animation
| initDD(`String group`, `Object config`, `Object overrides`) : YAHOO.util.DD | Element
Initializes a YAHOO.util.DD object for this element.
| initDDProxy(`String group`, `Object config`, `Object overrides`) : YAHOO.util.DDProxy | Element
Initializes a YAHOO.util.DDProxy object for this element.
| initDDTarget(`String group`, `Object config`, `Object overrides`) : YAHOO.util.DDTarget | Element
Initializes a YAHOO.util.DDTarget object for this element.
| insertAfter(`String/HTMLElement/Element el`) : YAHOO.ext.Element | Element
Inserts this element after the passed element in the DOM
| insertBefore(`String/HTMLElement/Element el`) : YAHOO.ext.Element | Element
Inserts this element before the passed element in the DOM
| insertHtml(`String where`, `String html`) : YAHOO.ext.Element | Element
Inserts an html fragment into this element
| isBorderBox() : Boolean | Element
Tests various css rules/browsers to determine if this element uses a border box
| isDisplayed() : Boolean | Element
Returns true if display is not "none"
| isVisible([`Boolean deep`]) : Boolean | Element
Checks whether the element is currently visible using both visibility and display properties.
| load() : void | Actor
Capturing and animation syncing override - See YAHOO.ext.Element.load for method details.
| mon(`String eventName`, `Function fn`, [`Object scope`], [`boolean override`]) : Function | Element
Append a managed listener (shorthanded for addManagedListener)
| move() : void | Actor
Capturing and animation syncing override - See YAHOO.ext.Element.move for method details.
| moveIn(`String anchor`, [`Array to`], [`Float duration`], [`Function easing`]) : void | Actor
Show the element in a way that it appears as if it is flying onto the screen
| moveOut(`String anchor`, [`Float duration`], [`Function easing`]) : void | Actor
Hide the element in a way that it appears as if it is flying off the screen
| moveTo() : void | Actor
Capturing and animation syncing override - See YAHOO.ext.Element.moveTo for method details.
| on(`String eventName`, `Function handler`, [`Object scope`], [`boolean override`]) : YAHOO.ext.Element | Element
Appends an event handler to this element (Same as addListener)
| pause(`Number seconds`) : void | Actor
Capture a pause (in seconds).
| play([`Function oncomplete`]) : void | Actor
Starts playback of self captured calls.
| pulsate([`Number count`], [`Float duration`]) : void | Actor
Fade the element in and out the specified amount of times
| radioClass(`String className`) : YAHOO.ext.Element | Element
Adds the passed className to this element and removes the class from all siblings
| remove() : void | Actor
Capturing override - See YAHOO.ext.Element.remove for method details.
| removeAllListeners() : YAHOO.ext.Element | Element
Removes all previous added listeners from this element
| removeClass() : void | Actor
Capturing override - See YAHOO.ext.Element.removeClass for method details.
| removeListener(`String sType`, `Function fn`, `Object scope`) : YAHOO.ext.Element | Element
Removes an event handler from this element
| repaint() : YAHOO.ext.Element | Element
Forces the browser to repaint this element
| replace(`String/HTMLElement/Element el`) : YAHOO.ext.Element | Element
Replaces the passed element with this element
| replaceClass() : void | Actor
Capturing override - See YAHOO.ext.Element.replaceClass for method details.
| scrollIntoView([`String/HTMLElement/Element container`]) : YAHOO.ext.Element | Element
Scrolls this element into view within the passed container.
| select(`String selector`, `Boolean unique`) : CompositeElement/CompositeElementLite | Element
Selects child nodes based on the passed CSS selector (the selector should not contain an id)
| select<static>(`String/Array selector`, [`Boolean unique`]) : CompositeElementLite/CompositeElement | Element
<static> Selects elements based on the passed CSS selector to enable working on them as 1.
| set(`Object o`) : YAHOO.ext.Element | Element
Sets the passed attributes as attributes of this element (a style attribute can be a string, object or function)
| setAbsolutePositioned() : void | Actor
Capturing override - See YAHOO.ext.Element.setAbsolutePositioned for method details.
| setBottom(`String bottom`) : YAHOO.ext.Element | Element
Set the element's css bottom style
| setBounds() : void | Actor
Capturing and animation syncing override - See YAHOO.ext.Element.setBounds for method details.
| setBox() : void | Actor
Capturing and animation syncing override - See YAHOO.ext.Element.setBox for method details.
| setDisplayed(`Boolean value`) : YAHOO.ext.Element | Element
Sets the css display. Uses originalDisplay if value is a boolean true.
| setHeight() : void | Actor
Capturing and animation syncing override - See YAHOO.ext.Element.setHeight for method details.
| setLeft() : void | Actor
Capturing override - See YAHOO.ext.Element.setLeft for method details.
| setLeftTop() : YAHOO.ext.Element | Element
Quick set left and top adding default units
| setLocation() : void | Actor
Capturing and animation syncing override - See YAHOO.ext.Element.setLocation for method details.
| setOpacity() : void | Actor
Capturing and animation syncing override - See YAHOO.ext.Element.setOpacity for method details.
| setPositioning() : void | Actor
Capturing override - See YAHOO.ext.Element.setPositioning for method details.
| setRegion(`YAHOO.util.Region region`, [`Boolean animate`], [`float duration`], [`Function onComplete`], [`Function easing`]) : YAHOO.ext.Element | Element
Sets the element's position and size the the specified region. If animation is true then width, height, x and y will ...
| setRelativePositioned() : void | Actor
Capturing override - See YAHOO.ext.Element.setRelativePositioned for method details.
| setRight(`String right`) : YAHOO.ext.Element | Element
Set the element's css right style
| setSize() : void | Actor
Capturing and animation syncing override - See YAHOO.ext.Element.setSize for method details.
| setStyle() : void | Actor
Capturing override - See YAHOO.ext.Element.setStyle for method details.
| setTop() : void | Actor
Capturing override - See YAHOO.ext.Element.setTop for method details.
| setVisibilityMode() : void | Actor
Capturing override - See YAHOO.ext.Element.setVisibilityMode for method details.
| setVisible() : void | Actor
Capturing and animation syncing override - See YAHOO.ext.Element.setVisible for method details.
| setWidth() : void | Actor
Capturing and animation syncing override - See YAHOO.ext.Element.setWidth for method details.
| setX() : void | Actor
Capturing override - See YAHOO.ext.Element.setX for method details.
| setXY() : void | Actor
Capturing and animation syncing override - See YAHOO.ext.Element.setXY for method details.
| setY() : void | Actor
Capturing override - See YAHOO.ext.Element.setY for method details.
| shake() : void | Actor
Shake this element from side to side
| show() : void | Actor
Capturing and animation syncing override - See YAHOO.ext.Element.show for method details.
| slideHide(`String anchor`, [`Float duration`], [`Function easing`]) : void | Actor
Hide the element using a "slide in" effect - In order for this effect to work the element MUST have a child element c...
| slideShow(`String anchor`, [`Number newSize`], [`Float duration`], [`Function easing`]) : void | Actor
Show the element using a "slide in" effect - In order for this effect to work the element MUST have a child element c...
| squish([`Float duration`]) : void | Actor
Hide the element by "squishing" it into the corner
| startCapture() : void | Actor
Start self capturing calls on this Actor. All subsequent calls are captured and executed when play() is called.
| stopCapture() : void | Actor
Stop self capturing calls on this Actor.
| swallowEvent(`String eventName`, [`Boolean preventDefault`]) : YAHOO.ext.Element | Element
Stops the specified event from bubbling and optionally prevent's the default action
| switchOff([`Float duration`]) : void | Actor
Blink the element as if it was clicked and then collapse on it's center
| toggle() : void | Actor
Capturing and animation syncing override - See YAHOO.ext.Element.toggle for method details.
| toggleClass(`String className`) : YAHOO.ext.Element | Element
Toggles (adds or removes) the passed class.
| unclip() : void | Actor
Capturing override - See YAHOO.ext.Element.unclip for method details.
| unselectable() : YAHOO.ext.Element | Element
Disables text selection for this element (normalized across browsers)
| update() : void | Actor
Capturing override - See YAHOO.ext.Element.update for method details.
| wrap([`Object config`]) : Element | Element
Creates and wraps this element with another element

## Public Events

This class has no public events.

## Property Details

### DISPLAY<static>

`public Number DISPLAY<static>`
<static> Visibility mode constant - Use display to hide element
This property is defined by Element.

### VISIBILITY<static>

`public Number VISIBILITY<static>`
<static> Visibility mode constant - Use visibility to hide element
This property is defined by Element.

### autoBoxAdjust

`public Object autoBoxAdjust`
true to automatically adjust width and height settings for box-model issues (default to true)
This property is defined by Element.

### autoDisplayMode

`public Object autoDisplayMode`
true to automatically detect display mode and use display instead of visibility with show()/hide() (defaults to false). To enable this globally:

    YAHOO.ext.Element.prototype.autoDisplayMode = true;

This property is defined by Element.

### capturing

`public Object capturing`
Whether this actor is currently capturing
This property is defined by Actor.

### defaultUnit

`public String defaultUnit`
The default unit to append to CSS values where a unit isn't provided (Defaults to px).
This property is defined by Element.

### dom

`public HTMLElement dom`
The DOM element
This property is defined by Element.

### id

`public String id`
The DOM element ID
This property is defined by Element.

### originalDisplay

`public String originalDisplay`
The element's default display mode
This property is defined by Element.

## Constructor Details

### Actor

`public function Actor(`String/HTMLElement el`, [`YAHOO.ext.Animator animator`], [`Boolean selfCapture`])`
Create new Actor.
Parameters:

- `el` : String/HTMLElement
  The dom element or element id
- `animator` : YAHOO.ext.Animator
  (optional) The Animator that will capture this Actor's actions
- `selfCapture` : Boolean
  (optional) Whether this actor should capture it's own actions to support self playback without an animator (defaults to false)

## Method Details

### addAsyncCall

`public function addAsyncCall(`Function fcn`, `Number callbackIndex`, [`Array args`], [`Object scope`])`
Capture an async function call.
Parameters:

- `fcn` : Function
  The function to call
- `callbackIndex` : Number
  The index of the callback parameter on the passed function. A CALLBACK IS REQUIRED.
- `args` : Array
  The arguments to call the function with
- `scope` : Object
  (optional) The scope of the function

Returns:

- `void`

This method is defined by Actor.

### addCall

`public function addCall(`Function fcn`, [`Array args`], [`Object scope`])`
Capture a function call.
Parameters:

- `fcn` : Function
  The function to call
- `args` : Array
  (optional) The arguments to call the function with
- `scope` : Object
  (optional) The scope of the function

Returns:

- `void`

This method is defined by Actor.

### addClass

`public function addClass()`
Capturing override - See YAHOO.ext.Element.addClass for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### addClassOnOver

`public function addClassOnOver(`String className`)`
Sets up event handlers to add and remove a css class when the mouse is over this element
Parameters:

- `className` : String

Returns:

- `YAHOO.ext.Element`
  this

This method is defined by Element.

### addHandler

`public function addHandler(`String eventName`, `Boolean stopPropagation`, `Function handler`, [`Object scope`], [`boolean override`])`
Appends an event handler to this element. The difference between this function and addListener is this function prevents the default action, and if set stops propagation (bubbling) as well
Parameters:

- `eventName` : String
  The type of event to listen for
- `stopPropagation` : Boolean
  Whether to also stopPropagation (bubbling)
- `handler` : Function
  The method the event invokes
- `scope` : Object
  (optional) An arbitrary object that will be passed as a parameter to the handler
- `override` : boolean
  (optional) If true, the obj passed in becomes the execution scope of the listener

Returns:

- `YAHOO.ext.Element`
  this

This method is defined by Element.

### addKeyListener

`public function addKeyListener(`Number/Array/Object/String key`, `Function fn`, [`Object scope`])`
Convenience method for constructing a KeyMap
Parameters:

- `key` : Number/Array/Object/String
  Either a string with the keys to listen for, the numeric key code, array of key codes or an object with the following options: {key: (number or array), shift: (true/false), ctrl: (true/false), alt: (true/false)}
- `fn` : Function
  The function to call
- `scope` : Object
  (optional) The scope of the function

Returns:

- `YAHOO.ext.KeyMap`
  The KeyMap created

This method is defined by Element.

### addKeyMap

`public function addKeyMap(`Object config`)`
Creates a KeyMap for this element
Parameters:

- `config` : Object
  The KeyMap config. See YAHOO.ext.KeyMap for more details

Returns:

- `YAHOO.ext.KeyMap`
  The KeyMap created

This method is defined by Element.

### addListener

`public function addListener(`String eventName`, `Function handler`, [`Object scope`], [`boolean override`])`
Appends an event handler to this element
Parameters:

- `eventName` : String
  The type of event to listen for
- `handler` : Function
  The method the event invokes
- `scope` : Object
  (optional) An arbitrary object that will be passed as a parameter to the handler
- `override` : boolean
  (optional) If true, the obj passed in becomes the execution scope of the listener

Returns:

- `YAHOO.ext.Element`
  this

This method is defined by Element.

### addManagedListener

`public function addManagedListener(`String eventName`, `Function fn`, [`Object scope`], [`boolean override`])`
Append a managed listener - See YAHOO.ext.EventObject for more details. Use mon() for a shorter version.
Parameters:

- `eventName` : String
  The type of event to listen for
- `fn` : Function
  The method the event invokes
- `scope` : Object
  (optional) An arbitrary object that will be passed as a parameter to the handler
- `override` : boolean
  (optional) If true, the obj passed in becomes the execution scope of the listener

Returns:

- `Function`
  The EventManager wrapped function that can be used to remove the listener

This method is defined by Element.

### alignTo

`public function alignTo()`
Capturing and animation syncing override - See YAHOO.ext.Element.alignTo for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### animate

`public function animate()`
Capturing and animation syncing override - See YAHOO.ext.Element.animate for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### appear

`public function appear([`Float duration`])`
Fade an element in
Parameters:

- `duration` : Float
  (optional) How long the effect lasts (in seconds)

Returns:

- `void`

This method is defined by Actor.

### appendChild

`public function appendChild(`String/HTMLElement/Array/Element/CompositeElement el`)`
Appends the passed element(s) to this element
Parameters:

- `el` : String/HTMLElement/Array/Element/CompositeElement

Returns:

- `YAHOO.ext.Element`
  this

This method is defined by Element.

### appendTo

`public function appendTo(`String/HTMLElement/Element el`)`
Appends this element to the passed element
Parameters:

- `el` : String/HTMLElement/Element
  The new parent element

Returns:

- `YAHOO.ext.Element`
  this

This method is defined by Element.

### applyStyles

`public function applyStyles(`String/Object/Function styles`)`
More flexible version of setStyle for setting style properties.
Parameters:

- `styles` : String/Object/Function
  A style specification string eg "width:100px", or object in the form {width:"100px"}, or a function which returns such a specification.

Returns:

- `YAHOO.ext.Element`
  this

This method is defined by Element.

### autoHeight

`public function autoHeight()`
Capturing and animation syncing override - See YAHOO.ext.Element.autoHeight for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### beginMeasure

`public function beginMeasure()`
Temporarily enables offsets (width,height,x,y) for an element with display:none, use endMeasure() when done.
Parameters:

- None.

Returns:

- `YAHOO.ext.Element`
  this

This method is defined by Element.

### blindHide

`public function blindHide(`String anchor`, [`Float duration`], [`Function easing`])`
Hide the element using a "blinds" effect
Parameters:

- `anchor` : String
  The part of the element that it should appear to collapse to. The short/long options are t/top, l/left, b/bottom, r/right.
- `duration` : Float
  (optional) How long the effect lasts (in seconds)
- `easing` : Function
  (optional) YAHOO.util.Easing method to use. (Defaults to YAHOO.util.Easing.easeIn)

Returns:

- `void`

This method is defined by Actor.

### blindShow

`public function blindShow(`String anchor`, [`Number newSize`], [`Float duration`], [`Function easing`])`
Show the element using a "blinds" effect
Parameters:

- `anchor` : String
  The part of the element that it should appear to exapand from. The short/long options currently are t/top, l/left
- `newSize` : Number
  (optional) The size to animate to. (Default to current size)
- `duration` : Float
  (optional) How long the effect lasts (in seconds)
- `easing` : Function
  (optional) YAHOO.util.Easing method to use. (Defaults to YAHOO.util.Easing.easeOut)

Returns:

- `void`

This method is defined by Actor.

### blur

`public function blur()`
Tries to blur the element. Any exceptions are caught.
Parameters:

- None.

Returns:

- `YAHOO.ext.Element`
  this

This method is defined by Element.

### bounce

`public function bounce()`
Bounce this element from up and down
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### bufferedListener

`public function bufferedListener(`String eventName`, `Function handler`, [`Object scope`], [`Number millis`])`
Appends an event handler to this element that is buffered. If the event is triggered more than once in the specified time-frame, only the last one actually fires.
Parameters:

- `eventName` : String
  The type of event to listen for
- `handler` : Function
  The method the event invokes
- `scope` : Object
  (optional) The scope (this object) for the handler
- `millis` : Number
  (optional) The number of milliseconds to buffer (defaults to 250)

Returns:

- `Function`
  The wrapped function that was created (can be used to remove the listener)

This method is defined by Element.

### capture

`public function capture(`YAHOO.ext.Actor.Action action`)`
Captures an action for this actor. Generally called internally but can be called directly.
Parameters:

- `action` : YAHOO.ext.Actor.Action

Returns:

- `void`

This method is defined by Actor.

### center

`public function center([`String/HTMLElement/YAHOO.ext.Element centerIn`])`
Centers the Element in either the viewport, or another Element.
Parameters:

- `centerIn` : String/HTMLElement/YAHOO.ext.Element
  (optional) The element in which to center the element.

Returns:

- `void`

This method is defined by Element.

### clear

`public function clear()`
Clears any calls that have been self captured.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### clearOpacity

`public function clearOpacity()`
Capturing override - See YAHOO.ext.Element.clearOpacity for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### clearPositioning

`public function clearPositioning()`
Capturing override - See YAHOO.ext.Element.clearPositioning for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### clip

`public function clip()`
Capturing override - See YAHOO.ext.Element.clip for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### createChild

`public function createChild(`Object config`, [`HTMLElement insertBefore`])`
Creates the passed DomHelper config and appends it to this element or optionally inserts it before the passed child element.
Parameters:

- `config` : Object
  DomHelper element config object
- `insertBefore` : HTMLElement
  (optional) a child element of this element

Returns:

- `YAHOO.ext.Element`
  The new child element

This method is defined by Element.

### createProxy

`public function createProxy(`String/Object config`, [`String/HTMLElement renderTo`], [`Boolean matchBox`])`
Creates a proxy element of this element
Parameters:

- `config` : String/Object
  The class name of the proxy element or a DomHelper config object
- `renderTo` : String/HTMLElement
  (optional) The element or element id to render the proxy to (defaults to document.body)
- `matchBox` : Boolean
  (optional) True to align and size the proxy to this element now (defaults to false)

Returns:

- `YAHOO.ext.Element`
  The new proxy element

This method is defined by Element.

### createShim

`public function createShim()`
Creates an iframe shim for this element to keep selects and other windowed objects from showing through.
Parameters:

- None.

Returns:

- `YAHOO.ext.Element`
  The new shim element

This method is defined by Element.

### dropOut

`public function dropOut([`Float duration`])`
Fade the element as it is falling from it's current position
Parameters:

- `duration` : Float
  (optional) How long the effect lasts (in seconds)

Returns:

- `void`

This method is defined by Actor.

### enableDisplayMode

`public function enableDisplayMode()`
Capturing override - See YAHOO.ext.Element.enableDisplayMode for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### endMeasure

`public function endMeasure()`
Restores displays to before beginMeasure was called
Parameters:

- None.

Returns:

- `YAHOO.ext.Element`
  this

This method is defined by Element.

### fade

`public function fade([`Float duration`])`
Fade an element out
Parameters:

- `duration` : Float
  (optional) How long the effect lasts (in seconds)

Returns:

- `void`

This method is defined by Actor.

### fitToParent

`public function fitToParent([`Boolean monitorResize`])`
Sizes this element to it's parent element's dimensions performing neccessary box adjustments.
Parameters:

- `monitorResize` : Boolean
  (optional) If true maintains the fit when the browser window is resized.

Returns:

- `YAHOO.ext.Element`
  this

This method is defined by Element.

### focus

`public function focus()`
Capturing override - See YAHOO.ext.Element.focus for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### frame

`public function frame([`Number color`], [`Number count`], [`Float duration`])`
Show a ripple of exploding, attenuating borders to draw attention to an Element.
Parameters:

- `color` : Number
  (optional) The color of the border.
- `count` : Number
  (optional) How many ripples.
- `duration` : Float
  (optional) How long each ripple takes to expire

Returns:

- `void`

This method is defined by Actor.

### get<static>

`public function get<static>(`String/HTMLElement/Element el`, [`Boolean autoGenerateId`])`
<static> Static method to retreive Element objects. Uses simple caching to consistently return the same object. Automatically fixes if an object was recreated with the same id via AJAX or DOM.
Parameters:

- `el` : String/HTMLElement/Element
  The id of the element or the element to wrap (must have an id). If you pass in an element, it is returned
- `autoGenerateId` : Boolean
  (optional) Set this flag to true if you are passing an element without an id (like document.body). It will auto generate an id if one isn't present.

Returns:

- `Element`
  The element object

This method is defined by Element.

### getBorderWidth

`public function getBorderWidth(`String side`)`
Gets the width of the border(s) for the specified side(s)
Parameters:

- `side` : String
  Can be t, l, r, b or any combination of those to add multiple values. For example, passing lr would get the border (l)eft width + the border (r)ight width.

Returns:

- `Number`
  The width of the sides passed added together

This method is defined by Element.

### getBottom

`public function getBottom(`Boolean local`)`
Gets the bottom Y coordinate of the element (element Y position + element height)
Parameters:

- `local` : Boolean
  True to get the local css position instead of page coordinate

Returns:

- `Number`

This method is defined by Element.

### getBox

`public function getBox([`Boolean contentBox`], [`Boolean local`])`
Return a box {x, y, width, height} that can be used to set another elements size/location to match this element.
Parameters:

- `contentBox` : Boolean
  (optional) If true a box for the content of the element is returned.
- `local` : Boolean
  (optional) If true the element's left and top are returned instead of page x/y.

Returns:

- `Object`

This method is defined by Element.

### getCenterXY

`public function getCenterXY(`Boolean offsetScroll`)`
Calculates the x, y to center this element on the screen
Parameters:

- `offsetScroll` : Boolean
  True to offset the documents current scroll position

Returns:

- `Array`
  The x, y values [x, y]

This method is defined by Element.

### getChildrenByClassName

`public function getChildrenByClassName(`String className`, [`String tagName`])`
Gets an array of child YAHOO.ext.Element objects by class name and optional tagName
Parameters:

- `className` : String
- `tagName` : String
  (optional)

Returns:

- `Array`
  The children

This method is defined by Element.

### getChildrenByTagName

`public function getChildrenByTagName(`String tagName`)`
Gets an array of child YAHOO.ext.Element objects by tag name
Parameters:

- `tagName` : String

Returns:

- `Array`
  The children

This method is defined by Element.

### getHeight

`public function getHeight([`Boolean contentHeight`])`
Returns the offset height of the element
Parameters:

- `contentHeight` : Boolean
  (optional) true to get the height minus borders and padding

Returns:

- `Number`
  The element's height

This method is defined by Element.

### getLeft

`public function getLeft(`Boolean local`)`
Gets the left X coordinate
Parameters:

- `local` : Boolean
  True to get the local css position instead of page coordinate

Returns:

- `Number`

This method is defined by Element.

### getMargins

`public function getMargins([`String sides`])`
Returns an object with properties top, left, right and bottom representing the margins of this element unless sides is passed, then it returns the calculated width of the sides (see getPadding)
Parameters:

- `sides` : String
  (optional) Any combination of l, r, t, b to get the sum of those sides

Returns:

- `Object/Number`

This method is defined by Element.

### getNextSibling

`public function getNextSibling()`
Gets the next sibling, skipping text nodes
Parameters:

- None.

Returns:

- `HTMLElement`
  The next sibling or null

This method is defined by Element.

### getPadding

`public function getPadding(`String side`)`
Gets the width of the padding(s) for the specified side(s)
Parameters:

- `side` : String
  Can be t, l, r, b or any combination of those to add multiple values. For example, passing lr would get the padding (l)eft + the padding (r)ight.

Returns:

- `Number`
  The padding of the sides passed added together

This method is defined by Element.

### getPositioning

`public function getPositioning()`
Gets an object with all CSS positioning properties. Useful along with setPostioning to get snapshot before performing an update and then restoring the element.
Parameters:

- None.

Returns:

- `Object`

This method is defined by Element.

### getPrevSibling

`public function getPrevSibling()`
Gets the previous sibling, skipping text nodes
Parameters:

- None.

Returns:

- `HTMLElement`
  The previous sibling or null

This method is defined by Element.

### getRegion

`public function getRegion()`
Returns the region of the given element. The element must be part of the DOM tree to have a region (display:none or elements not appended return false).
Parameters:

- None.

Returns:

- `Region`
  A YAHOO.util.Region containing "top, left, bottom, right" member data.

This method is defined by Element.

### getRight

`public function getRight(`Boolean local`)`
Gets the right X coordinate of the element (element X position + element width)
Parameters:

- `local` : Boolean
  True to get the local css position instead of page coordinate

Returns:

- `Number`

This method is defined by Element.

### getSize

`public function getSize([`Boolean contentSize`])`
Returns the size of the element
Parameters:

- `contentSize` : Boolean
  (optional) true to get the width/size minus borders and padding

Returns:

- `Object`
  An object containing the element's size {width: (element width), height: (element height)}

This method is defined by Element.

### getStyle

`public function getStyle(`String property`)`
Normalizes currentStyle and ComputedStyle.
Parameters:

- `property` : String
  The style property whose value is returned.

Returns:

- `String`
  The current value of the style property for this element.

This method is defined by Element.

### getTop

`public function getTop(`Boolean local`)`
Gets the top Y coordinate
Parameters:

- `local` : Boolean
  True to get the local css position instead of page coordinate

Returns:

- `Number`

This method is defined by Element.

### getUpdateManager

`public function getUpdateManager()`
Gets this elements UpdateManager
Parameters:

- None.

Returns:

- `YAHOO.ext.UpdateManager`
  The UpdateManager

This method is defined by Element.

### getWidth

`public function getWidth([`Boolean contentWidth`])`
Returns the offset width of the element
Parameters:

- `contentWidth` : Boolean
  (optional) true to get the width minus borders and padding

Returns:

- `Number`
  The element's width

This method is defined by Element.

### getX

`public function getX()`
Gets the current X position of the element based on page coordinates. Element must be part of the DOM tree to have page coordinates (display:none or elements not appended return false). @ return {Number} The X position of the element
Parameters:

- None.

Returns:

- `void`

This method is defined by Element.

### getXY

`public function getXY()`
Gets the current position of the element based on page coordinates. Element must be part of the DOM tree to have page coordinates (display:none or elements not appended return false). @ return {Array} The XY position of the element
Parameters:

- None.

Returns:

- `void`

This method is defined by Element.

### getY

`public function getY()`
Gets the current Y position of the element based on page coordinates. Element must be part of the DOM tree to have page coordinates (display:none or elements not appended return false). @ return {Number} The Y position of the element
Parameters:

- None.

Returns:

- `void`

This method is defined by Element.

### hasClass

`public function hasClass(`String className`)`
Checks if a CSS class is in use by the element.
Parameters:

- `className` : String
  The CSS class to check

Returns:

- `Boolean`
  true or false

This method is defined by Element.

### hide

`public function hide()`
Capturing and animation syncing override - See YAHOO.ext.Element.hide for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### highlight

`public function highlight([`String color`], [`String fromColor`], [`Float duration`], [`String attribute`])`
Highlight the element using a background color (or passed attribute) animation
Parameters:

- `color` : String
  (optional) The color to use for the highlight
- `fromColor` : String
  (optional) If the element does not currently have a background color, you will need to pass in a color to animate from
- `duration` : Float
  (optional) How long the effect lasts (in seconds)
- `attribute` : String
  (optional) Specify a CSS attribute to use other than background color - camelCase

Returns:

- `void`

This method is defined by Actor.

### initDD

`public function initDD(`String group`, `Object config`, `Object overrides`)`
Initializes a YAHOO.util.DD object for this element.
Parameters:

- `group` : String
  The group the DD object is member of
- `config` : Object
  The DD config object
- `overrides` : Object
  An object containing methods to override/implement on the DD object

Returns:

- `YAHOO.util.DD`
  The DD object

This method is defined by Element.

### initDDProxy

`public function initDDProxy(`String group`, `Object config`, `Object overrides`)`
Initializes a YAHOO.util.DDProxy object for this element.
Parameters:

- `group` : String
  The group the DDProxy object is member of
- `config` : Object
  The DDProxy config object
- `overrides` : Object
  An object containing methods to override/implement on the DDProxy object

Returns:

- `YAHOO.util.DDProxy`
  The DDProxy object

This method is defined by Element.

### initDDTarget

`public function initDDTarget(`String group`, `Object config`, `Object overrides`)`
Initializes a YAHOO.util.DDTarget object for this element.
Parameters:

- `group` : String
  The group the DDTarget object is member of
- `config` : Object
  The DDTarget config object
- `overrides` : Object
  An object containing methods to override/implement on the DDTarget object

Returns:

- `YAHOO.util.DDTarget`
  The DDTarget object

This method is defined by Element.

### insertAfter

`public function insertAfter(`String/HTMLElement/Element el`)`
Inserts this element after the passed element in the DOM
Parameters:

- `el` : String/HTMLElement/Element
  The element to insert after

Returns:

- `YAHOO.ext.Element`
  this

This method is defined by Element.

### insertBefore

`public function insertBefore(`String/HTMLElement/Element el`)`
Inserts this element before the passed element in the DOM
Parameters:

- `el` : String/HTMLElement/Element
  The element to insert before

Returns:

- `YAHOO.ext.Element`
  this

This method is defined by Element.

### insertHtml

`public function insertHtml(`String where`, `String html`)`
Inserts an html fragment into this element
Parameters:

- `where` : String
  Where to insert the html in relation to the this element - beforeBegin, afterBegin, beforeEnd, afterEnd.
- `html` : String
  The HTML fragment

Returns:

- `YAHOO.ext.Element`
  this

This method is defined by Element.

### isBorderBox

`public function isBorderBox()`
Tests various css rules/browsers to determine if this element uses a border box
Parameters:

- None.

Returns:

- `Boolean`

This method is defined by Element.

### isDisplayed

`public function isDisplayed()`
Returns true if display is not "none"
Parameters:

- None.

Returns:

- `Boolean`

This method is defined by Element.

### isVisible

`public function isVisible([`Boolean deep`])`
Checks whether the element is currently visible using both visibility and display properties.
Parameters:

- `deep` : Boolean
  True to walk the dom and see if parent elements are hidden.

Returns:

- `Boolean`
  true if the element is currently visible

This method is defined by Element.

### load

`public function load()`
Capturing and animation syncing override - See YAHOO.ext.Element.load for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### mon

`public function mon(`String eventName`, `Function fn`, [`Object scope`], [`boolean override`])`
Append a managed listener (shorthanded for addManagedListener)
Parameters:

- `eventName` : String
  The type of event to listen for
- `fn` : Function
  The method the event invokes
- `scope` : Object
  (optional) An arbitrary object that will be passed as a parameter to the handler
- `override` : boolean
  (optional) If true, the obj passed in becomes the execution scope of the listener

Returns:

- `Function`
  The EventManager wrapped function that can be used to remove the listener

This method is defined by Element.

### move

`public function move()`
Capturing and animation syncing override - See YAHOO.ext.Element.move for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### moveIn

`public function moveIn(`String anchor`, [`Array to`], [`Float duration`], [`Function easing`])`
Show the element in a way that it appears as if it is flying onto the screen
Parameters:

- `anchor` : String
  The part of the page that the element should appear to move from. The short/long options are t/top, l/left, b/bottom, r/right, tl/top-left, tr/top-right, bl/bottom-left or br/bottom-right.
- `to` : Array
  (optional) Array of x and y position to move to like [x, y] (Defaults to center screen)
- `duration` : Float
  (optional) How long the effect lasts (in seconds)
- `easing` : Function
  (optional) YAHOO.util.Easing method to use. (Defaults to YAHOO.util.Easing.easeOut)

Returns:

- `void`

This method is defined by Actor.

### moveOut

`public function moveOut(`String anchor`, [`Float duration`], [`Function easing`])`
Hide the element in a way that it appears as if it is flying off the screen
Parameters:

- `anchor` : String
  The part of the page that the element should appear to move to. The short/long options are t/top, l/left, b/bottom, r/right, tl/top-left, tr/top-right, bl/bottom-left or br/bottom-right.
- `duration` : Float
  (optional) How long the effect lasts (in seconds)
- `easing` : Function
  (optional) YAHOO.util.Easing method to use. (Defaults to YAHOO.util.Easing.easeIn)

Returns:

- `void`

This method is defined by Actor.

### moveTo

`public function moveTo()`
Capturing and animation syncing override - See YAHOO.ext.Element.moveTo for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### on

`public function on(`String eventName`, `Function handler`, [`Object scope`], [`boolean override`])`
Appends an event handler to this element (Same as addListener)
Parameters:

- `eventName` : String
  The type of event to listen for
- `handler` : Function
  The method the event invokes
- `scope` : Object
  (optional) An arbitrary object that will be passed as a parameter to the handler
- `override` : boolean
  (optional) If true, the obj passed in becomes the execution scope of the listener

Returns:

- `YAHOO.ext.Element`
  this

This method is defined by Element.

### pause

`public function pause(`Number seconds`)`
Capture a pause (in seconds).
Parameters:

- `seconds` : Number
  The seconds to pause

Returns:

- `void`

This method is defined by Actor.

### play

`public function play([`Function oncomplete`])`
Starts playback of self captured calls.
Parameters:

- `oncomplete` : Function
  (optional) Callback to execute when playback has completed

Returns:

- `void`

This method is defined by Actor.

### pulsate

`public function pulsate([`Number count`], [`Float duration`])`
Fade the element in and out the specified amount of times
Parameters:

- `count` : Number
  (optional) How many times to pulse (Defaults to 3)
- `duration` : Float
  (optional) How long the effect lasts (in seconds)

Returns:

- `void`

This method is defined by Actor.

### radioClass

`public function radioClass(`String className`)`
Adds the passed className to this element and removes the class from all siblings
Parameters:

- `className` : String
  The className to add

Returns:

- `YAHOO.ext.Element`
  this

This method is defined by Element.

### remove

`public function remove()`
Capturing override - See YAHOO.ext.Element.remove for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### removeAllListeners

`public function removeAllListeners()`
Removes all previous added listeners from this element
Parameters:

- None.

Returns:

- `YAHOO.ext.Element`
  this

This method is defined by Element.

### removeClass

`public function removeClass()`
Capturing override - See YAHOO.ext.Element.removeClass for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### removeListener

`public function removeListener(`String sType`, `Function fn`, `Object scope`)`
Removes an event handler from this element
Parameters:

- `sType` : String
  the type of event to remove
- `fn` : Function
  the method the event invokes
- `scope` : Object

Returns:

- `YAHOO.ext.Element`
  this

This method is defined by Element.

### repaint

`public function repaint()`
Forces the browser to repaint this element
Parameters:

- None.

Returns:

- `YAHOO.ext.Element`
  this

This method is defined by Element.

### replace

`public function replace(`String/HTMLElement/Element el`)`
Replaces the passed element with this element
Parameters:

- `el` : String/HTMLElement/Element
  The element to replace

Returns:

- `YAHOO.ext.Element`
  this

This method is defined by Element.

### replaceClass

`public function replaceClass()`
Capturing override - See YAHOO.ext.Element.replaceClass for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### scrollIntoView

`public function scrollIntoView([`String/HTMLElement/Element container`])`
Scrolls this element into view within the passed container.
Parameters:

- `container` : String/HTMLElement/Element
  (optional) The container element to scroll (defaults to document.body)

Returns:

- `YAHOO.ext.Element`
  this

This method is defined by Element.

### select

`public function select(`String selector`, `Boolean unique`)`
Selects child nodes based on the passed CSS selector (the selector should not contain an id)
Parameters:

- `selector` : String
  The CSS selector
- `unique` : Boolean
  true to create a unique YAHOO.ext.Element for each child (defaults to a shared flyweight object)

Returns:

- `CompositeElement/CompositeElementLite`
  The composite element

This method is defined by Element.

### select<static>

`public function select<static>(`String/Array selector`, [`Boolean unique`])`
<static> Selects elements based on the passed CSS selector to enable working on them as 1.
Parameters:

- `selector` : String/Array
  The CSS selector or an array of elements
- `unique` : Boolean
  (optional) true to create a unique YAHOO.ext.Element for each element (defaults to a shared flyweight object)

Returns:

- `CompositeElementLite/CompositeElement`

This method is defined by Element.

### set

`public function set(`Object o`)`
Sets the passed attributes as attributes of this element (a style attribute can be a string, object or function)
Parameters:

- `o` : Object
  The object with the attributes

Returns:

- `YAHOO.ext.Element`
  this

This method is defined by Element.

### setAbsolutePositioned

`public function setAbsolutePositioned()`
Capturing override - See YAHOO.ext.Element.setAbsolutePositioned for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### setBottom

`public function setBottom(`String bottom`)`
Set the element's css bottom style
Parameters:

- `bottom` : String
  The bottom CSS property value

Returns:

- `YAHOO.ext.Element`
  this

This method is defined by Element.

### setBounds

`public function setBounds()`
Capturing and animation syncing override - See YAHOO.ext.Element.setBounds for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### setBox

`public function setBox()`
Capturing and animation syncing override - See YAHOO.ext.Element.setBox for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### setDisplayed

`public function setDisplayed(`Boolean value`)`
Sets the css display. Uses originalDisplay if value is a boolean true.
Parameters:

- `value` : Boolean
  Boolean to display the element using it's default display or a string to set the display directly

Returns:

- `YAHOO.ext.Element`
  this

This method is defined by Element.

### setHeight

`public function setHeight()`
Capturing and animation syncing override - See YAHOO.ext.Element.setHeight for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### setLeft

`public function setLeft()`
Capturing override - See YAHOO.ext.Element.setLeft for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### setLeftTop

`public function setLeftTop()`
Quick set left and top adding default units
Parameters:

- None.

Returns:

- `YAHOO.ext.Element`
  this

This method is defined by Element.

### setLocation

`public function setLocation()`
Capturing and animation syncing override - See YAHOO.ext.Element.setLocation for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### setOpacity

`public function setOpacity()`
Capturing and animation syncing override - See YAHOO.ext.Element.setOpacity for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### setPositioning

`public function setPositioning()`
Capturing override - See YAHOO.ext.Element.setPositioning for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### setRegion

`public function setRegion(`YAHOO.util.Region region`, [`Boolean animate`], [`float duration`], [`Function onComplete`], [`Function easing`])`
Sets the element's position and size the the specified region. If animation is true then width, height, x and y will be animated concurrently.
Parameters:

- `region` : YAHOO.util.Region
  The region to fill
- `animate` : Boolean
  (optional) Animate the transition (Default is false)
- `duration` : float
  (optional) How long the animation lasts. (Defaults to .35 seconds)
- `onComplete` : Function
  (optional) Function to call when animation completes.
- `easing` : Function
  (optional) YAHOO.util.Easing method to use. (Defaults to YAHOO.util.Easing.easeBoth)

Returns:

- `YAHOO.ext.Element`
  this

This method is defined by Element.

### setRelativePositioned

`public function setRelativePositioned()`
Capturing override - See YAHOO.ext.Element.setRelativePositioned for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### setRight

`public function setRight(`String right`)`
Set the element's css right style
Parameters:

- `right` : String
  The right CSS property value

Returns:

- `YAHOO.ext.Element`
  this

This method is defined by Element.

### setSize

`public function setSize()`
Capturing and animation syncing override - See YAHOO.ext.Element.setSize for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### setStyle

`public function setStyle()`
Capturing override - See YAHOO.ext.Element.setStyle for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### setTop

`public function setTop()`
Capturing override - See YAHOO.ext.Element.setTop for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### setVisibilityMode

`public function setVisibilityMode()`
Capturing override - See YAHOO.ext.Element.setVisibilityMode for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### setVisible

`public function setVisible()`
Capturing and animation syncing override - See YAHOO.ext.Element.setVisible for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### setWidth

`public function setWidth()`
Capturing and animation syncing override - See YAHOO.ext.Element.setWidth for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### setX

`public function setX()`
Capturing override - See YAHOO.ext.Element.setX for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### setXY

`public function setXY()`
Capturing and animation syncing override - See YAHOO.ext.Element.setXY for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### setY

`public function setY()`
Capturing override - See YAHOO.ext.Element.setY for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### shake

`public function shake()`
Shake this element from side to side
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### show

`public function show()`
Capturing and animation syncing override - See YAHOO.ext.Element.show for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### slideHide

`public function slideHide(`String anchor`, [`Float duration`], [`Function easing`])`
Hide the element using a "slide in" effect - In order for this effect to work the element MUST have a child element container that can be "slid" otherwise a blindHide effect is rendered.
Parameters:

- `anchor` : String
  The part of the element that it should appear to slide to. The short/long options are t/top, l/left, b/bottom, r/right.
- `duration` : Float
  (optional) How long the effect lasts (in seconds)
- `easing` : Function
  (optional) YAHOO.util.Easing method to use. (Defaults to YAHOO.util.Easing.easeIn)

Returns:

- `void`

This method is defined by Actor.

### slideShow

`public function slideShow(`String anchor`, [`Number newSize`], [`Float duration`], [`Function easing`])`
Show the element using a "slide in" effect - In order for this effect to work the element MUST have a child element container that can be "slid" otherwise a blindShow effect is rendered.
Parameters:

- `anchor` : String
  The part of the element that it should appear to slide from. The short/long options currently are t/top, l/left
- `newSize` : Number
  (optional) The size to animate to. (Default to current size)
- `duration` : Float
  (optional) How long the effect lasts (in seconds)
- `easing` : Function
  (optional) YAHOO.util.Easing method to use. (Defaults to YAHOO.util.Easing.easeOuth)

Returns:

- `void`

This method is defined by Actor.

### squish

`public function squish([`Float duration`])`
Hide the element by "squishing" it into the corner
Parameters:

- `duration` : Float
  (optional) How long the effect lasts (in seconds)

Returns:

- `void`

This method is defined by Actor.

### startCapture

`public function startCapture()`
Start self capturing calls on this Actor. All subsequent calls are captured and executed when play() is called.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### stopCapture

`public function stopCapture()`
Stop self capturing calls on this Actor.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### swallowEvent

`public function swallowEvent(`String eventName`, [`Boolean preventDefault`])`
Stops the specified event from bubbling and optionally prevent's the default action
Parameters:

- `eventName` : String
- `preventDefault` : Boolean
  (optional) true to prevent the default action too

Returns:

- `YAHOO.ext.Element`
  this

This method is defined by Element.

### switchOff

`public function switchOff([`Float duration`])`
Blink the element as if it was clicked and then collapse on it's center
Parameters:

- `duration` : Float
  (optional) How long the effect lasts (in seconds)

Returns:

- `void`

This method is defined by Actor.

### toggle

`public function toggle()`
Capturing and animation syncing override - See YAHOO.ext.Element.toggle for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### toggleClass

`public function toggleClass(`String className`)`
Toggles (adds or removes) the passed class.
Parameters:

- `className` : String

Returns:

- `YAHOO.ext.Element`
  this

This method is defined by Element.

### unclip

`public function unclip()`
Capturing override - See YAHOO.ext.Element.unclip for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### unselectable

`public function unselectable()`
Disables text selection for this element (normalized across browsers)
Parameters:

- None.

Returns:

- `YAHOO.ext.Element`
  this

This method is defined by Element.

### update

`public function update()`
Capturing override - See YAHOO.ext.Element.update for method details.
Parameters:

- None.

Returns:

- `void`

This method is defined by Actor.

### wrap

`public function wrap([`Object config`])`
Creates and wraps this element with another element
Parameters:

- `config` : Object
  (optional) DomHelper element config object for the wrapper element or null for an empty div

Returns:

- `Element`
  The newly created wrapper element

This method is defined by Element.

yui-ext - Copyright © 2006 Jack Slocum. | Yahoo! UI - Copyright © 2006 Yahoo! Inc.
All rights reserved.