Upgrade iText Library from 2.1.7 -> 5.0.0

Link to SF Tracker: http://sourceforge.net/support/tracker.php?aid=2923757
This commit is contained in:
mjudd 2009-12-30 20:27:33 +00:00
parent 86f8784db9
commit 76cc5c9642
20 changed files with 163 additions and 155 deletions

View File

@ -135,7 +135,7 @@
<classpathentry exported="true" kind="lib" path="JasperReportsTools/lib/jasperreports-3.5.3.jar"/>
<classpathentry exported="true" kind="lib" path="packages/liberoHR.jar"/>
<classpathentry exported="true" kind="lib" path="packages/liberoMFG.jar"/>
<classpathentry exported="true" kind="lib" path="tools/lib/iText-2.1.7.jar"/>
<classpathentry exported="true" kind="lib" path="tools/lib/miglayout-3.7.1-swing.jar"/>
<classpathentry kind="lib" path="tools/lib/iText-5.0.0.jar"/>
<classpathentry kind="output" path="bin"/>
</classpath>

View File

@ -24,12 +24,12 @@ import java.io.OutputStream;
import org.adempiere.pdf.viewer.PDFViewerBean;
import org.compiere.model.MSysConfig;
import com.lowagie.text.FontFactory;
import com.lowagie.text.Rectangle;
import com.lowagie.text.pdf.DefaultFontMapper;
import com.lowagie.text.pdf.PdfContentByte;
import com.lowagie.text.pdf.PdfTemplate;
import com.lowagie.text.pdf.PdfWriter;
import com.itextpdf.text.FontFactory;
import com.itextpdf.text.Rectangle;
import com.itextpdf.text.pdf.DefaultFontMapper;
import com.itextpdf.text.pdf.PdfContentByte;
import com.itextpdf.text.pdf.PdfTemplate;
import com.itextpdf.text.pdf.PdfWriter;
/**
* Generate PDF document using iText
@ -49,8 +49,8 @@ public class Document {
try {
final PageFormat pf = pageable.getPageFormat(0);
final com.lowagie.text.Document document =
new com.lowagie.text.Document(new Rectangle(
final com.itextpdf.text.Document document =
new com.itextpdf.text.Document(new Rectangle(
(int) pf.getWidth(), (int) pf.getHeight()));
final PdfWriter writer = PdfWriter.getInstance(
document, output);

View File

@ -61,7 +61,7 @@ import org.compiere.util.Util;
import org.jdesktop.swingx.JXCollapsiblePane;
import org.jdesktop.swingx.border.DropShadowBorder;
import com.lowagie.text.Font;
import com.itextpdf.text.Font;
/**
* Single Row Panel.

View File

@ -67,17 +67,18 @@ import org.posterita.lib.UdiConstants;
import org.posterita.util.PathInfo;
import org.posterita.util.PoManager;
import com.lowagie.text.Document;
import com.lowagie.text.DocumentException;
import com.lowagie.text.Element;
import com.lowagie.text.Font;
import com.lowagie.text.FontFactory;
import com.lowagie.text.Image;
import com.lowagie.text.PageSize;
import com.lowagie.text.Phrase;
import com.lowagie.text.pdf.PdfPCell;
import com.lowagie.text.pdf.PdfPTable;
import com.lowagie.text.pdf.PdfWriter;
import com.itextpdf.text.BaseColor;
import com.itextpdf.text.Document;
import com.itextpdf.text.DocumentException;
import com.itextpdf.text.Element;
import com.itextpdf.text.Font;
import com.itextpdf.text.FontFactory;
import com.itextpdf.text.Image;
import com.itextpdf.text.PageSize;
import com.itextpdf.text.Phrase;
import com.itextpdf.text.pdf.PdfPCell;
import com.itextpdf.text.pdf.PdfPTable;
import com.itextpdf.text.pdf.PdfWriter;
public class CustomerManager
{
@ -909,7 +910,7 @@ public class CustomerManager
PdfPTable main = new PdfPTable(2);
main.setWidthPercentage(71.0f);
main.getDefaultCell().setBorderColor(Color.gray);
main.getDefaultCell().setBorderColor(BaseColor.GRAY);
PdfPCell cell = new PdfPCell();
cell.setMinimumHeight(150.0f);

View File

@ -116,17 +116,18 @@ import org.posterita.order.UDIOrderTypes;
import org.posterita.util.PathInfo;
import org.posterita.util.TmkPrinterConstants;
import com.lowagie.text.Chunk;
import com.lowagie.text.Document;
import com.lowagie.text.Element;
import com.lowagie.text.Font;
import com.lowagie.text.Image;
import com.lowagie.text.PageSize;
import com.lowagie.text.Paragraph;
import com.lowagie.text.Phrase;
import com.lowagie.text.pdf.PdfPCell;
import com.lowagie.text.pdf.PdfPTable;
import com.lowagie.text.pdf.PdfWriter;
import com.itextpdf.text.BaseColor;
import com.itextpdf.text.Chunk;
import com.itextpdf.text.Document;
import com.itextpdf.text.Element;
import com.itextpdf.text.Font;
import com.itextpdf.text.Image;
import com.itextpdf.text.PageSize;
import com.itextpdf.text.Paragraph;
import com.itextpdf.text.Phrase;
import com.itextpdf.text.pdf.PdfPCell;
import com.itextpdf.text.pdf.PdfPTable;
import com.itextpdf.text.pdf.PdfWriter;
public class POSReportManager {
@ -1208,12 +1209,12 @@ public class POSReportManager {
// -----------------------------------------------------------------------------------
// setting table footer
t.getDefaultCell().setBackgroundColor(new Color(240, 240, 240));
t.getDefaultCell().setBackgroundColor(BaseColor.LIGHT_GRAY);
PdfPCell c = new PdfPCell(new Paragraph(new Chunk("ORDER TOTAL",
headerFont)));
c.setColspan(2);
c.setBackgroundColor(new Color(240, 240, 240));
c.setBackgroundColor(BaseColor.LIGHT_GRAY);
t.addCell(c);
t.addCell(new Paragraph(new Chunk(totalQty + "", simpleFont)));

View File

@ -25,15 +25,17 @@ import java.awt.Color;
import java.util.Iterator;
import org.posterita.exceptions.OperationException;
import com.lowagie.text.Chunk;
import com.lowagie.text.Document;
import com.lowagie.text.DocumentException;
import com.lowagie.text.Element;
import com.lowagie.text.Image;
import com.lowagie.text.Paragraph;
import com.lowagie.text.Rectangle;
import com.lowagie.text.pdf.PdfPCell;
import com.lowagie.text.pdf.PdfPTable;
import com.itextpdf.text.BaseColor;
import com.itextpdf.text.Chunk;
import com.itextpdf.text.Document;
import com.itextpdf.text.DocumentException;
import com.itextpdf.text.Element;
import com.itextpdf.text.Image;
import com.itextpdf.text.Paragraph;
import com.itextpdf.text.Rectangle;
import com.itextpdf.text.pdf.PdfPCell;
import com.itextpdf.text.pdf.PdfPTable;
public class CrossTabReportGenerator extends PDFReportGenerator
@ -109,7 +111,7 @@ public class CrossTabReportGenerator extends PDFReportGenerator
if(j == noOfRows - 1)
{
cell.setBackgroundColor(new Color(170,170,170));
cell.setBackgroundColor(BaseColor.GRAY);
}
cell.setHorizontalAlignment(Element.ALIGN_LEFT);
@ -127,7 +129,7 @@ public class CrossTabReportGenerator extends PDFReportGenerator
if(k == columnCount-1)
{
PdfPCell cell = new PdfPCell(new Paragraph(txtck));
cell.setBackgroundColor(new Color(170,170,170));
cell.setBackgroundColor(BaseColor.GRAY);
cell.setHorizontalAlignment(Element.ALIGN_CENTER);
cell.setVerticalAlignment(Element.ALIGN_MIDDLE);
cell.setPaddingBottom(5);
@ -145,7 +147,7 @@ public class CrossTabReportGenerator extends PDFReportGenerator
if(j == noOfRows - 1)
{
cell.setBackgroundColor(new Color(170,170,170));
cell.setBackgroundColor(BaseColor.GRAY);
}
table.addCell(cell);

View File

@ -28,18 +28,20 @@ import java.util.Properties;
import org.posterita.exceptions.OperationException;
import org.posterita.lib.PropertiesConstant;
import com.lowagie.text.Chunk;
import com.lowagie.text.Document;
import com.lowagie.text.Element;
import com.lowagie.text.Font;
import com.lowagie.text.FontFactory;
import com.lowagie.text.Image;
import com.lowagie.text.PageSize;
import com.lowagie.text.Paragraph;
import com.lowagie.text.Rectangle;
import com.lowagie.text.pdf.BaseFont;
import com.lowagie.text.pdf.PdfTemplate;
import com.lowagie.text.pdf.PdfWriter;
import com.itextpdf.text.BaseColor;
import com.itextpdf.text.Chunk;
import com.itextpdf.text.Document;
import com.itextpdf.text.Element;
import com.itextpdf.text.Font;
import com.itextpdf.text.FontFactory;
import com.itextpdf.text.Image;
import com.itextpdf.text.PageSize;
import com.itextpdf.text.Paragraph;
import com.itextpdf.text.Rectangle;
import com.itextpdf.text.pdf.BaseFont;
import com.itextpdf.text.pdf.PdfTemplate;
import com.itextpdf.text.pdf.PdfWriter;
public abstract class PDFReportGenerator
{
@ -47,8 +49,8 @@ public abstract class PDFReportGenerator
protected float MARGIN = 30f;
//setting default fonts
protected Font TITLE_FONT = FontFactory.getFont(FontFactory.HELVETICA,18,Font.BOLD,new Color(255,0,0));
protected Font SUBTITLE_FONT = FontFactory.getFont(FontFactory.HELVETICA,15,Font.BOLD,new Color(255,0,0));
protected Font TITLE_FONT = FontFactory.getFont(FontFactory.HELVETICA,18,Font.BOLD,BaseColor.BLUE);
protected Font SUBTITLE_FONT = FontFactory.getFont(FontFactory.HELVETICA,15,Font.BOLD,BaseColor.BLUE);
protected Font HEADER_FONT = FontFactory.getFont(FontFactory.HELVETICA,10,Font.BOLD);
protected Font DATA_FONT = FontFactory.getFont(FontFactory.HELVETICA,10);

View File

@ -24,15 +24,15 @@ package org.posterita.core;
import java.text.SimpleDateFormat;
import java.util.Calendar;
import com.lowagie.text.Document;
import com.lowagie.text.Font;
import com.lowagie.text.FontFactory;
import com.lowagie.text.Rectangle;
import com.lowagie.text.pdf.PdfContentByte;
import com.lowagie.text.pdf.PdfPTable;
import com.lowagie.text.pdf.PdfPageEventHelper;
import com.lowagie.text.pdf.PdfTemplate;
import com.lowagie.text.pdf.PdfWriter;
import com.itextpdf.text.Document;
import com.itextpdf.text.Font;
import com.itextpdf.text.FontFactory;
import com.itextpdf.text.Rectangle;
import com.itextpdf.text.pdf.PdfContentByte;
import com.itextpdf.text.pdf.PdfPTable;
import com.itextpdf.text.pdf.PdfPageEventHelper;
import com.itextpdf.text.pdf.PdfTemplate;
import com.itextpdf.text.pdf.PdfWriter;
/**
* This class extends the page event handler that displays the

View File

@ -24,14 +24,14 @@ package org.posterita.core;
import java.util.Iterator;
import org.posterita.exceptions.OperationException;
import com.lowagie.text.Chunk;
import com.lowagie.text.Document;
import com.lowagie.text.Element;
import com.lowagie.text.PageSize;
import com.lowagie.text.Paragraph;
import com.lowagie.text.Rectangle;
import com.lowagie.text.pdf.PdfPCell;
import com.lowagie.text.pdf.PdfPTable;
import com.itextpdf.text.Chunk;
import com.itextpdf.text.Document;
import com.itextpdf.text.Element;
import com.itextpdf.text.PageSize;
import com.itextpdf.text.Paragraph;
import com.itextpdf.text.Rectangle;
import com.itextpdf.text.pdf.PdfPCell;
import com.itextpdf.text.pdf.PdfPTable;
public class SimpleReportGenerator extends PDFReportGenerator
{

View File

@ -43,17 +43,18 @@ import org.posterita.businesslogic.OrganisationManager;
import org.posterita.businesslogic.performanceanalysis.ReportManager;
import org.posterita.exceptions.OperationException;
import com.lowagie.text.Chunk;
import com.lowagie.text.Document;
import com.lowagie.text.DocumentException;
import com.lowagie.text.Element;
import com.lowagie.text.Font;
import com.lowagie.text.PageSize;
import com.lowagie.text.Paragraph;
import com.lowagie.text.Phrase;
import com.lowagie.text.pdf.PdfPCell;
import com.lowagie.text.pdf.PdfPTable;
import com.lowagie.text.pdf.PdfWriter;
import com.itextpdf.text.BaseColor;
import com.itextpdf.text.Chunk;
import com.itextpdf.text.Document;
import com.itextpdf.text.DocumentException;
import com.itextpdf.text.Element;
import com.itextpdf.text.Font;
import com.itextpdf.text.PageSize;
import com.itextpdf.text.Paragraph;
import com.itextpdf.text.Phrase;
import com.itextpdf.text.pdf.PdfPCell;
import com.itextpdf.text.pdf.PdfPTable;
import com.itextpdf.text.pdf.PdfWriter;
public class TabularReport
{
@ -510,7 +511,7 @@ public class TabularReport
PdfPCell header = new PdfPCell(new Paragraph(getTitle() + "\n" + getSubtitle(), style1));
header.setColspan(7);
header.setHorizontalAlignment(Element.ALIGN_CENTER);
header.setBackgroundColor(new Color(0xC0, 0xC0, 0xC0));
header.setBackgroundColor(BaseColor.BLACK);
mytable.addCell(header);
// Table sub header
@ -617,29 +618,29 @@ public class TabularReport
PdfPCell header = new PdfPCell(new Paragraph(new Chunk(getTitle(), style1) + "\n" + new Chunk(getSubtitle(), style2) + "\n", style1));
header.setColspan(4);
header.setHorizontalAlignment(Element.ALIGN_CENTER);
header.setBackgroundColor(new Color(0xC0, 0xC0, 0xC0));
header.setBackgroundColor(BaseColor.BLACK);
mytable.addCell(header);
//Date Header
PdfPCell dateHeader = new PdfPCell(new Paragraph("From : " + new Chunk(TimestampConvertor.convertTimeStampToFyracleDate(fromDate), style1), style1));
dateHeader.setColspan(1);
dateHeader.setHorizontalAlignment(Element.ALIGN_LEFT);
dateHeader.setBackgroundColor(Color.GRAY);
dateHeader.setBorderColor(Color.WHITE);
dateHeader.setBackgroundColor(BaseColor.GRAY);
dateHeader.setBorderColor(BaseColor.WHITE);
mytable.addCell(dateHeader);
dateHeader = new PdfPCell(new Paragraph("To : " +new Chunk(TimestampConvertor.convertTimeStampToFyracleDate(toDate), style1), style1));
dateHeader.setColspan(3);
dateHeader.setHorizontalAlignment(Element.ALIGN_LEFT);
dateHeader.setBackgroundColor(Color.GRAY);
dateHeader.setBorderColor(Color.WHITE);
dateHeader.setBackgroundColor(BaseColor.GRAY);
dateHeader.setBorderColor(BaseColor.WHITE);
mytable.addCell(dateHeader);
// Info Header
PdfPCell infoHeader = new PdfPCell(new Paragraph("ALL VALUES ARE EXCLUSIVE OF VAT - SALES FIGURES ARE TAKEN AFTER DISCOUNT", style5));
infoHeader.setColspan(4);
infoHeader.setHorizontalAlignment(Element.ALIGN_CENTER);
infoHeader.setBackgroundColor(new Color(0xC0, 0xC0, 0xC0));
infoHeader.setBackgroundColor(BaseColor.BLACK);
mytable.addCell(infoHeader);
// Rows Header
@ -715,29 +716,29 @@ public class TabularReport
PdfPCell header = new PdfPCell(new Paragraph(new Chunk(title, style1) + "\n" + new Chunk(subtitle, style2) + "\n", style1));
header.setColspan(6);
header.setHorizontalAlignment(Element.ALIGN_CENTER);
header.setBackgroundColor(new Color(0xC0, 0xC0, 0xC0));
header.setBackgroundColor(BaseColor.BLACK);
mytable.addCell(header);
//Date Header
PdfPCell dateHeader = new PdfPCell(new Paragraph("From : " + new Chunk(TimestampConvertor.convertTimeStampToFyracleDate(fromDate), style1), style1));
dateHeader.setColspan(2);
dateHeader.setHorizontalAlignment(Element.ALIGN_LEFT);
dateHeader.setBackgroundColor(Color.GRAY);
dateHeader.setBorderColor(Color.WHITE);
dateHeader.setBackgroundColor(BaseColor.GRAY);
dateHeader.setBorderColor(BaseColor.WHITE);
mytable.addCell(dateHeader);
dateHeader = new PdfPCell(new Paragraph("To : " + new Chunk(TimestampConvertor.convertTimeStampToFyracleDate(toDate), style1), style1));
dateHeader.setColspan(4);
dateHeader.setHorizontalAlignment(Element.ALIGN_LEFT);
dateHeader.setBackgroundColor(Color.GRAY);
dateHeader.setBorderColor(Color.WHITE);
dateHeader.setBackgroundColor(BaseColor.GRAY);
dateHeader.setBorderColor(BaseColor.WHITE);
mytable.addCell(dateHeader);
// Info Header
PdfPCell infoHeader = new PdfPCell(new Paragraph("ALL VALUES ARE EXCLUSIVE OF VAT & BASED ON PURCHASE PRICES", style5));
infoHeader.setColspan(6);
infoHeader.setHorizontalAlignment(Element.ALIGN_CENTER);
infoHeader.setBackgroundColor(new Color(0xC0, 0xC0, 0xC0));
infoHeader.setBackgroundColor(BaseColor.BLACK);
mytable.addCell(infoHeader);
// Rows Header
@ -814,7 +815,7 @@ public class TabularReport
PdfPCell header = new PdfPCell(new Paragraph(getTitle() + "\n" + getSubtitle(), style1));
header.setColspan(9);
header.setHorizontalAlignment(Element.ALIGN_CENTER);
header.setBackgroundColor(new Color(0xC0, 0xC0, 0xC0));
header.setBackgroundColor(BaseColor.BLACK);
mytable.addCell(header);
// Table sub header

View File

@ -36,17 +36,17 @@ import org.apache.ecs.xhtml.tr;
import org.posterita.businesslogic.performanceanalysis.ReportManager;
import org.posterita.exceptions.OperationException;
import com.lowagie.text.Chunk;
import com.lowagie.text.Document;
import com.lowagie.text.DocumentException;
import com.lowagie.text.Element;
import com.lowagie.text.Font;
import com.lowagie.text.PageSize;
import com.lowagie.text.Paragraph;
import com.lowagie.text.Phrase;
import com.lowagie.text.pdf.PdfPCell;
import com.lowagie.text.pdf.PdfPTable;
import com.lowagie.text.pdf.PdfWriter;
import com.itextpdf.text.Chunk;
import com.itextpdf.text.Document;
import com.itextpdf.text.DocumentException;
import com.itextpdf.text.Element;
import com.itextpdf.text.Font;
import com.itextpdf.text.PageSize;
import com.itextpdf.text.Paragraph;
import com.itextpdf.text.Phrase;
import com.itextpdf.text.pdf.PdfPCell;
import com.itextpdf.text.pdf.PdfPTable;
import com.itextpdf.text.pdf.PdfWriter;
public class TabularReport2
{

View File

@ -40,17 +40,18 @@ import org.posterita.Constants;
import org.posterita.businesslogic.performanceanalysis.ReportManager;
import org.posterita.exceptions.OperationException;
import com.lowagie.text.Chunk;
import com.lowagie.text.Document;
import com.lowagie.text.DocumentException;
import com.lowagie.text.Element;
import com.lowagie.text.Font;
import com.lowagie.text.PageSize;
import com.lowagie.text.Paragraph;
import com.lowagie.text.Phrase;
import com.lowagie.text.pdf.PdfPCell;
import com.lowagie.text.pdf.PdfPTable;
import com.lowagie.text.pdf.PdfWriter;
import com.itextpdf.text.BaseColor;
import com.itextpdf.text.Chunk;
import com.itextpdf.text.Document;
import com.itextpdf.text.DocumentException;
import com.itextpdf.text.Element;
import com.itextpdf.text.Font;
import com.itextpdf.text.PageSize;
import com.itextpdf.text.Paragraph;
import com.itextpdf.text.Phrase;
import com.itextpdf.text.pdf.PdfPCell;
import com.itextpdf.text.pdf.PdfPTable;
import com.itextpdf.text.pdf.PdfWriter;
public class TabularReportMerge
{
@ -263,7 +264,7 @@ public class TabularReportMerge
PdfPCell header = new PdfPCell(new Paragraph(new Chunk(title, style1) + "\n" + new Chunk(subtitle, style2) + "\n", style1));
header.setColspan(7);
header.setHorizontalAlignment(Element.ALIGN_CENTER);
header.setBackgroundColor(new Color(0xC0, 0xC0, 0xC0));
header.setBackgroundColor(BaseColor.BLACK);
mytable.addCell(header);
// Table sub header
@ -370,29 +371,29 @@ public class TabularReportMerge
PdfPCell header = new PdfPCell(new Paragraph(new Chunk(title, style1) + "\n" + new Chunk(subtitle, style2) + "\n", style1));
header.setColspan(4);
header.setHorizontalAlignment(Element.ALIGN_CENTER);
header.setBackgroundColor(new Color(0xC0, 0xC0, 0xC0));
header.setBackgroundColor(BaseColor.BLACK);
mytable.addCell(header);
//Date Header
PdfPCell dateHeader = new PdfPCell(new Paragraph("From : " + new Chunk(TimestampConvertor.convertTimeStamp(fromDate, TimestampConvertor.DEFAULT_DATE_PATTERN1), style1), style1));
dateHeader.setColspan(1);
dateHeader.setHorizontalAlignment(Element.ALIGN_LEFT);
dateHeader.setBackgroundColor(Color.GRAY);
dateHeader.setBorderColor(Color.WHITE);
dateHeader.setBackgroundColor(BaseColor.GRAY);
dateHeader.setBorderColor(BaseColor.WHITE);
mytable.addCell(dateHeader);
dateHeader = new PdfPCell(new Paragraph("To : " + new Chunk(TimestampConvertor.convertTimeStamp(toDate, TimestampConvertor.DEFAULT_DATE_PATTERN1), style1), style1));
dateHeader.setColspan(3);
dateHeader.setHorizontalAlignment(Element.ALIGN_LEFT);
dateHeader.setBackgroundColor(Color.GRAY);
dateHeader.setBorderColor(Color.WHITE);
dateHeader.setBackgroundColor(BaseColor.GRAY);
dateHeader.setBorderColor(BaseColor.WHITE);
mytable.addCell(dateHeader);
// Info Header
PdfPCell infoHeader = new PdfPCell(new Paragraph("ALL VALUES ARE EXCLUSIVE OF VAT - SALES FIGURES ARE TAKEN AFTER DISCOUNT", style5));
infoHeader.setColspan(4);
infoHeader.setHorizontalAlignment(Element.ALIGN_CENTER);
infoHeader.setBackgroundColor(new Color(0xC0, 0xC0, 0xC0));
infoHeader.setBackgroundColor(BaseColor.BLACK);
mytable.addCell(infoHeader);
// Rows Header
@ -468,29 +469,29 @@ public class TabularReportMerge
PdfPCell header = new PdfPCell(new Paragraph(new Chunk(title, style1) + "\n" + new Chunk(subtitle, style2) + "\n", style1));
header.setColspan(6);
header.setHorizontalAlignment(Element.ALIGN_CENTER);
header.setBackgroundColor(new Color(0xC0, 0xC0, 0xC0));
header.setBackgroundColor(BaseColor.BLACK);
mytable.addCell(header);
//Date Header
PdfPCell dateHeader = new PdfPCell(new Paragraph("From : " + new Chunk(TimestampConvertor.convertTimeStamp(fromDate, TimestampConvertor.DEFAULT_DATE_PATTERN1), style1), style1));
dateHeader.setColspan(2);
dateHeader.setHorizontalAlignment(Element.ALIGN_LEFT);
dateHeader.setBackgroundColor(Color.GRAY);
dateHeader.setBorderColor(Color.WHITE);
dateHeader.setBackgroundColor(BaseColor.GRAY);
dateHeader.setBorderColor(BaseColor.WHITE);
mytable.addCell(dateHeader);
dateHeader = new PdfPCell(new Paragraph("To : " + new Chunk(TimestampConvertor.convertTimeStamp(toDate, TimestampConvertor.DEFAULT_DATE_PATTERN1), style1), style1));
dateHeader.setColspan(4);
dateHeader.setHorizontalAlignment(Element.ALIGN_LEFT);
dateHeader.setBackgroundColor(Color.GRAY);
dateHeader.setBorderColor(Color.WHITE);
dateHeader.setBackgroundColor(BaseColor.GRAY);
dateHeader.setBorderColor(BaseColor.WHITE);
mytable.addCell(dateHeader);
// Info Header
PdfPCell infoHeader = new PdfPCell(new Paragraph("ALL VALUES ARE EXCLUSIVE OF VAT & BASED ON PURCHASE PRICES", style5));
infoHeader.setColspan(6);
infoHeader.setHorizontalAlignment(Element.ALIGN_CENTER);
infoHeader.setBackgroundColor(new Color(0xC0, 0xC0, 0xC0));
infoHeader.setBackgroundColor(BaseColor.BLACK);
mytable.addCell(infoHeader);
// Rows Header

View File

@ -38,7 +38,7 @@ import org.posterita.exceptions.OperationException;
import org.posterita.form.POSHelpForm;
import org.posterita.struts.core.BaseDispatchAction;
import com.lowagie.text.DocumentException;
import com.itextpdf.text.DocumentException;
public class POSHelpAction extends BaseDispatchAction
{

View File

@ -65,7 +65,7 @@ import org.posterita.form.OrderLineForm;
import org.posterita.lib.UdiConstants;
import org.posterita.struts.core.DefaultForm;
import com.lowagie.text.DocumentException;
import com.itextpdf.text.DocumentException;
public class BarcodeAction extends POSDispatchAction
{

View File

@ -59,7 +59,7 @@ import org.posterita.exceptions.OperationException;
import org.posterita.form.InventoryForm;
import org.posterita.struts.core.DefaultForm;
import com.lowagie.text.DocumentException;
import com.itextpdf.text.DocumentException;
public class DocumentAction extends POSDispatchAction
{

View File

@ -73,7 +73,7 @@ import org.posterita.exceptions.UOMValuePrecisionNotValidException;
import org.posterita.form.InventoryLineForm;
import org.posterita.struts.core.DefaultForm;
import com.lowagie.text.DocumentException;
import com.itextpdf.text.DocumentException;
public class InventoryCartAction extends POSDispatchAction
{

View File

@ -52,7 +52,7 @@ import org.posterita.exceptions.ApplicationException;
import org.posterita.exceptions.OperationException;
import org.posterita.struts.core.DefaultForm;
import com.lowagie.text.DocumentException;
import com.itextpdf.text.DocumentException;
public class POSInfoAction extends POSDispatchAction
{

View File

@ -102,7 +102,7 @@ import org.posterita.struts.core.BaseDispatchAction;
import org.posterita.struts.core.DefaultForm;
import org.posterita.util.PathInfo;
import com.lowagie.text.DocumentException;
import com.itextpdf.text.DocumentException;
public class POSReportAction extends BaseDispatchAction

View File

@ -56,12 +56,12 @@ import org.zkoss.zk.ui.Component;
import org.zkoss.zk.ui.Execution;
import org.zkoss.zk.ui.Executions;
import com.lowagie.text.Document;
import com.lowagie.text.DocumentException;
import com.lowagie.text.pdf.PdfContentByte;
import com.lowagie.text.pdf.PdfImportedPage;
import com.lowagie.text.pdf.PdfReader;
import com.lowagie.text.pdf.PdfWriter;
import com.itextpdf.text.Document;
import com.itextpdf.text.DocumentException;
import com.itextpdf.text.pdf.PdfContentByte;
import com.itextpdf.text.pdf.PdfImportedPage;
import com.itextpdf.text.pdf.PdfReader;
import com.itextpdf.text.pdf.PdfWriter;
/**
* ZK Application Environment and utilities

View File

@ -40,11 +40,11 @@ import org.zkoss.zul.Div;
import org.zkoss.zul.Hbox;
import org.zkoss.zul.Html;
import com.lowagie.text.Document;
import com.lowagie.text.pdf.PdfContentByte;
import com.lowagie.text.pdf.PdfImportedPage;
import com.lowagie.text.pdf.PdfReader;
import com.lowagie.text.pdf.PdfWriter;
import com.itextpdf.text.Document;
import com.itextpdf.text.pdf.PdfContentByte;
import com.itextpdf.text.pdf.PdfImportedPage;
import com.itextpdf.text.pdf.PdfReader;
import com.itextpdf.text.pdf.PdfWriter;
/******************************************************************************
* Product: Adempiere ERP & CRM Smart Business Solution *