Package org.eclipse.graphiti.mm.algorithms.styles

Examples of org.eclipse.graphiti.mm.algorithms.styles.Color


    for (ContainerShape band : ChoreographyUtil.getParticipantBandContainerShapes(container)) {
      Participant participant = BusinessObjectUtil.getFirstElementOfType(band, Participant.class);
      boolean isInitiating = hasInitiatingParticipant
          && participant.equals(choreography.getInitiatingParticipantRef());
      Color color = manageColor(isInitiating ? IColorConstant.WHITE : IColorConstant.LIGHT_GRAY);
      band.getGraphicsAlgorithm().setBackground(color);
      BPMNShape bpmnShape = BusinessObjectUtil.getFirstElementOfType(band, BPMNShape.class);
      bpmnShape.setParticipantBandKind(getParticipantBandKind(isInitiating, bpmnShape.getParticipantBandKind()));
    }
View Full Code Here


      if (retRgb == null) {
        return null;
      }

      Diagram diagram = (Diagram) color.eContainer();
      Color newColor = Graphiti.getGaService().manageColor(diagram, retRgb.red, retRgb.green, retRgb.blue);
      return newColor;

    }

    return null;
View Full Code Here

    gcas.add(gca);
    gca.setStart(StylesFactory.eINSTANCE.createGradientColoredLocation());
   
    IGaService gaService = Graphiti.getGaService();
   
    final Color startColor = gaService.manageColor(diagram, ColorUtil.getRedFromHex(colorStart)
                          , ColorUtil.getGreenFromHex(colorStart)
                          , ColorUtil.getBlueFromHex(colorStart));
    gca.getStart().setColor(startColor);
   
//    gca.getStart().setColor(StylesFactory.eINSTANCE.createColor());
//    gca.getStart().getColor().setBlue(ColorUtil.getBlueFromHex(colorStart));
//    gca.getStart().getColor().setGreen(ColorUtil.getGreenFromHex(colorStart));
//    gca.getStart().getColor().setRed(ColorUtil.getRedFromHex(colorStart));
    gca.getStart().setLocationType(locationTypeStart);
    gca.getStart().setLocationValue(locationValueStart);
    gca.setEnd(StylesFactory.eINSTANCE.createGradientColoredLocation());
   
    final Color endColor = gaService.manageColor(diagram, ColorUtil.getRedFromHex(colorEnd)
      , ColorUtil.getGreenFromHex(colorEnd)
      , ColorUtil.getBlueFromHex(colorEnd));
   
    gca.getEnd().setColor(endColor);
    gca.getEnd().setLocationType(locationTypeEnd);
View Full Code Here

TOP

Related Classes of org.eclipse.graphiti.mm.algorithms.styles.Color

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.