If you know bit of HTML and when you're developing a webpage, I think you would have felt uneasy while choosing the colors for the web. I've developed a small Swing component which will just list down all the known color as shown below in the screenshot. I hope this tool enables you to choose the perfect colors. You need to have two files, one is Java program and other is Properties file which has the color codes used in my program.

ColorsDemo.java
import java.io.FileInputStream;
import java.awt.*;
import java.util.*;
import javax.swing.*;
import java.awt.event.*;

public class ColorsDemo extends JFrame implements ActionListener
{
FileInputStream fis;
Properties prop;
Color colors[];
JScrollPane s,s1;
JPanel p;
JTextArea ta;
JButton clabels[];
boolean backcolor;
public ColorsDemo()
{
try{
fis=new FileInputStream("props.properties");
prop=new Properties();
prop.load(fis);
}catch(Exception e){
}
backcolor=true;
p=new JPanel();
s=new JScrollPane(p);
p.setLayout(new GridLayout(20,7));
colors=new Color[140];
clabels=new JButton[140];
Enumeration e = prop.propertyNames();
int i=0;
while(e.hasMoreElements())
{
String propname=(String)e.nextElement();
String str=prop.getProperty(propname);
int r=(Integer.decode("#"+str.substring(1,3))).intValue();
int g=(Integer.decode("#"+str.substring(3,5))).intValue();
int b=(Integer.decode("#"+str.substring(5,7))).intValue();
clabels[i]=new JButton("<HTML><CENTER>"+propname+"<BR>"+str+"<BR>Red="+r+", Green="+g+", Blue="+b+"</HTML>");
colors[i]=new Color(r,g,b);
clabels[i].setBackground(colors[i]);
clabels[i].addActionListener(this);
p.add(clabels[i]);
//clabels[i].setEditable(false);
i++;
}
Container c=getContentPane();
ta=new JTextArea("Using the following buttons you are able \n"+
"to set the background and foreground colors\n"+
"of this text area.\n Click the buttons,\n"+
"It will automatically sets the background\n"+
"and foreground colors.\n Remember one time\n"+
"background color and another one foreground color\n"+
"For the first time background color\n"+
"------------------------------------\n"+
"Designed and Devloped by\n"+
"SANTHOSH REDDY MANDADI");
s1=new JScrollPane(ta);
ta.setFont(new Font("MS Sans Serif",Font.BOLD,20));
c.setLayout(new GridLayout(2,1));
c.add(s1);
c.add(s);
setDefaultCloseOperation(EXIT_ON_CLOSE);
setSize(500,400);
setTitle("Color Demo - you can able to select suitable colors for webpage");
setVisible(true);
}
public void actionPerformed(ActionEvent ae)
{
String str=ae.getActionCommand();
int x=str.indexOf('#');
str=str.substring(x,x+8);
int r=(Integer.decode("#"+str.substring(1,3))).intValue();
int g=(Integer.decode("#"+str.substring(3,5))).intValue();
int b=(Integer.decode("#"+str.substring(5,7))).intValue();
Color c=new Color(r,g,b);
if(backcolor)
{
ta.setBackground(c);
backcolor=false;
//System.out.println(ta.getText().lastIndexOf('\n'));
//System.out.println(ta.getText().length());
//ta.setSelectionStart(ta.getText().lastIndexOf('\n'));
//ta.setSelectionEnd(ta.getText().length());
//ta.select(ta.getSelectionStart(),ta.getSelectionEnd());
//ta.selectAll();
//System.out.println(ta.getSelectedText());
//ta.revalidate();
}
else
{
ta.setForeground(c);
backcolor=true;
}
}
public static void main(String[] args) throws Exception
{
new ColorsDemo();
}
}
prop.properties
ALICEBLUE=#F0F8FF
ANTIQUEWHITE=#FAEBD7
AQUA=#00FFFF
AQUAMARINE=#7FFFD4
AZURE=#F0FFFF
BEIGE=#F5F5DC
BISQUE=#FFE4C4
BLACK=#000000
BLANCHEDALMOND=#FFEBCD
BLUE=#0000FF
BLUEVIOLET=#8A2BE2
BROWN=#A52A2A
BURLYWOOD=#DEB887
CADETBLUE=#5F9EA0
CHARTREUSE=#7FFF00
CHOCOLATE=#D2691E
CORAL=#FF7F50
CORNFLOWER=#6495ED
CORNSILK=#FFF8DC
CRIMSON=#D614EC
CYAN=#00FFFF
DARKBLUE=#00008B
DARKCYAN=#008B8B
DARKGOLDENROD=#B8860B
DARKGRAY=#A9A9A9
DARKGREEN=#006400
DARKKHAKI=#BDB76B
DARKMAGENTA=#8B008B
DARKOLIVEGREEN=#556B2F
DARKORANGE=#FF8C00
DARKORCHID=#9932CC
DARKRED=#8B0000
DARKSALMON=#E9967A
DARKSEAGREEN=#8FBC8B
DARKSLATEBLUE=#483D8B
DARKSLATEGRAY=#2F4F4F
DARKTURQUOISE=#00CED1
DARKVIOLET=#9400D3
DEEPPINK=#FF1493
DEEPSKYBLUE=#00BFFF
DIMGRAY=#696969
DODGERBLUE=#1E90FF
FIREBRICK=#B22222
FLORALWHITE=#FFFAF0
FORESTGREEN=#228B22
FUCHIA=#FF00FF
GIANSBORO=#DCDCDC
GHOSTWHITE=#F8F8FF
GOLD=#FFD700
GOLDENTROD=#DAA520
GRAY=#808080
GREEN=#008000
GREENYELLOW=#ADFF2F
HONEYDEW=#F0FFF0
HOTPINK=#FF69B4
INDIANRED=#CD5C5C
INDIGO=#4B0082
IVORY=#FFFFF0
KHAKI=#F0E68C
LAVENDER=#E6E6FA
LAVENDERBLUSH=#FFF0F5
LAWNGREEN=#7CFC00
LEMONCHIFFON=#FFFACD
LIGHTBLUE=#ADD8E6
LIGHTCORAL=#F08080
LIGHTCYAN=#E0FFFF
LIGHTGOLDENRODYELLOW=#FAFAD2
LIGHTGREEN=#90EE90
LIGHTGRAY=#D3D3D3
LIGHTPINK=#FFB6C1
LIGHTSALMON=#FFA074
LIGHTSEAGREEN=#20B2AA
LIGHTSKYBLUE=#87CEFA
LIGHTSLATEGRAY=#778899
LIGHTSTEELBLUE=#B0C4DE
LIGHTYELLOW=#FFFFE0
LIME=#00FF00
LIMEGREEN=#32CD32
LINEN=#FAF0E6
MAGENTA=#FF00FF
MAROON=#800000
MEDIUMAQUAMARINE=#66CDAA
MEDIUMBLUE=#0000CD
MEDUMORCHID=#BA55D3
MEDIUMPURPLE=#9370DB
MEDIUMSEAGREEN=#3CB371
MEDIUMSLATEBLUE=#7B68EE
MEDIUMSPRINGGREEN=#00FA9A
MEDIUMTURQUOISE=#48D1CC
MEDIUMVIOLETRED=#C71585
MIDNIGHTBLUE=#191970
MINTCREAM=#F5FFFA
MISTYROSE=#FFE4E1
MOCCASIN=#FFE4B5
NAVAJOWTHITE=#FFDEAD
NAVY=#000080
OLDLACE=#FDF5E6
OLIVE=#808000
OLIVEDRAB=#6B8E23
ORANGE=#FFA500
ORANGERED=#FF4500
ORCHID=#DA70D6
PALEGOLDENROD=#EEE8AA
PALEGREEN=#98FB98
PALETURQUOISE=#AFEEEE
PALEVIOLETRED=#DB7093
PAPAYAWHIP=#FFEFD5
PEACHPUFF=#FFDAB9
PERU=#CD853F
PINK=#FFC0CB
PLUM=#DDA0DD
POWDERBLUE=#B0E0E6
PURPLE=#800080
RED=#FF0000
ROSYBROWN=#BC8F8F
ROYALBLUE=#4169E1
SEASHELL=#FFF5EE
SALMON=#FA8072
SILVER=#C0C0C0
SEAGREEN=#2E8B57
SLATEBLUE=#6A5ACD
SIENNA=#A0522D
SNOW=#FFFAFA
SKYBLUE=#87CEEB
STEELBLUE=#4682B4
SLATEGRAY=#708090
TEAL=#008080
SPRINGGREEN=#00FF7F
TOMATO=#FF6347
TAN=#D2B48C
VIOLET=#EE82EE
THISTLE=#D8BFD8
WHITE=#FFFFFF
TURQUOISE=#40E0D0
YELLOW=#FFFF00
WHEAT=#F5DEB3
SADDLEBROWN=#8B4513
WHITESMOKE=#F5F5F5
SANDYBROWN=#F4A460
YELLOWGREEN=#9ACD32

Place properties file under the same folder where you've placed the ColorsDemo.java. Compile the code and run it, you'll see the output as a swing window. This program has been tested on 1.5, 1.6, and 1.7 versions of Sun Java.

If you've sometime, why don't you checkout my other Java programs