borland Packages  Class Hierarchy  jbcl.control Package  Index 

ImageControl component

java.lang.Object
   +----java.awt.Component
           +----java.awt.Container
                   +----com.sun.java.swing.JComponent
                           +----borland.jbcl.view.BeanPanel
                                   +----borland.jbcl.view.FieldView
                                           +----borland.jbcl.control.FieldControl
                                                   +----borland.jbcl.control.ImageControl

About the ImageControl component

Variables  Constructors  Properties  Methods  Event Listeners

Implements AccessListener, ColumnAware, DataChangeListener, DataSetAware, NavigationListener, ItemEditSite, ItemPaintSite, SingletonModel, SingletonModelListener, WritableSingletonModel, BlackBox, SingletonModelView, SingletonView, FocusListener, KeyListener, ImageObserver, MenuContainer, Serializable, EventListener

The ImageControl component provides a container to display a graphic image such as a .gif file. You can specify the image as an Image class using the image property, as an image file name using the imageName property, and as a URL to an image using the imageURL property.

The Javasoft image shown below is aligned right, middle within the ImageControl:

ImageControl inherits much of its behavior from the FieldControl and FieldView components. See these components for more information.


ImageControl variables

Variables implemented in borland.jbcl.control.FieldControl

Variables implemented in borland.jbcl.view.BeanPanel

Variables implemented in borland.jbcl.view.FieldView

Variables implemented in com.sun.java.swing.JComponent

Variables implemented in java.awt.Component

ImageControl constructors

ImageControl properties

*Read-only properties **Write-only properties

Properties implemented in this class

Properties implemented in borland.jbcl.control.FieldControl

Properties implemented in borland.jbcl.view.BeanPanel

Properties implemented in borland.jbcl.view.FieldView

Properties implemented in com.sun.java.swing.JComponent

Properties implemented in java.awt.Component

Properties implemented in java.awt.Container

Properties implemented in java.lang.Object

ImageControl methods

Methods implemented in this class

Methods implemented in borland.jbcl.control.FieldControl

Methods implemented in borland.jbcl.view.BeanPanel

Methods implemented in borland.jbcl.view.FieldView

Methods implemented in com.sun.java.swing.JComponent

Methods implemented in java.awt.Component

Methods implemented in java.awt.Container

Methods implemented in java.lang.Object

ImageControl event listeners


ImageControl constructors

ImageControl()

  public ImageControl()

Constructs an ImageControl.


ImageControl properties

image

 public Image getImage()
 public void setImage(java.awt.Image image)
Stores the image in a model, such as SingletonModel, as a data item. The getter returns the image object.

The setter uses ImageControl.setupImage(image,"").

imageName

 public String getImageName()
 public void setImageName(java.lang.String path)
Stores the fully qualified directory and filename for the image.

imageURL

 public URL getImageURL()
 public void setImageURL(java.net.URL url)
Stores the URL for the image, such as: http://www.borland.com/images/circle.gif

model

 public void setModel(borland.jbcl.model.SingletonModel model)
Specifies the SingletonModel object that provides the image for this component.

ImageControl methods

defaultLayout()

  protected void defaultLayout()

Used by the constructor to lay out the ImageControl.

setupImage(java.awt.Image, java.lang.String)

  protected void setupImage(java.awt.Image im, java.lang.String path)

Calls java.awt.Component.prepareImage() and fills the background color.

updateSelection()

  protected void updateSelection()

Calls jbcl.util.ImageLoader.loadFromBlob(), calls ImageControl.setupImage(), then repaints the image.


ImageControl event listeners

This component is a source for the following event sets. For information on the standard AWT event sets, see Standard Java events. For information on the JBCL event sets, see Events in JBCL.

action

 public synchronized void addActionListener(java.awt.event.ActionListener l)
 public synchronized void removeActionListener(java.awt.event.ActionListener l)

ancestor

 public void addAncestorListener(com.sun.java.swing.event.AncestorListener )
 public void removeAncestorListener(com.sun.java.swing.event.AncestorListener )

component

 public synchronized void addComponentListener(java.awt.event.ComponentListener )
 public synchronized void removeComponentListener(java.awt.event.ComponentListener )

container

 public synchronized void addContainerListener(java.awt.event.ContainerListener )
 public void removeContainerListener(java.awt.event.ContainerListener )

customItem

 public synchronized void addCustomItemListener(borland.jbcl.view.CustomItemListener l)
 public synchronized void removeCustomItemListener(borland.jbcl.view.CustomItemListener l)

focus

 public synchronized void addFocusListener(java.awt.event.FocusListener )
 public synchronized void removeFocusListener(java.awt.event.FocusListener )

key

 public void addKeyListener(java.awt.event.KeyListener l)
 public void removeKeyListener(java.awt.event.KeyListener l)

model

 public void addModelListener(borland.jbcl.model.SingletonModelListener l)
 public void removeModelListener(borland.jbcl.model.SingletonModelListener l)

mouse

 public synchronized void addMouseListener(java.awt.event.MouseListener )
 public synchronized void removeMouseListener(java.awt.event.MouseListener )

mouseMotion

 public synchronized void addMouseMotionListener(java.awt.event.MouseMotionListener )
 public synchronized void removeMouseMotionListener(java.awt.event.MouseMotionListener )

propertyChange

 public synchronized void addPropertyChangeListener(java.beans.PropertyChangeListener )
 public synchronized void removePropertyChangeListener(java.beans.PropertyChangeListener )

vetoableChange

 public synchronized void addVetoableChangeListener(java.beans.VetoableChangeListener )
 public synchronized void removeVetoableChangeListener(java.beans.VetoableChangeListener )