PPT Slide
import javax.swing.event.*;
class DynamicIcon implements Icon {
public DynamicIcon (Image im, JSlider width, JSlider height){
public int getIconWidth() { return width.getValue(); }
public int getIconHeight() { return height.getValue(); }
public void paintIcon(Component c, Graphics g, int x, int y) {
g.setClip(x, y, getIconWidth(), getIconHeight());