Class Img
- java.lang.Object
-
- org.pepstock.charba.client.dom.BaseEventTarget
-
- org.pepstock.charba.client.dom.BaseNode
-
- org.pepstock.charba.client.dom.BaseElement
-
- org.pepstock.charba.client.dom.BaseHtmlElement
-
- org.pepstock.charba.client.dom.elements.Img
-
- All Implemented Interfaces:
IsJSType
,IsCastable
@JsType(isNative=true, name="HTMLImageElement", namespace="<global>") public final class Img extends BaseHtmlElement implements IsCastable
Represents an HTML <img> element, providing the properties and methods used to manipulate image elements.- Author:
- Andrea "Stock" Stocchero
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.pepstock.charba.client.dom.BaseEventTarget
BaseEventTarget.EventListenerCallback
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
getHeight()
Returns the value that reflects the height attribute, indicating the rendered height of the image in CSS pixels.String
getSrc()
Returns the full URL of the image including base URI.int
getWidth()
Returns the value that reflects the width attribute, indicating the rendered width of the image in CSS pixels.void
setHeight(int height)
Sets the value that reflects the height attribute, indicating the rendered height of the image in CSS pixels.void
setSrc(String src)
Sets the full URL of the image including base URI.void
setWidth(int width)
Sets the value that reflects the width attribute, indicating the rendered width of the image in CSS pixels.-
Methods inherited from class org.pepstock.charba.client.dom.BaseHtmlElement
blur, focus, getAbsoluteLeft, getAbsoluteTop, getInnerText, getOffsetHeight, getOffsetLeft, getOffsetParent, getOffsetTop, getOffsetWidth, getParentHtmlElement, getScrollingElement, getStyle, getTabIndex, removeFromParent, setInnerText, setTabIndex
-
Methods inherited from class org.pepstock.charba.client.dom.BaseElement
getAttributes, getBoundingClientRect, getChildElementCount, getClientHeight, getClientLeft, getClientTop, getClientWidth, getElementsByTagName, getFirstElementChild, getId, getInnerHTML, getLastElementChild, getNextElementSibling, getOuterHTML, getPreviousElementSibling, getScrollHeight, getScrollLeft, getScrollTop, getScrollWidth, getTagName, hasAttributes, hasPointerCapture, releasePointerCapture, remove, setId, setInnerHTML, setPointerCapture
-
Methods inherited from class org.pepstock.charba.client.dom.BaseNode
appendChild, cloneNode, getChildNodes, getFirstChild, getLastChild, getNextSibling, getNodeName, getNodeType, getNodeValue, getOwnerDocument, getParentElement, getParentNode, getPreviousSibling, getTextContent, hasChildNodes, insertBefore, removeAllChildren, removeChild, setNodeValue, setTextContent
-
Methods inherited from class org.pepstock.charba.client.dom.BaseEventTarget
addEventListener, addEventListener, dispatchEvent, dispatchEvent, removeEventListener, removeEventListener
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.pepstock.charba.client.dom.IsCastable
as
-
-
-
-
Field Detail
-
TAG
@JsOverlay public static final String TAG
The tag for this element.- See Also:
- Constant Field Values
-
-
Method Detail
-
getHeight
@JsProperty public int getHeight()
Returns the value that reflects the height attribute, indicating the rendered height of the image in CSS pixels.- Returns:
- the value that reflects the height attribute
-
setHeight
@JsProperty public void setHeight(int height)
Sets the value that reflects the height attribute, indicating the rendered height of the image in CSS pixels.- Parameters:
height
- the value that reflects the height attribute
-
getSrc
@JsProperty public String getSrc()
Returns the full URL of the image including base URI.- Returns:
- the full URL of the image including base URI
-
setSrc
@JsProperty public void setSrc(String src)
Sets the full URL of the image including base URI.- Parameters:
src
- the full URL of the image including base URI
-
getWidth
@JsProperty public int getWidth()
Returns the value that reflects the width attribute, indicating the rendered width of the image in CSS pixels.- Returns:
- the value that reflects the width attribute
-
setWidth
@JsProperty public void setWidth(int width)
Sets the value that reflects the width attribute, indicating the rendered width of the image in CSS pixels.- Parameters:
width
- the value that reflects the width attribute
-
-