当前位置: 首页>>代码示例>>Java>>正文


Java Color.CYAN属性代码示例

本文整理汇总了Java中java.awt.Color.CYAN属性的典型用法代码示例。如果您正苦于以下问题:Java Color.CYAN属性的具体用法?Java Color.CYAN怎么用?Java Color.CYAN使用的例子?那么恭喜您, 这里精选的属性代码示例或许可以为您提供帮助。您也可以进一步了解该属性所在java.awt.Color的用法示例。


在下文中一共展示了Color.CYAN属性的13个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: ColorComboBox

/**
 * C'tor
 * The combo box is initialized with some basic colors and user can also
 * pick a custom color
 */
public ColorComboBox() {
    this( new Color[] {
        Color.BLACK,
        Color.BLUE,
        Color.CYAN,
        Color.DARK_GRAY,
        Color.GRAY,
        Color.GREEN,
        Color.LIGHT_GRAY,
        Color.MAGENTA,
        Color.ORANGE,
        Color.PINK,
        Color.RED,
        Color.WHITE,
        Color.YELLOW,
        }, new String[0], true);
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:22,代码来源:ColorComboBox.java

示例2: executeCommand

@Override
public void executeCommand(Message msg) {
	String content = Util.getCommandContents(msg);
	if(content.equals("")) {
		MessageUtils.sendIncorrectCommandUsage(msg, this);
		return;
	}
	EmbedBuilder em = new EmbedBuilder();
	int r = new Random().nextInt(responses.length);
	em.setTitle(content, null)
	.setDescription(responses[r]);
	Color c;
	if(r < 10)
		c = Color.GREEN;
	else if(r >= 10 && r <= 14)
		c = Color.CYAN;
	else
		c = Color.RED;
	em.setColor(c);
	msg.getChannel().sendMessage(em.build()).queue();
	
}
 
开发者ID:paul-io,项目名称:momo-2,代码行数:22,代码来源:EightBall.java

示例3: transform

@Override
public Paint transform(VirtualLink input) {
	if (vls.contains(input))
		return Color.CYAN;
	else
		return backupVL.get(input.getLayer()).transform(input);
}
 
开发者ID:KeepTheBeats,项目名称:alevin-svn2,代码行数:7,代码来源:MappingTreeSelectionListener.java

示例4: drawRaycast

public boolean drawRaycast(RayCastResult ray) {
	if (levelGeometry == null || !levelGeometry.isLoaded()) return false;
			
	Color lineColor = ray.hitLocation != null ? Color.RED : Color.BLUE;
	Color cubeColor = ray.hitLocation != null ? Color.ORANGE : Color.CYAN;
	
	drawLine(lineColor, new Location(ray.ray.getOrigin()), new Location(ray.ray.getExamplePoint2()));
	
	if (ray.hitLocation != null) {
		Triangle triangle = ray.hitTriangle;
		drawPolygon(cubeColor, triangle.verticesAsLoc[0], triangle.verticesAsLoc[1], triangle.verticesAsLoc[2]);			
	}
	
	return true;
}
 
开发者ID:kefik,项目名称:Pogamut3,代码行数:15,代码来源:LevelGeometryDraw.java

示例5: add

/**
 * 
 * @param layer
 */
public void add(ImageLayer layer) {
	try{
     if(layer==null) return;
     initGlobe();
     GeoImageReader reader=layer.getImageReader();
     List<double[]> imageframe = layer.getImageReader().getFrameLatLon(reader.getWidth(),reader.getHeight());
     if (imageframe != null) {
         List<LatLon> ll = new ArrayList<LatLon>();
         for (double[] c : imageframe) {
             ll.add(new LatLon(Angle.fromDegreesLatitude(c[1]), Angle.fromDegreesLongitude(c[0])));
         }
         GlobeAnnotation ga=new GlobeAnnotation(layer.getName() + " opened", 
    		new Position(new LatLon(Angle.fromDegreesLatitude(imageframe.get(0)[1]), 
    								Angle.fromDegreesLongitude(imageframe.get(0)[0])), 
    								0));
         
         WWGeoImage gi = new WWGeoImage(new Polyline(ll,0),ga ,
         		layer.isActive() ? Color.CYAN : Color.BLUE, layer.isActive() ? Color.CYAN : Color.BLUE);
         
         gi.setAnnotationVisible(layer.isActive());
         gi.setDelegateOwner(layer);
         imageLayer.addRenderable(gi);
     }
	}catch(Exception e){
		logger.error(e.getMessage(),e);
	}  
}
 
开发者ID:ec-europa,项目名称:sumo,代码行数:31,代码来源:WWJPanel.java

示例6: decodeColor

/**
* Decodes a color value.  The parameter <code>str</code> is either the
* name of a Java color or a string in the form <code>"#rrggbb"</code>
* or <code>"#aarrggbb"</code>.  As a special case, the string
* <code>"none"</code> returns <code>null</code>.
*
* @param str The string representation of the color
* @return The color value
*/

  public static Color decodeColor(String str) {
     if (str.equalsIgnoreCase("none")) return null;
     if (str.equalsIgnoreCase("bg")) return BACKGROUND_FILL;
     if (str.equalsIgnoreCase("black")) return Color.BLACK;
     if (str.equalsIgnoreCase("blue")) return Color.BLUE;
     if (str.equalsIgnoreCase("cyan")) return Color.CYAN;
     if (str.equalsIgnoreCase("darkGray")) return Color.DARK_GRAY;
     if (str.equalsIgnoreCase("DARK_GRAY")) return Color.DARK_GRAY;
     if (str.equalsIgnoreCase("gray")) return Color.GRAY;
     if (str.equalsIgnoreCase("green")) return Color.GREEN;
     if (str.equalsIgnoreCase("lightGray")) return Color.LIGHT_GRAY;
     if (str.equalsIgnoreCase("LIGHT_GRAY")) return Color.LIGHT_GRAY;
     if (str.equalsIgnoreCase("magenta")) return Color.MAGENTA;
     if (str.equalsIgnoreCase("orange")) return Color.ORANGE;
     if (str.equalsIgnoreCase("pink")) return Color.PINK;
     if (str.equalsIgnoreCase("red")) return Color.RED;
     if (str.equalsIgnoreCase("white")) return Color.WHITE;
     if (str.equalsIgnoreCase("yellow")) return Color.YELLOW;
     try {
        if (str.startsWith("0x")) {
           str = str.substring(2);
        } else if (str.startsWith("#")) {
           str = str.substring(1);
        }
        int nDigits = str.length();
        int aa = 0xFF;
        if (nDigits == 8) {
           aa = Integer.parseInt(str.substring(0, 2), 16);
           str = str.substring(2);
        } else if (nDigits != 6) {
           throw new RuntimeException("decodeColor: Colors must have " +
                                      "6 or 8 hexadecimal digits");
        }
        return new Color(Integer.parseInt(str, 16) | (aa << 24), true);
     } catch (NumberFormatException ex) {
        throw new RuntimeException("decodeColor: Illegal color " + str);
     }
  }
 
开发者ID:eric-roberts,项目名称:JavaPPTX,代码行数:48,代码来源:PPUtil.java

示例7: testLineSlide

private PPSlide testLineSlide() {
   PPSlide slide = new PPSlide();
   slide.addTitle("Test PPLine Class");
   double xc = slide.getWidth() / 2;
   double yc = slide.getHeight() / 2;
   double r = 100;
   double dx = 0;
   double dy = 0;
   Color color = null;
   for (int i = 0; i < 8; i++) {
      switch (i) {
       case 0: dx = 0; dy = -r; color = Color.RED; break;
       case 1: dx = r; dy = -r; color = Color.ORANGE; break;
       case 2: dx = r; dy = 0; color = Color.YELLOW; break;
       case 3: dx = r; dy = r; color = Color.GREEN; break;
       case 4: dx = 0; dy = r; color = Color.CYAN; break;
       case 5: dx = -r; dy = r; color = Color.BLUE; break;
       case 6: dx = -r; dy = 0; color = Color.MAGENTA; break;
       case 7: dx = -r; dy = -r; color = Color.PINK; break;
      }
      PPLine line = new PPLine(xc, yc, xc + dx, yc + dy);
      line.setColor(color);
      line.setLineWeight(2);
      slide.add(line);
   }
   return slide;
}
 
开发者ID:eric-roberts,项目名称:JavaPPTX,代码行数:27,代码来源:PPShapeTest.java

示例8: getColor

private Color getColor(Object value) {
    String val = Objects.toString(value, "").trim();
    switch (val) {
        case "Execute":
            return Color.BLUE;//.darker();
        case "App":
            return Color.CYAN;//.darker();
        case "Browser":
            return Color.RED;//.darker();
        default:
            return new Color(204, 0, 255);
    }
}
 
开发者ID:CognizantQAHub,项目名称:Cognizant-Intelligent-Test-Scripter,代码行数:13,代码来源:ObjectRenderer.java

示例9: makeColor

private static void makeColor() {
	/* Primi 9 Colori */
	list[0] = Color.RED;
	name[0] = "ROSSO";
	list[1] = Color.BLUE;
	name[1] = "BLU";
	list[2] = Color.MAGENTA;
	name[2] = "MAGENTA";
	list[3] = Color.GREEN;
	name[3] = "VERDE";
	list[4] = Color.BLACK;
	name[4] = "NERO";
	list[5] = Color.YELLOW;
	name[5] = "GIALLO";
	list[6] = Color.PINK;
	name[6] = "ROSA";
	list[7] = Color.CYAN;
	name[7] = "AZZURRO";
	list[8] = Color.ORANGE;
	name[8] = "ARANCIONE";
	list[9] = Color.GRAY;
	name[9] = "GRIGIO";
	list[10] = new Color(155, 0, 0);
	name[10] = "ROSSO SCURO";
	list[11] = new Color(94, 0, 2);
	name[11] = "MARRONE";
	list[12] = new Color(242, 129, 252);
	name[12] = "VIOLA CHIARO";
	list[13] = new Color(129, 69, 135);
	name[13] = "VIOLA SCURO";
	list[14] = new Color(141, 141, 254);
	name[14] = "BLU CHIARO";
	list[15] = new Color(1, 1, 109);
	name[15] = "BLU SCURO";
	list[16] = new Color(3, 124, 146);
	name[16] = "AZZURRO SCURO";
	list[17] = new Color(83, 172, 105);
	name[17] = "VERDINO";
	list[18] = new Color(33, 116, 35);
	name[18] = "VERDE SCURO";
	list[19] = new Color(128, 206, 49);
	name[19] = "VERDACCIO";
	list[20] = new Color(170, 162, 55);
	name[20] = "ORO";
	list[21] = new Color(191, 156, 34);
	name[21] = "OCRA";
	list[22] = new Color(255, 0, 128);
	name[22] = "ROSACCIO";
	list[23] = new Color(198, 50, 50);
	name[23] = "ROSSO N°2";
	list[24] = new Color(99, 55, 137);
	name[24] = "VIOLA SCURO N°2";
	list[25] = new Color(99, 55, 137).brighter();
	name[25] = "ROSSO N°3";
	list[26] = new Color(129, 69, 135).brighter();
	name[26] = "VIOLA SCURO N°2";
	list[27] = new Color(141, 141, 254).darker();
	name[27] = "BLU CHIARO N°2";
	list[28] = new Color(1, 1, 109).brighter().brighter();
	name[28] = "BLU SCURO N°2";
	list[29] = new Color(3, 124, 146).brighter();
	name[29] = "AZZURRO SCURO N°2";
	list[30] = new Color(83, 172, 105).darker();
	name[30] = "VERDINO N°2";
	list[31] = new Color(33, 116, 35).brighter();
	name[31] = "VERDE SCURO N°2";
	list[32] = new Color(128, 206, 49).brighter();
	name[32] = "VERDACCIO N°2";
	list[33] = new Color(170, 162, 55).brighter();
	name[33] = "ORO N°2";
	list[34] = new Color(191, 156, 34).darker();
	name[34] = "OCRA N°2";
	list[35] = new Color(255, 0, 128).brighter();
	name[35] = "ROSACCIO N°2";
	list[36] = new Color(198, 50, 50).darker().darker();
	name[36] = "ROSSO N°4";
	list[37] = new Color(99, 55, 137).brighter().brighter();
	name[37] = "VIOLA SCURO N°3";
}
 
开发者ID:max6cn,项目名称:jmt,代码行数:79,代码来源:JavaWatColor.java

示例10: makeColor

private static void makeColor() {
	/* Primi 9 Colori */
	list[0] = Color.RED;
	name[0] = "ROSSO";
	list[1] = Color.BLUE;
	name[1] = "BLU";
	list[2] = Color.MAGENTA;
	name[2] = "MAGENTA";
	list[3] = Color.GREEN;
	name[3] = "VERDE";
	list[4] = Color.BLACK;
	name[4] = "NERO";
	list[5] = Color.YELLOW;
	name[5] = "GIALLO";
	list[6] = Color.PINK;
	name[6] = "ROSA";
	list[7] = Color.CYAN;
	name[7] = "AZZURRO";
	list[8] = Color.ORANGE;
	name[8] = "ARANCIONE";
	list[9] = Color.GRAY;
	name[9] = "GRIGIO";
	list[10] = new Color(155, 0, 0);
	name[10] = "ROSSO SCURO";
	list[11] = new Color(94, 0, 2);
	name[11] = "MARRONE";
	list[12] = new Color(242, 129, 252);
	name[12] = "VIOLA CHIARO";
	list[13] = new Color(129, 69, 135);
	name[13] = "VIOLA SCURO";
	list[14] = new Color(141, 141, 254);
	name[14] = "BLU CHIARO";
	list[15] = new Color(1, 1, 109);
	name[15] = "BLU SCURO";
	list[16] = new Color(3, 124, 146);
	name[16] = "AZZURRO SCURO";
	list[17] = new Color(83, 172, 105);
	name[17] = "VERDINO";
	list[18] = new Color(33, 116, 35);
	name[18] = "VERDE SCURO";
	list[19] = new Color(128, 206, 49);
	name[19] = "VERDACCIO";
	list[20] = new Color(170, 162, 55);
	name[20] = "ORO";
	list[21] = new Color(191, 156, 34);
	name[21] = "OCRA";
	list[22] = new Color(255, 0, 128);
	name[22] = "ROSACCIO";
	list[23] = new Color(198, 50, 50);
	name[23] = "ROSSO N�2";
	list[24] = new Color(99, 55, 137);
	name[24] = "VIOLA SCURO N�2";
	list[25] = new Color(99, 55, 137).brighter();
	name[25] = "ROSSO N�3";
	list[26] = new Color(129, 69, 135).brighter();
	name[26] = "VIOLA SCURO N�2";
	list[27] = new Color(141, 141, 254).darker();
	name[27] = "BLU CHIARO N�2";
	list[28] = new Color(1, 1, 109).brighter().brighter();
	name[28] = "BLU SCURO N�2";
	list[29] = new Color(3, 124, 146).brighter();
	name[29] = "AZZURRO SCURO N�2";
	list[30] = new Color(83, 172, 105).darker();
	name[30] = "VERDINO N�2";
	list[31] = new Color(33, 116, 35).brighter();
	name[31] = "VERDE SCURO N�2";
	list[32] = new Color(128, 206, 49).brighter();
	name[32] = "VERDACCIO N�2";
	list[33] = new Color(170, 162, 55).brighter();
	name[33] = "ORO N�2";
	list[34] = new Color(191, 156, 34).darker();
	name[34] = "OCRA N�2";
	list[35] = new Color(255, 0, 128).brighter();
	name[35] = "ROSACCIO N�2";
	list[36] = new Color(198, 50, 50).darker().darker();
	name[36] = "ROSSO N�4";
	list[37] = new Color(99, 55, 137).brighter().brighter();
	name[37] = "VIOLA SCURO N�3";

}
 
开发者ID:HOMlab,项目名称:QN-ACTR-Release,代码行数:80,代码来源:JavaWatColor.java

示例11: getForegroundColor

/**
 * @return The foreground color
 */
protected final Color getForegroundColor(){
	return customColors ? foreground : Color.CYAN;
}
 
开发者ID:RoanH,项目名称:KeysPerSecond,代码行数:6,代码来源:Configuration.java

示例12: getColor2

protected Color getColor2(Edge e)
{
    return pi.isPicked(e)? Color.CYAN : c2;
}
 
开发者ID:dev-cuttlefish,项目名称:cuttlefish,代码行数:4,代码来源:PluggableRendererDemo.java

示例13: addArtefactsAmbiguities

public void addArtefactsAmbiguities(List<Geometry> artGeoms,boolean display){
	super.addGeometries(ARTEFACTS_AMBIGUITY_TAG, Color.CYAN,5, GeometryImage.POINT, artGeoms, display);

}
 
开发者ID:ec-europa,项目名称:sumo,代码行数:4,代码来源:ComplexEditVDSVectorLayer.java


注:本文中的java.awt.Color.CYAN属性示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。