com.sibvisions.rad.ui.swing.impl.component
Class SwingIcon

java.lang.Object
  extended by com.sibvisions.rad.ui.awt.impl.AwtResource<C>
      extended by com.sibvisions.rad.ui.awt.impl.AwtComponent<C>
          extended by com.sibvisions.rad.ui.awt.impl.AwtContainer<C>
              extended by com.sibvisions.rad.ui.swing.impl.SwingComponent<JVxIcon>
                  extended by com.sibvisions.rad.ui.swing.impl.component.SwingIcon
All Implemented Interfaces:
ComponentListener, KeyListener, MouseListener, EventListener, IIcon, IAlignmentConstants, IComponent, IContainer, IResource, INamedObject

public class SwingIcon
extends SwingComponent<JVxIcon>
implements IIcon

The SwingIcon is the IIcon implementation for swing. It displays an area for an image. and does not react to input events. As a result, it cannot get the keyboard focus.

See Also:
JLabel, IIcon

Field Summary
 
Fields inherited from class com.sibvisions.rad.ui.awt.impl.AwtComponent
eventComponentMoved, eventComponentResized, eventSource, factory, parent
 
Fields inherited from class com.sibvisions.rad.ui.awt.impl.AwtResource
resource
 
Fields inherited from interface javax.rad.ui.IAlignmentConstants
ALIGN_BOTTOM, ALIGN_CENTER, ALIGN_LEFT, ALIGN_RIGHT, ALIGN_STRETCH, ALIGN_TOP
 
Constructor Summary
SwingIcon()
          Creates a new instance of SwingIcon.
 
Method Summary
 IImage getImage()
          Returns the default image.
 void setHorizontalAlignment(int pHorizontalAlignment)
          Sets the horizontal alignment.
 void setImage(IImage pImage)
          Sets the default image.
 void setVerticalAlignment(int pVerticalAlignment)
          Sets the vertical alignment.
 
Methods inherited from class com.sibvisions.rad.ui.swing.impl.SwingComponent
capture, getToolTipText, setBackground, setToolTipText
 
Methods inherited from class com.sibvisions.rad.ui.awt.impl.AwtContainer
add, add, add, add, addIntern, checkAdd, getComponent, getComponentCount, getLayout, indexOf, remove, remove, removeAll, removeIntern, setLayout, setLayoutIntern
 
Methods inherited from class com.sibvisions.rad.ui.awt.impl.AwtComponent
componentHidden, componentMoved, componentResized, componentShown, createImage, eventComponentMoved, eventComponentResized, eventKeyPressed, eventKeyReleased, eventKeyTyped, eventMouseClicked, eventMouseEntered, eventMouseExited, eventMousePressed, eventMouseReleased, getBackground, getBounds, getCursor, getEventSource, getFactory, getFont, getForeground, getHorizontalAlignment, getLocation, getLocationRelativeTo, getMaximumSize, getMinimumSize, getName, getParent, getPreferredSize, getSize, getVerticalAlignment, isBackgroundSet, isCursorSet, isEnabled, isFocusable, isFontSet, isForegroundSet, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isVisible, keyPressed, keyReleased, keyTyped, mouseClicked, mouseEntered, mouseExited, mousePressed, mouseReleased, requestFocus, setBounds, setCursor, setEnabled, setEventSource, setFactory, setFocusable, setFont, setForeground, setLocation, setLocationRelativeTo, setMaximumSize, setMinimumSize, setName, setParent, setPreferredSize, setSize, setVisible, validate
 
Methods inherited from class com.sibvisions.rad.ui.awt.impl.AwtResource
equals, getResource, hashCode, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface javax.rad.ui.IComponent
capture, eventComponentMoved, eventComponentResized, eventKeyPressed, eventKeyReleased, eventKeyTyped, eventMouseClicked, eventMouseEntered, eventMouseExited, eventMousePressed, eventMouseReleased, getBackground, getBounds, getCursor, getEventSource, getFactory, getFont, getForeground, getLocation, getLocationRelativeTo, getMaximumSize, getMinimumSize, getName, getParent, getPreferredSize, getSize, getToolTipText, isBackgroundSet, isCursorSet, isEnabled, isFocusable, isFontSet, isForegroundSet, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isVisible, requestFocus, setBackground, setBounds, setCursor, setEnabled, setEventSource, setFocusable, setFont, setForeground, setLocation, setLocationRelativeTo, setMaximumSize, setMinimumSize, setName, setParent, setPreferredSize, setSize, setToolTipText, setVisible
 
Methods inherited from interface javax.rad.ui.IResource
getResource
 
Methods inherited from interface javax.rad.ui.IAlignmentConstants
getHorizontalAlignment, getVerticalAlignment
 

Constructor Detail

SwingIcon

public SwingIcon()
Creates a new instance of SwingIcon.

Method Detail

getImage

public IImage getImage()
Returns the default image.

Specified by:
getImage in interface IIcon
Returns:
the default image
See Also:
IIcon.setImage(IImage)

setImage

public void setImage(IImage pImage)
Sets the default image.

Specified by:
setImage in interface IIcon
Parameters:
pImage - the image
See Also:
IIcon.getImage()

setHorizontalAlignment

public void setHorizontalAlignment(int pHorizontalAlignment)
Sets the horizontal alignment. Possible values are defined in AlignmentConstants.

Specified by:
setHorizontalAlignment in interface IAlignmentConstants
Overrides:
setHorizontalAlignment in class AwtComponent<JVxIcon>
Parameters:
pHorizontalAlignment - the new vertical alignment

setVerticalAlignment

public void setVerticalAlignment(int pVerticalAlignment)
Sets the vertical alignment. Possible values are defined in AlignmentConstants.

Specified by:
setVerticalAlignment in interface IAlignmentConstants
Overrides:
setVerticalAlignment in class AwtComponent<JVxIcon>
Parameters:
pVerticalAlignment - the new vertical alignment


Copyright © 2009 SIB Visions GmbH. All Rights Reserved.