Class ImageIconProxy

java.lang.Object
javax.swing.ImageIcon
com.nomagic.magicdraw.ui.ImageIconProxy
All Implemented Interfaces:
Serializable, Accessible, Icon

@OpenApi @Deprecated public class ImageIconProxy extends ImageIcon
Deprecated.
This class is used only for reloading icons after image path is changed.
See Also:
  • Field Details

  • Constructor Details

    • ImageIconProxy

      @OpenApi public ImageIconProxy(Class clazz, String name)
      Deprecated.
      Constructs a new ImageIcon instance.
      Parameters:
      clazz - the class to identify resources.
      name - the name of the icon in the map.
    • ImageIconProxy

      @OpenApi public ImageIconProxy(Class clazz, String name, String pathToIcons)
      Deprecated.
      Constructs a new ImageIcon instance. For icons directory uses given path
      Parameters:
      clazz - the class to indentify resources.
      name - the name of the icon in the map.
      pathToIcons - path to icons directory, this directory must contain subdirs icons32 and icons24. Can be empty string In this case it means same dir as clazz.
    • ImageIconProxy

      @OpenApi public ImageIconProxy(IconControlerInterface iconControler)
      Deprecated.
      The proxy constructor with given controller
      Parameters:
      iconControler -
  • Method Details

    • paintIcon

      public void paintIcon(Component c, Graphics g, int x, int y)
      Deprecated.
      Draw the icon at the specified location. Icon implementations may use the Component argument to get properties useful for painting, e.g. the foreground or background color.
      Specified by:
      paintIcon in interface Icon
      Overrides:
      paintIcon in class ImageIcon
      Parameters:
      c - the component.
      g - the graphics.
      x - X coordinate.
      y - Y coordinate.
    • getIconWidth

      public int getIconWidth()
      Deprecated.
      Returns the icon's width.
      Specified by:
      getIconWidth in interface Icon
      Overrides:
      getIconWidth in class ImageIcon
      Returns:
      an int specifying the fixed width of the icon.
    • getImage

      public Image getImage()
      Deprecated.
      Returns image for the icon.
      Overrides:
      getImage in class ImageIcon
      Returns:
      the image.
    • getIconHeight

      public int getIconHeight()
      Deprecated.
      Returns the icon's height.
      Specified by:
      getIconHeight in interface Icon
      Overrides:
      getIconHeight in class ImageIcon
      Returns:
      an int specifying the fixed height of the icon.