1 /* 2 * Created on Aug 31, 2004 3 */ 4 package org.flexdock.docking.drag.effects; 5 6 import java.awt.Color; 7 import java.awt.Graphics; 8 import java.awt.Rectangle; 9 10 /** 11 * @author Christopher Butler 12 * 13 */ 14 public class RubberBand { 15 public static final String DEBUG_OUTPUT = "rubberband.debug"; 16 paint(Graphics g, int x, int y, int width, int height)17 public void paint(Graphics g, int x, int y, int width, int height) { 18 paint(g, new Rectangle(x, y, width, height)); 19 } 20 paint(int x, int y, int width, int height)21 public void paint(int x, int y, int width, int height) { 22 paint(new Rectangle(x, y, width, height)); 23 } 24 paint(Rectangle r)25 public void paint(Rectangle r) { 26 paint(null, r); 27 } 28 paint(Graphics g, Rectangle r)29 public void paint(Graphics g, Rectangle r) { 30 if(g==null || r==null || true) 31 return; 32 33 g.setXORMode(Color.BLACK); 34 g.drawRect(r.x, r.y, r.width, r.height); 35 g.setXORMode(null); 36 } 37 clear()38 public void clear() { 39 } 40 } 41