Package org.eclipse.graphiti.mm.algorithms

Examples of org.eclipse.graphiti.mm.algorithms.Image


    {
      // create shape for image
      final Shape shape = peCreateService.createShape(containerShape, false);

      // create and set image
      final Image image = gaService.createImage(shape, ImageProvider.getKeyForLargeIcon(addedClass.getIconName()));
      gaService.setLocationAndSize(image, imageRect.x, imageRect.y, imageRect.width, imageRect.height);

      // if addedClass has no resource we add it to the resource of the diagram
      // in a real scenario the business model would have its own resource
//      if (addedClass.eResource() == null) {
View Full Code Here


          globalTaskShape = peService.createShape(container, false);
          peService.setPropertyValue(globalTaskShape, GLOBAL_TASK_SHAPE_PROPERTY, Boolean.toString(true));
        }
        String imageId = getImageId(t);
        if (imageId != null) {
          Image image = gaService.createImage(globalTaskShape, imageId);
          gaService.setLocationAndSize(image, MARKER_OFFSET + 2, MARKER_OFFSET + 2, 16, 16);
        }
      }

      else if (callActivity.getCalledElementRef() instanceof Process) {
View Full Code Here

  public IAddFeature getAddFeature(IFeatureProvider fp) {
    return new AddTaskFeature(fp) {
      @Override
      protected void decorateActivityRectangle(RoundedRectangle rect) {
        IGaService service = Graphiti.getGaService();
        Image img = service.createImage(rect, ImageProvider.IMG_16_SCRIPT_TASK);
        service.setLocationAndSize(img, 2, 2, GraphicsUtil.TASK_IMAGE_SIZE, GraphicsUtil.TASK_IMAGE_SIZE);
      }
    };
  }
View Full Code Here

  public IAddFeature getAddFeature(IFeatureProvider fp) {
    return new AddTaskFeature(fp) {
      @Override
      protected void decorateActivityRectangle(RoundedRectangle rect) {
        IGaService service = Graphiti.getGaService();
        Image img = service.createImage(rect, ImageProvider.IMG_16_BUSINESS_RULE_TASK);
        service.setLocationAndSize(img, 2, 2, 16, 16);
      }

      @Override
      protected int getWidth() {
View Full Code Here

  public IAddFeature getAddFeature(IFeatureProvider fp) {
    return new AddTaskFeature(fp) {
      @Override
      protected void decorateActivityRectangle(RoundedRectangle rect) {
        IGaService service = Graphiti.getGaService();
        Image img = service.createImage(rect, ImageProvider.IMG_16_USER_TASK);
        service.setLocationAndSize(img, 2, 2, GraphicsUtil.TASK_IMAGE_SIZE, GraphicsUtil.TASK_IMAGE_SIZE);
      }
    };
  }
View Full Code Here

  public IAddFeature getAddFeature(IFeatureProvider fp) {
    return new AddTaskFeature(fp) {
      @Override
      protected void decorateActivityRectangle(RoundedRectangle rect) {
        IGaService service = Graphiti.getGaService();
        Image img = service.createImage(rect, ImageProvider.IMG_16_SEND_TASK);
        service.setLocationAndSize(img, 2, 2, GraphicsUtil.TASK_IMAGE_SIZE, GraphicsUtil.TASK_IMAGE_SIZE);
      }
    };
  }
View Full Code Here

  public IAddFeature getAddFeature(IFeatureProvider fp) {
    return new AddTaskFeature(fp) {
      @Override
      protected void decorateActivityRectangle(RoundedRectangle rect) {
        IGaService service = Graphiti.getGaService();
        Image img = service.createImage(rect, ImageProvider.IMG_16_SERVICE_TASK);
        service.setLocationAndSize(img, 2, 2, GraphicsUtil.TASK_IMAGE_SIZE, GraphicsUtil.TASK_IMAGE_SIZE);
      }
    };
  }
View Full Code Here

  public IAddFeature getAddFeature(IFeatureProvider fp) {
    return new AddTaskFeature(fp) {
      @Override
      protected void decorateActivityRectangle(RoundedRectangle rect) {
        IGaService service = Graphiti.getGaService();
        Image img = service.createImage(rect, ImageProvider.IMG_16_RECEIVE_TASK);
        service.setLocationAndSize(img, 2, 2, GraphicsUtil.TASK_IMAGE_SIZE, GraphicsUtil.TASK_IMAGE_SIZE);
      }
    };
  }
View Full Code Here

    circle.setFilled(false);
    return circle;
  }

  public static Image createEventImage(Shape shape, String imageId) {
    Image image = gaService.createImage(shape, imageId);
    gaService.setLocationAndSize(image, 8, 8, 20, 20);
    return image;
  }
View Full Code Here

    return new AddTaskFeature(fp) {

      @Override
      protected void decorateActivityRectangle(RoundedRectangle rect) {
        IGaService service = Graphiti.getGaService();
        Image img = service.createImage(rect, ImageProvider.IMG_16_SEND_TASK);
        service.setLocationAndSize(img, 2, 2, GraphicsUtil.TASK_IMAGE_SIZE, GraphicsUtil.TASK_IMAGE_SIZE);
      }
    };
  }
View Full Code Here

TOP

Related Classes of org.eclipse.graphiti.mm.algorithms.Image

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.