[Arakhnę-Dev] [406] * Move the color constants to VectorToolkit to Colors.

[ Thread Index | Date Index | More arakhne.org/dev Archives ]


Revision: 406
Author:   galland
Date:     2013-04-04 20:23:15 +0200 (Thu, 04 Apr 2013)
Log Message:
-----------
* Move the color constants to VectorToolkit to Colors.

Modified Paths:
--------------
    trunk/ui/ui-vector/src/main/java/org/arakhne/afc/ui/vector/VectorToolkit.java

Added Paths:
-----------
    trunk/ui/ui-vector/src/main/java/org/arakhne/afc/ui/vector/Colors.java

Added: trunk/ui/ui-vector/src/main/java/org/arakhne/afc/ui/vector/Colors.java
===================================================================
--- trunk/ui/ui-vector/src/main/java/org/arakhne/afc/ui/vector/Colors.java	                        (rev 0)
+++ trunk/ui/ui-vector/src/main/java/org/arakhne/afc/ui/vector/Colors.java	2013-04-04 18:23:15 UTC (rev 406)
@@ -0,0 +1,97 @@
+/* 
+ * $Id$
+ * 
+ * Copyright (C) 2012 Stephane GALLAND.
+ * 
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ * 
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+ * Lesser General Public License for more details.
+ * 
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+ * This program is free software; you can redistribute it and/or modify
+ */
+package org.arakhne.afc.ui.vector;
+
+/** Default system colors.
+ *
+ * @author $Author: galland$
+ * @version $FullVersion$
+ * @mavengroupid $GroupId$
+ * @mavenartifactid $ArtifactId$
+ */
+public class Colors {
+	
+    /**
+     * The color white.  In the default sRGB space.
+     */
+    public final static Color WHITE = VectorToolkit.color(255, 255, 255, 255);
+
+    /**
+     * The color light gray.  In the default sRGB space.
+     */
+    public final static Color LIGHT_GRAY = VectorToolkit.color(192, 192, 192, 255);
+
+    /**
+     * The color gray.  In the default sRGB space.
+     */
+    public final static Color GRAY = VectorToolkit.color(128, 128, 128, 255);
+
+    /**
+     * The color dark gray.  In the default sRGB space.
+     */
+    public final static Color DARK_GRAY = VectorToolkit.color(64, 64, 64, 255);
+
+    /**
+     * The color black.  In the default sRGB space.
+     */
+    public final static Color BLACK = VectorToolkit.color(0, 0, 0, 255);
+
+    /**
+     * The color red.  In the default sRGB space.
+     */
+    public final static Color RED = VectorToolkit.color(255, 0, 0, 255);
+
+    /**
+     * The color pink.  In the default sRGB space.
+     */
+    public final static Color PINK = VectorToolkit.color(255, 175, 175, 255);
+
+    /**
+     * The color orange.  In the default sRGB space.
+     */
+    public final static Color ORANGE = VectorToolkit.color(255, 200, 0, 255);
+
+    /**
+     * The color yellow.  In the default sRGB space.
+     */
+    public final static Color YELLOW = VectorToolkit.color(255, 255, 0, 255);
+
+    /**
+     * The color green.  In the default sRGB space.
+     */
+    public final static Color GREEN = VectorToolkit.color(0, 255, 0, 255);
+
+    /**
+     * The color magenta.  In the default sRGB space.
+     */
+    public final static Color MAGENTA = VectorToolkit.color(255, 0, 255, 255);
+
+    /**
+     * The color cyan.  In the default sRGB space.
+     */
+    public final static Color CYAN = VectorToolkit.color(0, 255, 255, 255);
+
+    /**
+     * The color blue.  In the default sRGB space.
+     */
+    public final static Color BLUE = VectorToolkit.color(0, 0, 255, 255);
+    
+}

Modified: trunk/ui/ui-vector/src/main/java/org/arakhne/afc/ui/vector/VectorToolkit.java
===================================================================
--- trunk/ui/ui-vector/src/main/java/org/arakhne/afc/ui/vector/VectorToolkit.java	2013-04-04 07:15:27 UTC (rev 405)
+++ trunk/ui/ui-vector/src/main/java/org/arakhne/afc/ui/vector/VectorToolkit.java	2013-04-04 18:23:15 UTC (rev 406)
@@ -778,67 +778,93 @@
 	
     /**
      * The color white.  In the default sRGB space.
+     * @deprecated see {@link Colors#WHITE}
      */
