javax.rad.genui.component
Class UIIcon

java.lang.Object
  extended by javax.rad.genui.UIResource<C>
      extended by javax.rad.genui.UIComponent<IIcon>
          extended by javax.rad.genui.component.UIIcon
All Implemented Interfaces:
ITranslatable, IIcon, IAlignmentConstants, IComponent, IResource, INamedObject

public class UIIcon
extends UIComponent<IIcon>
implements IIcon

Platform and technology independent Icon. It is designed for use with AWT, Swing, SWT, JSP, JSF, ... .


Field Summary
 
Fields inherited from class javax.rad.genui.UIComponent
lLastTranslationModified, parent
 
Fields inherited from class javax.rad.genui.UIResource
uiResource
 
Fields inherited from interface javax.rad.ui.IAlignmentConstants
ALIGN_BOTTOM, ALIGN_CENTER, ALIGN_LEFT, ALIGN_RIGHT, ALIGN_STRETCH, ALIGN_TOP
 
Constructor Summary
  UIIcon()
          Creates a new instance of UIIcon.
protected UIIcon(IIcon pIcon)
          Creates a new instance of UIIcon with the given icon.
  UIIcon(IImage pImage)
          Creates a new instance of UIIcon.
  UIIcon(IImage pImage, int pHorizontalAlignment, int pVerticalAlignment)
          Creates a new instance of UIIcon.
  UIIcon(String pImageName)
          Creates a new instance of UIIcon.
  UIIcon(String pImageName, int pHorizontalAlignment, int pVerticalAlignment)
          Creates a new instance of UIIcon.
 
Method Summary
 int getHorizontalAlignment()
          Returns the alignment along the x axis.
 IImage getImage()
          Returns the default image.
 int getVerticalAlignment()
          Returns the alignment along the y axis.
 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 javax.rad.genui.UIComponent
addNotify, beforeAddNotify, capture, createCellFormatter, createNodeFormatter, debug, error, eventComponentMoved, eventComponentResized, eventKeyPressed, eventKeyReleased, eventKeyTyped, eventMouseClicked, eventMouseEntered, eventMouseExited, eventMousePressed, eventMouseReleased, getBackground, getBounds, getComponentUIResource, getCurrentTranslation, getCursor, getEventSource, getFactory, getFont, getForeground, getLocation, getLocationRelativeTo, getMaximumSize, getMinimumSize, getName, getParent, getPreferredSize, getResource, getSize, getToolTipText, getTranslation, info, invokeAndWait, invokeAndWait, invokeInThread, invokeInThread, invokeLater, invokeLater, isBackgroundSet, isBeforeNotified, isCursorSet, isEnabled, isFocusable, isFontSet, isForegroundSet, isMaximumSizeSet, isMinimumSizeSet, isNotified, isPreferredSizeSet, isTranslationChanged, isTranslationEnabled, isVisible, removeNotify, requestFocus, setBackground, setBounds, setBounds, setCursor, setEnabled, setEventSource, setFocusable, setFont, setForeground, setLocation, setLocation, setLocationRelativeTo, setMaximumSize, setMaximumSize, setMinimumSize, setMinimumSize, setName, setParent, setPreferredSize, setPreferredSize, setSize, setSize, setToolTipText, setTranslation, setTranslationEnabled, setVisible, translate, updateTranslation
 
Methods inherited from class javax.rad.genui.UIResource
equals, getUIResource, 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
 

Constructor Detail

UIIcon

public UIIcon()
Creates a new instance of UIIcon.

See Also:
IIcon

UIIcon

protected UIIcon(IIcon pIcon)
Creates a new instance of UIIcon with the given icon.

Parameters:
pIcon - the icon
See Also:
IIcon

UIIcon

public UIIcon(IImage pImage)
Creates a new instance of UIIcon.

Parameters:
pImage - the Image.
See Also:
IIcon

UIIcon

public UIIcon(String pImageName)
Creates a new instance of UIIcon.

Parameters:
pImageName - the Image name.
See Also:
IIcon

UIIcon

public UIIcon(IImage pImage,
              int pHorizontalAlignment,
              int pVerticalAlignment)
Creates a new instance of UIIcon.

Parameters:
pImage - the Image.
pHorizontalAlignment - the horizontal alignment.
pVerticalAlignment - the vertical alignment.
See Also:
IIcon

UIIcon

public UIIcon(String pImageName,
              int pHorizontalAlignment,
              int pVerticalAlignment)
Creates a new instance of UIIcon.

Parameters:
pImageName - the Image name.
pHorizontalAlignment - the horizontal alignment.
pVerticalAlignment - the vertical alignment.
See Also:
IIcon
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()

getHorizontalAlignment

public int getHorizontalAlignment()
Returns the alignment along the x axis. This specifies how the component would like to be aligned relative to other components. Possible values are defined in AlignmentConstants.

Specified by:
getHorizontalAlignment in interface IAlignmentConstants
Returns:
the horizontal alignment

setHorizontalAlignment

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

Specified by:
setHorizontalAlignment in interface IAlignmentConstants
Parameters:
pHorizontalAlignment - the new vertical alignment

getVerticalAlignment

public int getVerticalAlignment()
Returns the alignment along the y axis. This specifies how the component would like to be aligned relative to other components. Possible values are defined in AlignmentConstants.

Specified by:
getVerticalAlignment in interface IAlignmentConstants
Returns:
the vertical alignment

setVerticalAlignment

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

Specified by:
setVerticalAlignment in interface IAlignmentConstants
Parameters:
pVerticalAlignment - the new vertical alignment


Copyright © 2009 SIB Visions GmbH. All Rights Reserved.