Package org.pentaho.reporting.designer.core.model.lineal

Examples of org.pentaho.reporting.designer.core.model.lineal.LinealModel


    public void actionPerformed(final ActionEvent e)
    {
      final GuideLine newGuideLine = new GuideLine(oldGuideLine.getPosition(), true);
      final UndoManager undo = getRenderContext().getUndo();
      final LinealModel linealModel = getLinealModel();
      undo.addChange(new UpdateHorizontalGuidelineUndoEntry(index, newGuideLine, oldGuideLine));
      linealModel.updateGuideLine(index, newGuideLine);
    }
View Full Code Here


      this.guideLine = guideLine;
    }

    public void actionPerformed(final ActionEvent e)
    {
      final LinealModel linealModel = getLinealModel();
      final UndoManager undo = getRenderContext().getUndo();
      undo.addChange(new RemoveHorizontalGuidelineUndoEntry(guideLine));
      linealModel.removeGuideLine(guideLine);
    }
View Full Code Here

  public void undo(final ReportRenderContext context)
  {
    final AbstractReportDefinition abstractReportDefinition = context.getReportDefinition();
    final Band band = (Band) ModelUtility.findElementById(abstractReportDefinition, id);
    final LinealModel linealModel = ModelUtility.getVerticalLinealModel(band);
    linealModel.removeGuideLine(guideLine);
  }
View Full Code Here

  public void redo(final ReportRenderContext context)
  {
    final AbstractReportDefinition abstractReportDefinition = context.getReportDefinition();
    final Band band = (Band) ModelUtility.findElementById(abstractReportDefinition, id);
    final LinealModel linealModel = ModelUtility.getVerticalLinealModel(band);
    linealModel.addGuidLine(guideLine);
  }
View Full Code Here

  public void undo(final ReportRenderContext context)
  {
    final AbstractReportDefinition abstractReportDefinition = context.getReportDefinition();
    final Band band = (Band) ModelUtility.findElementById(abstractReportDefinition, id);
    final LinealModel linealModel = ModelUtility.getVerticalLinealModel(band);
    linealModel.addGuidLine(guideLine);
  }
View Full Code Here

  public void redo(final ReportRenderContext context)
  {
    final AbstractReportDefinition abstractReportDefinition = context.getReportDefinition();
    final Band band = (Band) ModelUtility.findElementById(abstractReportDefinition, id);
    final LinealModel linealModel = ModelUtility.getVerticalLinealModel(band);
    linealModel.removeGuideLine(guideLine);
  }
View Full Code Here

    this.renderContext = renderContext;
    this.renderContext.getMasterReportElement().addReportModelListener(new PageFormatUpdateHandler());
    this.changeHandler = new RootBandChangeHandler();
    this.showTopBorder = showTopBorder;
    this.zoomModel = renderContext.getZoomModel();
    this.linealModel = new LinealModel();
    this.linealUpdateHandler = new LinealUpdateHandler();
    this.linealModel.addLinealModelListener(linealUpdateHandler);
    this.renderContext.getZoomModel().addZoomModelListener(changeHandler);

    final DragAndDropHandler andDropHandler = new DragAndDropHandler();
View Full Code Here

    this.reportElement = reportElement;
    this.pageDefinition = pageDefinition;
    if (reportElement == null)
    {
      this.linealModel = new LinealModel();
      this.name = null;
    }
    else
    {
      this.linealModel = reportElement.getVerticalLinealModel();
View Full Code Here

      this.index = index;
    }

    public void actionPerformed(final ActionEvent e)
    {
      final LinealModel linealModel = getLinealModel();
      if (linealModel == null)
      {
        return;
      }

      final GuideLineDialog spinnerDialog;
      final Component parent = VerticalLinealComponent.this;
      final Window window = SwingUtil.getWindowAncestor(parent);
      if (window instanceof JDialog)
      {
        spinnerDialog = new GuideLineDialog((JDialog) window);
      }
      else if (window instanceof JFrame)
      {
        spinnerDialog = new GuideLineDialog((JFrame) window);
      }
      else
      {
        spinnerDialog = new GuideLineDialog();
      }

      spinnerDialog.setUnit(WorkspaceSettings.getInstance().getUnit());
      spinnerDialog.setPosition(guideLine.getPosition());

      spinnerDialog.pack();
      SwingUtil.centerDialogInParent(spinnerDialog);
      if (spinnerDialog.showDialog())
      {
        final GuideLine newGuideLine = new GuideLine(spinnerDialog.getPosition(), guideLine.isActive());
        linealModel.updateGuideLine(index, newGuideLine);
        this.guideLine = newGuideLine;
      }

    }
View Full Code Here

    }

    public void actionPerformed(final ActionEvent e)
    {
      final GuideLine newGuideLine = new GuideLine(guideLine.getPosition(), false);
      final LinealModel linealModel = getLinealModel();
      final UndoManager undo = getRenderContext().getUndo();
      undo.addChange(new UpdateVerticalGuidelineUndoEntry(index, newGuideLine, guideLine, getInstanceID()));
      linealModel.updateGuideLine(index, newGuideLine);
    }
View Full Code Here

TOP

Related Classes of org.pentaho.reporting.designer.core.model.lineal.LinealModel

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.