org.gwtwidgets.client.ui
Class PNGImage

java.lang.Object
  extended by com.google.gwt.user.client.ui.UIObject
      extended by com.google.gwt.user.client.ui.Widget
          extended by com.google.gwt.user.client.ui.Image
              extended by org.gwtwidgets.client.ui.PNGImage
All Implemented Interfaces:
com.google.gwt.user.client.EventListener, com.google.gwt.user.client.ui.SourcesClickEvents, com.google.gwt.user.client.ui.SourcesLoadEvents, com.google.gwt.user.client.ui.SourcesMouseEvents
Direct Known Subclasses:
ImageButton

public class PNGImage
extends com.google.gwt.user.client.ui.Image

Image widget that overcomes PNG browser incompatabilities. Although meant for PNG images, it will work with any image format supported by the browser. If the image file ends with ".png" or ".PNG" it will use the PNG specific routines, otherwise will use generic non-PNG specific routines. The URL, width, and height are required at the creation of the widget, and may not be updated via the widget methogs. Calling setUrl() will throw a RuntimeException. This is in part due to the workarounds required for IE 5.5 and IE6.

Author:
rhanson

Constructor Summary
PNGImage(java.lang.String url, int width, int height)
           
 
Method Summary
 java.lang.String getUrl()
           
 void setUrl(java.lang.String url)
          Should not be used.
 
Methods inherited from class com.google.gwt.user.client.ui.Image
addClickListener, addLoadListener, addMouseListener, onBrowserEvent, prefetch, removeClickListener, removeLoadListener, removeMouseListener
 
Methods inherited from class com.google.gwt.user.client.ui.Widget
getParent, isAttached, onAttach, onDetach, onLoad, removeFromParent
 
Methods inherited from class com.google.gwt.user.client.ui.UIObject
addStyleName, getAbsoluteLeft, getAbsoluteTop, getElement, getOffsetHeight, getOffsetWidth, getStyleName, getTitle, isVisible, isVisible, removeStyleName, setElement, setHeight, setPixelSize, setSize, setStyleName, setStyleName, setTitle, setVisible, setVisible, setWidth, sinkEvents, toString, unsinkEvents
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

PNGImage

public PNGImage(java.lang.String url,
                int width,
                int height)
Method Detail

getUrl

public java.lang.String getUrl()
Overrides:
getUrl in class com.google.gwt.user.client.ui.Image

setUrl

public void setUrl(java.lang.String url)
Should not be used. Throws RuntimeException

Overrides:
setUrl in class com.google.gwt.user.client.ui.Image


Copyright © 2006 Robert Hanson. All Rights Reserved.