Package net.sf.jasperreports.engine.design

Examples of net.sf.jasperreports.engine.design.JRDesignBand.addElement()


  }
 
  private void addLastPageFooter(SpreadSheetFieldArray fields) throws JRException {
    JRDesignBand band = getAggregatableFooter(fields);
    band.addElement(getPageFooter());
   
    jasperDesign.setLastPageFooter(band);
  }
  private void addPageFooter() throws JRException {
    //page footer
View Full Code Here


    JRDesignLine line = new JRDesignLine();
    line.setX(0);
    line.setY(0);
    line.setWidth(968);
    line.setHeight(0);
    band.addElement(line);
   
    band.addElement(getPageFooter());
    jasperDesign.setPageFooter(band);
  }
 
View Full Code Here

    line.setY(0);
    line.setWidth(968);
    line.setHeight(0);
    band.addElement(line);
   
    band.addElement(getPageFooter());
    jasperDesign.setPageFooter(band);
  }
 
  public void generateDesign(SpreadSheetFieldArray fieldArray) throws JRException {
    hasAggregableField = false;
View Full Code Here

        staticText.setHeight(15);
        staticText.setTextAlignment(JRTextElement.TEXT_ALIGN_RIGHT);
        staticText.setFont(normalFont);
        staticText.setText(interval.getText1());
        staticText.setPrintWhenDetailOverflows(true);
        columnHeader.addElement(staticText);

        // add textFields
        JRDesignBand detailBand = (JRDesignBand) design.getDetail();
 
        JRDesignTextField textField = new JRDesignTextField();
View Full Code Here

        JRDesignExpression expression = new JRDesignExpression();
        expression.setValueClass(fieldType);
        expression.setText("$F{" + fieldName + "}");
        textField.setExpression(expression);
        textField.setPrintWhenDetailOverflows(true);
        detailBand.addElement(textField);
        maxX += 80;
      }

    } catch (JRException e) {
      // TODO Auto-generated catch block
View Full Code Here

    int offset = LayoutUtils.findVerticalOffset(band);
    text.setY(offset);
    applyStyleToElement(style, text);
    text.setWidth(getReport().getOptions().getPrintableWidth());
    text.setHeight(50);
    band.addElement(text);
    log.debug("OK setting up WHEN NO DATA band");

  }

  protected void startLayout() {
View Full Code Here

        image.setOnErrorType(JRDesignImage.ON_ERROR_TYPE_ICON); //FIXME should we provide control of this to the user?

        applyStyleToElement(column.getStyle(), image);

        detail.addElement(image);
      }
      /**
       * Image columns
       */
      else if (column instanceof ImageColumn) {
View Full Code Here

        image.setX(column.getPosX().intValue());
        image.setScaleImage(imageColumn.getScaleMode().getValue());

        applyStyleToElement(column.getStyle(), image);

        detail.addElement(image);
      }
      /**
       * Regular Column
       */
      else {
View Full Code Here

      else {
        JRDesignTextField textField = generateTextFieldFromColumn(column, getReport().getOptions().getDetailHeight().intValue(), null);
        transformDetailBandTextField(column, textField);
       
        if (textField.getExpression() != null)
          detail.addElement(textField);
       
//        if (column.getConditionalStyles() != null && !column.getConditionalStyles().isEmpty() ){
//          for (Iterator iterator = column.getConditionalStyles().iterator(); iterator.hasNext();) {
//            ConditionalStyle condition = (ConditionalStyle) iterator.next();
//            JRDesignTextField textField = generateTextFieldFromColumn(column, getReport().getOptions().getDetailHeight().intValue(), null);
View Full Code Here

        DJChart djChart = (DJChart) l.get(i-1);
        JRDesignChart chart = createChart(djChart);

        //Charts has their own band, so they are added in the band at Y=0
        JRDesignBand band = createGroupForChartAndGetBand(djChart);
        band.addElement(chart);
      }
    }
  }

  protected JRDesignBand createGroupForChartAndGetBand(DJChart djChart) {
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.