public class Image extends Image implements IsResponsive, HasStyle, HasType<ImageType>
UIObject.DebugIdImpl, UIObject.DebugIdImplEnabled
DEBUG_ID_PREFIX
Constructor and Description |
---|
Image()
Creates an empty image.
|
Image(ImageResource resource)
Creates an image whose size and content are defined by an ImageResource.
|
Image(SafeUri url)
Creates an image with a specified URL.
|
Image(SafeUri url,
int left,
int top,
int width,
int height)
Creates a clipped image with a specified URL and visibility rectangle.
|
Image(String url)
Creates an image with a specified URL.
|
Image(String url,
int left,
int top,
int width,
int height)
Creates a clipped image with a specified URL and visibility rectangle.
|
Modifier and Type | Method and Description |
---|---|
void |
addStyle(Style style)
Adds the provided style to the widget.
|
void |
removeStyle(Style style)
Removes the provided style from the widget.
|
void |
setHideOn(Device device)
Sets the kind of device, this widget is hidden on.
|
void |
setShowOn(Device device)
Sets the kind of device, this widget is shown on.
|
void |
setStyle(Style style)
Replaces the widet's style with the provided one.
|
void |
setType(ImageType style)
Sets the type of the widget.
|
addClickHandler, addClickListener, addDoubleClickHandler, addDragEndHandler, addDragEnterHandler, addDragHandler, addDragLeaveHandler, addDragOverHandler, addDragStartHandler, addDropHandler, addErrorHandler, addGestureChangeHandler, addGestureEndHandler, addGestureStartHandler, addLoadHandler, addLoadListener, addMouseDownHandler, addMouseListener, addMouseMoveHandler, addMouseOutHandler, addMouseOverHandler, addMouseUpHandler, addMouseWheelHandler, addMouseWheelListener, addTouchCancelHandler, addTouchEndHandler, addTouchMoveHandler, addTouchStartHandler, getAltText, getHeight, getOriginLeft, getOriginTop, getUrl, getWidth, onBrowserEvent, onLoad, prefetch, prefetch, removeClickListener, removeLoadListener, removeMouseListener, removeMouseWheelListener, setAltText, setResource, setUrl, setUrl, setUrlAndVisibleRect, setUrlAndVisibleRect, setVisibleRect, wrap
addAttachHandler, addBitlessDomHandler, addDomHandler, addHandler, asWidget, asWidgetOrNull, createHandlerManager, delegateEvent, doAttachChildren, doDetachChildren, fireEvent, getHandlerCount, getLayoutData, getParent, isAttached, isOrWasAttached, onAttach, onDetach, onUnload, removeFromParent, setLayoutData, sinkEvents
addStyleDependentName, addStyleName, ensureDebugId, ensureDebugId, ensureDebugId, getAbsoluteLeft, getAbsoluteTop, getElement, getOffsetHeight, getOffsetWidth, getStyleElement, getStyleName, getStyleName, getStylePrimaryName, getStylePrimaryName, getTitle, isVisible, isVisible, onEnsureDebugId, removeStyleDependentName, removeStyleName, resolvePotentialElement, setElement, setElement, setHeight, setPixelSize, setSize, setStyleDependentName, setStyleName, setStyleName, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setTitle, setVisible, setVisible, setWidth, sinkBitlessEvent, toString, unsinkEvents
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
fireEvent
public Image()
public Image(ImageResource resource)
resource
- the ImageResource to be displayedpublic Image(SafeUri url, int left, int top, int width, int height)
url
- the URL of the image to be displayedleft
- the horizontal co-ordinate of the upper-left vertex of the
visibility rectangletop
- the vertical co-ordinate of the upper-left vertex of the
visibility rectanglewidth
- the width of the visibility rectangleheight
- the height of the visibility rectanglepublic Image(SafeUri url)
url
- the URL of the image to be displayedpublic Image(String url, int left, int top, int width, int height)
url
- the URL of the image to be displayedleft
- the horizontal co-ordinate of the upper-left vertex of the
visibility rectangletop
- the vertical co-ordinate of the upper-left vertex of the
visibility rectanglewidth
- the width of the visibility rectangleheight
- the height of the visibility rectanglepublic void setShowOn(Device device)
The widget is not shown on any other device.
Only works if responsive design is turned on!
setShowOn
in interface IsResponsive
Configurator.hasResponsiveDesign()
,
IsResponsive.setHideOn(Device)
public void setHideOn(Device device)
The widget is not hidden on any other device.
Only works if responsive design is turned on!
setHideOn
in interface IsResponsive
Configurator.hasResponsiveDesign()
,
IsResponsive.setShowOn(Device)
public void removeStyle(Style style)
removeStyle
in interface HasStyle
style
- the style to be removed from the Widget.Copyright © 2012-2014 gwtbootstrap. All Rights Reserved.