here's my patch :


Index: pom.xml
===================================================================
--- pom.xml (revision 1173)
+++ pom.xml (working copy)
@@ -356,9 +356,14 @@
       <dependency>
         <groupId>com.lowagie</groupId>
         <artifactId>itext</artifactId>
- <version>1.3</version>
+ <version>2.1.7</version>
       </dependency>
       <dependency>
+ <groupId>com.lowagie</groupId>
+ <artifactId>itext-rtf</artifactId>
+ <version>2.1.7</version>
+ </dependency>
+ <dependency>
         <groupId>taglibs</groupId>
         <artifactId>standard</artifactId>
         <version>1.0.6</version>
Index: displaytag/pom.xml
===================================================================
--- displaytag/pom.xml (revision 1173)
+++ displaytag/pom.xml (working copy)
@@ -77,6 +77,10 @@
     </dependency>
     <dependency>
       <groupId>com.lowagie</groupId>
+ <artifactId>itext-rtf</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>com.lowagie</groupId>
       <artifactId>itext</artifactId>
     </dependency>
       <dependency>
Index: displaytag-examples/src/main/java/org/displaytag/sample/decorators/ItextTotalWrapper.java
===================================================================
--- displaytag-examples/src/main/java/org/displaytag/sample/decorators/ItextTotalWrapper.java (revision 1173)
+++ displaytag-examples/src/main/java/org/displaytag/sample/decorators/ItextTotalWrapper.java (working copy)
@@ -68,7 +68,7 @@
      */
     public String startRow()
     {
- this.table.setDefaultCellBorder(Rectangle.BOTTOM);
+ this.table.getDefaultCell().setBorder(Rectangle.BOTTOM);
         return null;
     }
 
@@ -102,8 +102,8 @@
         {
             try
             {
- this.font = FontFactory.getFont(this.font.getFamilyname(), this.font.size(), Font.BOLD, this.font
- .color());
+ this.font = FontFactory.getFont(this.font.getFamilyname(), this.font.getSize(), Font.BOLD, this.font
+ .getColor());
                 table.addCell(this.getCell(""));
                 table.addCell(this.getCell(""));
                 table.addCell(this.getCell("-------------"));
Index: displaytag/src/main/java/org/displaytag/export/DefaultPdfExportView.java
===================================================================
--- displaytag/src/main/java/org/displaytag/export/DefaultPdfExportView.java (revision 1173)
+++ displaytag/src/main/java/org/displaytag/export/DefaultPdfExportView.java (working copy)
@@ -87,7 +87,7 @@
             cb.saveState();
             // write the headertable
             table.setTotalWidth(document.right() - document.left());
- table.writeSelectedRows(0, -1, document.left(), document.getPageSize().height() - 50, cb);
+ table.writeSelectedRows(0, -1, document.left(), document.getPageSize().getHeight() - 50, cb);
             // compose the footer
             String text = "Page " + writer.getPageNumber();
             float textSize = helv.getWidthPoint(text, 12);
Index: displaytag/src/main/java/org/displaytag/export/PdfView.java
===================================================================
--- displaytag/src/main/java/org/displaytag/export/PdfView.java (revision 1173)
+++ displaytag/src/main/java/org/displaytag/export/PdfView.java (working copy)
@@ -105,7 +105,7 @@
     protected void initTable() throws BadElementException
     {
         tablePDF = new Table(this.model.getNumberOfColumns());
- tablePDF.setDefaultVerticalAlignment(Element.ALIGN_TOP);
+ tablePDF.getDefaultCell().setVerticalAlignment(Element.ALIGN_TOP);
         tablePDF.setCellsFitPage(true);
         tablePDF.setWidth(100);
 
Index: displaytag/src/main/java/org/displaytag/render/ItextTableWriter.java
===================================================================
--- displaytag/src/main/java/org/displaytag/render/ItextTableWriter.java (revision 1173)
+++ displaytag/src/main/java/org/displaytag/render/ItextTableWriter.java (working copy)
@@ -78,7 +78,7 @@
      */
     protected void writeTableOpener(TableModel model)
     {
- this.table.setDefaultVerticalAlignment(Element.ALIGN_TOP);
+ this.table.getDefaultCell().setVerticalAlignment(Element.ALIGN_TOP);
         this.table.setCellsFitPage(true);
         this.table.setWidth(100);
         this.table.setPadding(2);
@@ -372,8 +372,8 @@
      */
     private void setBoldStyle(Chunk chunk, Color color)
     {
- Font font = chunk.font();
- chunk.setFont(FontFactory.getFont(font.getFamilyname(), font.size(), Font.BOLD, color));
+ Font font = chunk.getFont();
+ chunk.setFont(FontFactory.getFont(font.getFamilyname(), font.getSize(), Font.BOLD, color));
     }
 
     /**
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators.
For more information on JIRA, see: http://www.atlassian.com/software/jira
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
displaytag-devel mailing list
displaytag-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/displaytag-devel

Reply via email to