Package org.pentaho.reporting.designer.core.editor.report.drag

Examples of org.pentaho.reporting.designer.core.editor.report.drag.MoveDragOperation


      }

      carrier.set(0, reportElement);
      final Point2D.Double originPoint = new Point2D.Double(0, StrictGeomUtility.toExternalValue(layoutData.getY()));

      final MoveDragOperation mop = new MoveDragOperation
          (carrier, originPoint, EmptySnapModel.INSTANCE, EmptySnapModel.INSTANCE);
      mop.update(new Point2D.Double(0, StrictGeomUtility.toExternalValue(delta)), 1);
      mop.finish();

      currentY += incr;
    }
    final MassElementStyleUndoEntry massElementStyleUndoEntry = builder.finish();
    getActiveContext().getUndo().addChange(ActionMessages.getString("DistributeMiddleAction.UndoName"), massElementStyleUndoEntry);
View Full Code Here


      final CachedLayoutData layoutData = ModelUtility.getCachedLayoutData(reportElement);
      final long height = layoutData.getWidth();

      carrier[0] = reportElement;
      final Point2D.Double originPoint = new Point2D.Double(StrictGeomUtility.toExternalValue(layoutData.getX()), 0);
      final MoveDragOperation mop = new MoveDragOperation
          (Arrays.asList(carrier), originPoint, EmptySnapModel.INSTANCE, EmptySnapModel.INSTANCE);
      mop.update(new Point2D.Double(StrictGeomUtility.toExternalValue(currentY), 0), 1);
      mop.finish();

      currentY += height + gap;
    }
    final MassElementStyleUndoEntry massElementStyleUndoEntry = builder.finish();
    getActiveContext().getUndo().addChange(ActionMessages.getString("DistributeHorizontalJustifyAction.UndoName"), massElementStyleUndoEntry);
View Full Code Here

    {
      final CachedLayoutData layoutData = ModelUtility.getCachedLayoutData(reportElement);

      carrier[0] = reportElement;
      final Point2D.Double originPoint = new Point2D.Double(0, StrictGeomUtility.toExternalValue(layoutData.getY()));
      final MoveDragOperation mop =
          new MoveDragOperation(Arrays.asList(carrier), originPoint, EmptySnapModel.INSTANCE, EmptySnapModel.INSTANCE);
      mop.update(new Point2D.Double(0, StrictGeomUtility.toExternalValue(currentY)), 1);
      mop.finish();

      currentY += incr;
    }
    final MassElementStyleUndoEntry massElementStyleUndoEntry = builder.finish();
    getActiveContext().getUndo().addChange(ActionMessages.getString("DistributeTopAction.UndoName"), massElementStyleUndoEntry);
View Full Code Here

      final CachedLayoutData layoutData = ModelUtility.getCachedLayoutData(reportElement);
      final long height = layoutData.getHeight();

      carrier[0] = reportElement;
      final Point2D.Double originPoint = new Point2D.Double(StrictGeomUtility.toExternalValue(layoutData.getX()), 0);
      final MoveDragOperation mop = new MoveDragOperation
          (Arrays.asList(carrier), originPoint, EmptySnapModel.INSTANCE, EmptySnapModel.INSTANCE);
      mop.update(new Point2D.Double(0, StrictGeomUtility.toExternalValue(currentY)), 1);
      mop.finish();

      currentY += height + gap;
    }
    final MassElementStyleUndoEntry massElementStyleUndoEntry = builder.finish();
    getActiveContext().getUndo().addChange(ActionMessages.getString("DistributeVerticalJustifyAction.UndoName"), massElementStyleUndoEntry);
View Full Code Here

        continue;
      }

      carrier[0] = reportElement;
      final Point2D.Double originPoint = new Point2D.Double(StrictGeomUtility.toExternalValue(layoutData.getX()), 0);
      final MoveDragOperation mop = new MoveDragOperation
          (Arrays.asList(carrier), originPoint, EmptySnapModel.INSTANCE, EmptySnapModel.INSTANCE);
      mop.update(new Point2D.Double(StrictGeomUtility.toExternalValue(delta), 0), 1);
      mop.finish();

      currentY += incr;
    }
    final MassElementStyleUndoEntry massElementStyleUndoEntry = builder.finish();
    getActiveContext().getUndo().addChange(ActionMessages.getString("DistributeRightAction.UndoName"), massElementStyleUndoEntry);
