Package com.itextpdf.text

Examples of com.itextpdf.text.Document.newPage()


                try {
                    com.itextpdf.text.Image image2 =
                            com.itextpdf.text.Image.getInstance(bufferedImage, null);
                    image2.scalePercent((float) scaler);
                    document.add(image2);
                    document.newPage();
                    int current = cpt.incrementAndGet();
                    int nbSlides = profile.getSlideCount();
                    System.out.println("Exported slide " + current + (nbSlides > 0 ? "/" + nbSlides : ""));
                    if (!profile.isLastSlide(current)) {
                        profile.nextSlide();
View Full Code Here


            page = getPage(writer, reader, i++);
            if (page != null)
                cb.addTemplate(page, right, bottom);

            doc.newPage();
        }
        doc.close();
    }

    private static void splitLine(Document doc, PdfWriter writer) {
View Full Code Here

            page = getPage(writer, reader, pages[i++]);
            if (page != null)
                cb.addTemplate(page, right, bottom);

            doc.newPage();
        }
        doc.close();
    }

    public static void main(String[] args) {
View Full Code Here

            PdfImportedPage page;
            float offsetX;
            for (int p = 1; p <= total; p++) {
                offsetX = 0;
                if (p % 2 != 0) {
                    document.newPage();
                } else {
                    offsetX = pageSize.getWidth();
                }
                page = writer.getImportedPage(reader, p);
                cb.addTemplate(page, offsetX, 0);
View Full Code Here

      document.open();
      addMetaData(document);
     
      for(int i = 0; i < persAndAusgezID.length; i++){
        if(i > 0)
          document.newPage();
          ResultSet rs = DataMgr.getInstance().getResultSet("" +
              "SELECT "+
              ""+
              "`gehaltausgezahlt`.`BuchungsDat`, "+
              "`gehaltausgezahlt`.`GehBrutto`, "+
View Full Code Here

    int pageCount = TiffImage.getNumberOfPages(ra);
    for (int i = 0; i < pageCount; ++i) {
      Image img = TiffImage.getTiffImage(ra, i + 1);
      if (img != null) {
        if (i != 0) {
          document.newPage();
        }
        if (img.getWidth() > PageSize.A4.getWidth() || img.getHeight() > PageSize.A4.getHeight()) {
          img.scaleToFit(PageSize.A4.getWidth(), PageSize.A4.getHeight());
        }
        document.add(img);
View Full Code Here

    for (int i = 0; i < pageCount; ++i) {
      God.appWindow.getStatusBar().setInitProgress(i, pageCount);
      Image img = TiffImage.getTiffImage(ra, i + 1);
      if (img != null) {
        if (i != 0) {
          document.newPage();
        }
        if (img.getWidth() > PageSize.A4.getWidth() || img.getHeight() > PageSize.A4.getHeight()) {
          img.scaleToFit(PageSize.A4.getWidth(), PageSize.A4.getHeight());
        }
        document.add(img);
View Full Code Here

      document.addTitle(title);
      document.open();
     
      for (JFreeChart chart : charts) {
        addChartToPDF(chart, rect, writer);       
        document.newPage();
      }
    } catch (DocumentException de) {
      System.err.println(de.getMessage());
    }
    document.close();
View Full Code Here

     
      for (int i=0; i<2;i++) {
        addChartToPDF2(charts1.get(i), writer, 1-i, 0);       
        addChartToPDF2(charts2.get(i), writer, 1-i, 1);       
      }
      document.newPage();
      for (int i=0; i<2;i++) {
        addChartToPDF2(charts1.get(i+2), writer, 1-i, 0);       
        addChartToPDF2(charts2.get(i+2), writer, 1-i, 1);       
      }
      document.newPage();
View Full Code Here

      document.newPage();
      for (int i=0; i<2;i++) {
        addChartToPDF2(charts1.get(i+2), writer, 1-i, 0);       
        addChartToPDF2(charts2.get(i+2), writer, 1-i, 1);       
      }
      document.newPage();
      for (int i=0; i<2;i++) {
        addChartToPDF2(charts1.get(i+4), writer, 1-i, 0);       
        addChartToPDF2(charts2.get(i+4), writer, 1-i, 1);       
      }
      document.newPage();
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.