+	@Deprecated
     public final static Color WHITE;
 
     /**
      * The color light gray.  In the default sRGB space.
+     * @deprecated see {@link Colors#LIGHT_GRAY}
      */
+	@Deprecated
     public final static Color LIGHT_GRAY;
 
     /**
      * The color gray.  In the default sRGB space.
+     * @deprecated see {@link Colors#GRAY}
      */
+	@Deprecated
     public final static Color GRAY;
 
     /**
      * The color dark gray.  In the default sRGB space.
+     * @deprecated see {@link Colors#DARK_GRAY}
      */
+	@Deprecated
     public final static Color DARK_GRAY;
 
     /**
      * The color black.  In the default sRGB space.
+     * @deprecated see {@link Colors#BLACK}
      */
+	@Deprecated
     public final static Color BLACK;
 
     /**
      * The color red.  In the default sRGB space.
+     * @deprecated see {@link Colors#RED}
      */
+	@Deprecated
     public final static Color RED;
 
     /**
      * The color pink.  In the default sRGB space.
+     * @deprecated see {@link Colors#PINK}
      */
+	@Deprecated
     public final static Color PINK;
 
     /**
      * The color orange.  In the default sRGB space.
+     * @deprecated see {@link Colors#ORANGE}
      */
+	@Deprecated
     public final static Color ORANGE;
 
     /**
      * The color yellow.  In the default sRGB space.
+     * @deprecated see {@link Colors#YELLOW}
      */
+	@Deprecated
     public final static Color YELLOW;
 
     /**
      * The color green.  In the default sRGB space.
+     * @deprecated see {@link Colors#GREEN}
      */
+	@Deprecated
     public final static Color GREEN;
 
     /**
      * The color magenta.  In the default sRGB space.
+     * @deprecated see {@link Colors#MAGENTA}
      */
+	@Deprecated
     public final static Color MAGENTA;
 
     /**
      * The color cyan.  In the default sRGB space.
+     * @deprecated see {@link Colors#CYAN}
      */
+	@Deprecated
     public final static Color CYAN;
 
     /**
      * The color blue.  In the default sRGB space.
+     * @deprecated see {@link Colors#BLUE}
      */
+	@Deprecated
     public final static Color BLUE;
 
     /** Create a color.
@@ -1042,19 +1068,19 @@
 	
 	static {
 		init();
-	    WHITE = color(255, 255, 255, 255);
-	    LIGHT_GRAY = color(192, 192, 192, 255);
-	    GRAY = color(128, 128, 128, 255);
-	    DARK_GRAY = color(64, 64, 64, 255);
-	    BLACK = color(0, 0, 0, 255);
-	    RED = color(255, 0, 0, 255);
-	    PINK = color(255, 175, 175, 255);
-	    ORANGE = color(255, 200, 0, 255);
-	    YELLOW = color(255, 255, 0, 255);
-	    GREEN = color(0, 255, 0, 255);
-	    MAGENTA = color(255, 0, 255, 255);
-	    CYAN = color(0, 255, 255, 255);
-	    BLUE = color(0, 0, 255, 255);
+		WHITE = color(255, 255, 255, 255);
+		LIGHT_GRAY = color(192, 192, 192, 255);
+		GRAY = color(128, 128, 128, 255);
+		DARK_GRAY = color(64, 64, 64, 255);
+		BLACK = color(0, 0, 0, 255);
+		RED = color(255, 0, 0, 255);
+		PINK = color(255, 175, 175, 255);
+		ORANGE = color(255, 200, 0, 255);
+		YELLOW = color(255, 255, 0, 255);
+		GREEN = color(0, 255, 0, 255);
+		MAGENTA = color(255, 0, 255, 255);
+		CYAN = color(0, 255, 255, 255);
+		BLUE = color(0, 0, 255, 255);
 	}
 
 	//------------------------------


Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/