View Full Code Here

    registerChanges();
  }

  private void align(final int theShiftValue, final Element[] elements)
  {
    final MoveDragOperation mop =
        new MoveDragOperation(elements, new Point(), EmptySnapModel.INSTANCE, EmptySnapModel.INSTANCE);
    mop.update(new Point(theShiftValue, 0), 1);
    mop.finish();
  }
View Full Code Here

        continue;
      }

      carrier[0] = reportElement;
      final Point2D.Double originPoint = new Point2D.Double(0, StrictGeomUtility.toExternalValue(layoutData.getY()));
      final MoveDragOperation mop = new MoveDragOperation
          (carrier, originPoint, EmptySnapModel.INSTANCE, EmptySnapModel.INSTANCE);
      mop.update(new Point2D.Double(0, StrictGeomUtility.toExternalValue(delta)), 1);
      mop.finish();

      currentY += incr;
    }
    final MassElementStyleUndoEntry massElementStyleUndoEntry = builder.finish();
    getActiveContext().getUndo().addChange(ActionMessages.getString("DistributeBottomAction.UndoName"), massElementStyleUndoEntry);
View Full Code Here

    {
      final Element reportElement = reportElements[i];
      carrier[0] = reportElement;
      final CachedLayoutData layoutData = ModelUtility.getCachedLayoutData(reportElement);
      final Point2D.Double originPoint = new Point2D.Double(StrictGeomUtility.toExternalValue(layoutData.getX()), 0);
      final MoveDragOperation mop = new MoveDragOperation
          (carrier, originPoint, EmptySnapModel.INSTANCE, EmptySnapModel.INSTANCE);
      mop.update(new Point2D.Double(StrictGeomUtility.toExternalValue(currentY), 0), 1);
      mop.finish();

      currentY += incr;
    }
    final MassElementStyleUndoEntry massElementStyleUndoEntry = builder.finish();
    getActiveContext().getUndo().addChange(ActionMessages.getString("DistributeLeftAction.UndoName"), massElementStyleUndoEntry);
View Full Code Here

      }

      carrier[0] = reportElement;
      final Point2D.Double originPoint = new Point2D.Double(0, StrictGeomUtility.toExternalValue(layoutData.getY()));

      final MoveDragOperation mop = new MoveDragOperation
          (carrier, originPoint, EmptySnapModel.INSTANCE, EmptySnapModel.INSTANCE);
      mop.update(new Point2D.Double(0, StrictGeomUtility.toExternalValue(delta)), 1);
      mop.finish();

      currentY += incr;
    }
    final MassElementStyleUndoEntry massElementStyleUndoEntry = builder.finish();
    getActiveContext().getUndo().addChange(ActionMessages.getString("DistributeMiddleAction.UndoName"), massElementStyleUndoEntry);
View Full Code Here

      final CachedLayoutData layoutData = ModelUtility.getCachedLayoutData(reportElement);
      final long height = layoutData.getWidth();

      carrier[0] = reportElement;
      final Point2D.Double originPoint = new Point2D.Double(StrictGeomUtility.toExternalValue(layoutData.getX()), 0);
      final MoveDragOperation mop = new MoveDragOperation
          (carrier, originPoint, EmptySnapModel.INSTANCE, EmptySnapModel.INSTANCE);
      mop.update(new Point2D.Double(StrictGeomUtility.toExternalValue(currentY), 0), 1);
      mop.finish();

      currentY += height + gap;
    }
    final MassElementStyleUndoEntry massElementStyleUndoEntry = builder.finish();
    getActiveContext().getUndo().addChange(ActionMessages.getString("DistributeHorizontalJustifyAction.UndoName"), massElementStyleUndoEntry);
View Full Code Here

TOP

Related Classes of org.pentaho.reporting.designer.core.editor.report.drag.MoveDragOperation

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.