Here you can find the source of drawBorderWhite(Graphics2D g, JComponent focusOwner, JComponent area)
public static void drawBorderWhite(Graphics2D g, JComponent focusOwner, JComponent area)
//package com.java2s; //License from project: Open Source License import java.awt.Color; import java.awt.Graphics2D; import javax.swing.JComponent; public class Main { public static void drawBorderWhite(Graphics2D g, JComponent focusOwner, JComponent area) { g.setColor(new Color(255, 255, 255)); g.drawRect(0, 0, area.getWidth() - 1, area.getHeight() - 1); g.drawRect(1, 1, area.getWidth() - 3, area.getHeight() - 3); if (focusOwner != null && focusOwner.isFocusOwner()) { g.setColor(new Color(240, 240, 240)); g.drawRect(0, 0, area.getWidth() - 1, area.getHeight() - 1); g.drawRect(1, 1, area.getWidth() - 3, area.getHeight() - 3); }/* www .ja va2 s . com*/ } }