01: /*
02: * The contents of this file are subject to the Mozilla Public License
03: * Version 1.1 (the "License"); you may not use this file except in
04: * compliance with the License. You may obtain a copy of the License at
05: * http://www.mozilla.org/MPL/
06: *
07: * Software distributed under the License is distributed on an "AS IS"
08: * basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the
09: * License for the specific language governing rights and limitations
10: * under the License.
11: *
12: * The Original Code is iSQL-Viewer, A Mutli-Platform Database Tool.
13: *
14: * The Initial Developer of the Original Code is iSQL-Viewer, A Mutli-Platform Database Tool.
15: * Portions created by Mark A. Kobold are Copyright (C) 2000-2007. All Rights Reserved.
16: *
17: * Contributor(s):
18: * Mark A. Kobold [mkobold <at> isqlviewer <dot> com].
19: *
20: * If you didn't download this code from the following link, you should check
21: * if you aren't using an obsolete version: http://www.isqlviewer.com
22: */
23: package org.isqlviewer.bookmarks;
24:
25: import java.awt.Color;
26:
27: /**
28: * Simple Enumeration of allowable colors that a bookmark can use as its label color.
29: * <p>
30: *
31: * @author Mark A. Kobold <mkobold at isqlviewer dot com>
32: * @version 1.0
33: */
34: public enum ColorLabel {
35:
36: /**
37: * Red (255,117,112).
38: */
39: RED(255, 117, 112),
40: /**
41: * Orange (255, 188, 91)
42: */
43: ORANGE(255, 188, 91),
44: /**
45: * Yellow (247, 237, 97)
46: */
47: YELLOW(247, 237, 97),
48: /**
49: * Green (183, 231, 100)
50: */
51: GREEN(183, 231, 100),
52: /**
53: * Blue (113, 188, 255)
54: */
55: BLUE(113, 188, 255),
56: /**
57: * Purple/Violet (220, 161, 229)
58: */
59: PURPLE(220, 161, 229),
60: /**
61: * Gray (190, 190, 190)
62: */
63: GRAY(190, 190, 190);
64:
65: private Color color = null;
66:
67: private ColorLabel(int red, int green, int blue) {
68:
69: color = new Color(red, green, blue);
70: }
71:
72: public Color toColor() {
73:
74: return color;
75: }
76: }
|