Home

# Class goog.graphics.ext.Element

Base class for a wrapper around the goog.graphics wrapper that enables more advanced functionality.

extends goog.events.EventTarget

Instance Method Summary
| `computeIsParentDependent_(?goog.graphics.ext.Element.Position_ position)` Computes whether the element is still parent dependent.

`disposeInternal()`

Unattach listeners from this object. Classes that extend EventTarget may need to override this method in order to remove references to DOM Elements and additional listeners, it should be something like this:

    MyClass.prototype.disposeInternal = function() {
    MyClass.superClass_.disposeInternal.call(this);
    // Dispose logic for MyClass
    };

| `getBottom() ⇒ number`
| `getCenter() ⇒ number`
| `getGraphics() ⇒ (goog.graphics.ext.Element|goog.graphics.ext.Graphics|null)`
| `getGraphicsImplementation() ⇒ ?goog.graphics.AbstractGraphics` Returns the graphics implementation.
| `getHeight() ⇒ number`
| `getLeft() ⇒ number`
| `getMaxX() ⇒ number`
| `getMaxY() ⇒ number`
| `getMiddle() ⇒ number`
| `getMinHeight() ⇒ number`
| `getMinWidth() ⇒ number`
| `getParent() ⇒ (goog.graphics.ext.Group|null|undefined)`
| `getPixelScaleX() ⇒ number`
| `getPixelScaleY() ⇒ number`
| `getRight() ⇒ number`
| `getRotation() ⇒ number`
| `getTop() ⇒ number`
| `getWidth() ⇒ number`
| `getWrapper() ⇒ ?goog.graphics.Element`
| `isParentDependent() ⇒ boolean` Returns whether this element's bounds depend on its parents. This function should be treated as if it has package scope.
| `isPendingTransform() ⇒ boolean`
| `parentTransform()` Called by the parent when the parent has transformed. Should be treated as package scope.
| `redraw()` Overridable function for subclass specific reset.
| `reset()` Reset the element. This is called when the element changes size, or when the coordinate system changes in a way that would affect pixel based rendering
| `setBottom((number|string) bottom, boolean= opt_chain)` Sets the bottom coordinate of the element. Overwrites any previous value of top, middle, or bottom for this element.
| `setBounds((number|string) left, (number|string) top, (number|string) width, (number|string) height, boolean= opt_chain)` Shortcut for setting the left, top, width, and height.
| `setCenter((number|string) center, boolean= opt_chain)` Sets the center coordinate of the element. Overwrites any previous value of left, center, or right for this element.
| `setHeight((number|string) height, boolean= opt_chain)` Sets the height of the element.
| `setLeft((number|string) left, boolean= opt_chain)` Sets the left coordinate of the element. Overwrites any previous value of left, center, or right for this element.
| `setMiddle((number|string) middle, boolean= opt_chain)` Sets the middle coordinate of the element. Overwrites any previous value of top, middle, or bottom for this element
| `setMinHeight((number|string) minHeight)` Sets the minimum height of the element.
| `setMinSize_(?goog.graphics.ext.Element.Position_ position, (number|string) minSize)` Sets the minimum width/height of the element.
| `setMinWidth((number|string) minWidth)` Sets the minimum width of the element.
| `setPosition((number|string) left, (number|string) top, boolean= opt_chain)` Shortcut for setting the left and top position.
| `setPosition_(?goog.graphics.ext.Element.Position_ position, (number|string) value, ?goog.graphics.ext.Element.PositionType_ type, boolean= opt_chain)` Internal convenience method for setting position - either as a left/top, center/middle, or right/bottom value. Only one should be specified.
| `setRight((number|string) right, boolean= opt_chain)` Sets the right coordinate of the element. Overwrites any previous value of left, center, or right for this element.
| `setRotation(number angle)` Set the rotation of this element.
| `setSize((number|string) width, (number|string) height, boolean= opt_chain)` Shortcut for setting the width and height.
| `setSize_(?goog.graphics.ext.Element.Position_ position, (number|string) size, boolean= opt_chain)` Sets the width/height of the element.
| `setTop((number|string) top, boolean= opt_chain)` Sets the top coordinate of the element. Overwrites any previous value of top, middle, or bottom for this element.
| `setWidth((number|string) width, boolean= opt_chain)` Sets the width of the element.
| `transform()` Performs a pending transform.

Static Method Summary
| `Position_(?goog.graphics.ext.Element element, boolean horizontal)` Manages a position and size, either horizontal or vertical.