Package org.eclipse.gmf.runtime.notation

Examples of org.eclipse.gmf.runtime.notation.Location


  public View createView(IAdaptable semanticAdapter, View containerView,
      String semanticHint, int index, boolean persisted,
      PreferencesHint preferencesHint) {
    Node view = (Node) super.createView(semanticAdapter, containerView,
        semanticHint, index, persisted, preferencesHint);
    Location location = (Location) view.getLayoutConstraint();
    IMapMode mapMode = MeasurementUnitHelper.getMapMode(containerView
        .getDiagram().getMeasurementUnit());
    location.setX(mapMode.DPtoLP(0));
    location.setY(mapMode.DPtoLP(40));
    return view;
  }
View Full Code Here


  public View createView(IAdaptable semanticAdapter, View containerView,
      String semanticHint, int index, boolean persisted,
      PreferencesHint preferencesHint) {
    Node view = (Node) super.createView(semanticAdapter, containerView,
        semanticHint, index, persisted, preferencesHint);
    Location location = (Location) view.getLayoutConstraint();
    IMapMode mapMode = MeasurementUnitHelper.getMapMode(containerView
        .getDiagram().getMeasurementUnit());
    location.setX(mapMode.DPtoLP(0));
    location.setY(mapMode.DPtoLP(20));
    return view;
  }
View Full Code Here

  public View createView(IAdaptable semanticAdapter, View containerView,
      String semanticHint, int index, boolean persisted,
      PreferencesHint preferencesHint) {
    Node view = (Node) super.createView(semanticAdapter, containerView,
        semanticHint, index, persisted, preferencesHint);
    Location location = (Location) view.getLayoutConstraint();
    IMapMode mapMode = MeasurementUnitHelper.getMapMode(containerView
        .getDiagram().getMeasurementUnit());
    location.setX(mapMode.DPtoLP(0));
    location.setY(mapMode.DPtoLP(120));
    return view;
  }
View Full Code Here

  public View createView(IAdaptable semanticAdapter, View containerView,
      String semanticHint, int index, boolean persisted,
      PreferencesHint preferencesHint) {
    Node view = (Node) super.createView(semanticAdapter, containerView,
        semanticHint, index, persisted, preferencesHint);
    Location location = (Location) view.getLayoutConstraint();
    IMapMode mapMode = MeasurementUnitHelper.getMapMode(containerView
        .getDiagram().getMeasurementUnit());
    location.setX(mapMode.DPtoLP(20));
    location.setY(mapMode.DPtoLP(20));
    return view;
  }
View Full Code Here

  public View createView(IAdaptable semanticAdapter, View containerView,
      String semanticHint, int index, boolean persisted,
      PreferencesHint preferencesHint) {
    Node view = (Node) super.createView(semanticAdapter, containerView,
        semanticHint, index, persisted, preferencesHint);
    Location location = (Location) view.getLayoutConstraint();
    IMapMode mapMode = MeasurementUnitHelper.getMapMode(containerView
        .getDiagram().getMeasurementUnit());
    location.setX(mapMode.DPtoLP(0));
    location.setY(mapMode.DPtoLP(60));
    return view;
  }
View Full Code Here

  public View createView(IAdaptable semanticAdapter, View containerView,
      String semanticHint, int index, boolean persisted,
      PreferencesHint preferencesHint) {
    Node view = (Node) super.createView(semanticAdapter, containerView,
        semanticHint, index, persisted, preferencesHint);
    Location location = (Location) view.getLayoutConstraint();
    IMapMode mapMode = MeasurementUnitHelper.getMapMode(containerView
        .getDiagram().getMeasurementUnit());
    location.setX(mapMode.DPtoLP(0));
    location.setY(mapMode.DPtoLP(40));
    return view;
  }
View Full Code Here

  public View createView(IAdaptable semanticAdapter, View containerView,
      String semanticHint, int index, boolean persisted,
      PreferencesHint preferencesHint) {
    Node view = (Node) super.createView(semanticAdapter, containerView,
        semanticHint, index, persisted, preferencesHint);
    Location location = (Location) view.getLayoutConstraint();
    IMapMode mapMode = MeasurementUnitHelper.getMapMode(containerView
        .getDiagram().getMeasurementUnit());
    location.setX(mapMode.DPtoLP(0));
    location.setY(mapMode.DPtoLP(20));
    return view;
  }
View Full Code Here

  public View createView(IAdaptable semanticAdapter, View containerView,
      String semanticHint, int index, boolean persisted,
      PreferencesHint preferencesHint) {
    Node view = (Node) super.createView(semanticAdapter, containerView,
        semanticHint, index, persisted, preferencesHint);
    Location location = (Location) view.getLayoutConstraint();
    IMapMode mapMode = MeasurementUnitHelper.getMapMode(containerView
        .getDiagram().getMeasurementUnit());
    location.setX(mapMode.DPtoLP(0));
    location.setY(mapMode.DPtoLP(20));
    return view;
  }
View Full Code Here

  public View createView(IAdaptable semanticAdapter, View containerView,
      String semanticHint, int index, boolean persisted,
      PreferencesHint preferencesHint) {
    Node view = (Node) super.createView(semanticAdapter, containerView,
        semanticHint, index, persisted, preferencesHint);
    Location location = (Location) view.getLayoutConstraint();
    IMapMode mapMode = MeasurementUnitHelper.getMapMode(containerView
        .getDiagram().getMeasurementUnit());
    location.setX(mapMode.DPtoLP(0));
    location.setY(mapMode.DPtoLP(80));
    return view;
  }
View Full Code Here

            boundsCommand.add(new SetBoundsCommand(boundsCommand
                .getEditingDomain(), boundsCommand.getLabel(),
                descriptor, new Rectangle(b.getX(), b.getY(), b
                    .getWidth(), b.getHeight())));
          } else if (((Node) originalView).getLayoutConstraint() instanceof Location) {
            Location l = (Location) ((Node) originalView)
                .getLayoutConstraint();
            boundsCommand.add(new SetBoundsCommand(boundsCommand
                .getEditingDomain(), boundsCommand.getLabel(),
                descriptor, new Point(l.getX(), l.getY())));
          } else if (((Node) originalView).getLayoutConstraint() instanceof Size) {
            Size s = (Size) ((Node) originalView)
                .getLayoutConstraint();
            boundsCommand.add(new SetBoundsCommand(boundsCommand
                .getEditingDomain(), boundsCommand.getLabel(),
View Full Code Here

TOP

Related Classes of org.eclipse.gmf.runtime.notation.Location

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.