2
* @(#)QuaquaSmallColorWellBorder.java 1.0 2005-04-18
4
* Copyright (c) 2005 Werner Randelshofer
5
* Staldenmattweg 2, Immensee, CH-6405, Switzerland.
8
* This software is the confidential and proprietary information of
9
* Werner Randelshofer. ("Confidential Information"). You shall not
10
* disclose such Confidential Information and shall use it only in
11
* accordance with the terms of the license agreement you entered into
12
* with Werner Randelshofer.
15
package org.pushingpixels.substance.internal.contrib.randelshofer.quaqua.colorchooser;
19
import javax.swing.border.*;
21
* SmallColorWellBorder.
25
public class SmallColorWellBorder implements Border {
26
private static Color inner = Color.white;
27
private static Color outer = new Color(0x949494);
28
/** Creates a new instance of QuaquaSquareButtonBorder */
29
public SmallColorWellBorder() {
33
public Insets getBorderInsets(Component c) {
34
return new Insets(1, 1, 1, 1);
38
public boolean isBorderOpaque() {
43
public void paintBorder(Component c, Graphics gr, int x, int y, int width, int height) {
44
gr.setColor(c.getBackground());
45
gr.fillRect(x + 2, y + 2, width - 4, height - 4);
47
gr.drawRect(x + 1, y + 1, width - 3, height - 3);
49
gr.drawRect(x, y, width - 1, height - 1);