/**
* Barcode column
*/
if (column instanceof BarCodeColumn) {
BarCodeColumn barcodeColumn = (BarCodeColumn)column;
JRDesignImage image = new JRDesignImage(new JRDesignStyle().getDefaultStyleProvider());
JRDesignExpression imageExp = new JRDesignExpression();
// imageExp.setText("ar.com.fdvs.dj.core.BarcodeHelper.getBarcodeImage("+barcodeColumn.getBarcodeType() + ", "+ column.getTextForExpression()+ ", "+ barcodeColumn.isShowText() + ", " + barcodeColumn.isCheckSum() + ", " + barcodeColumn.getApplicationIdentifier() + ","+ column.getWidth() +", "+ report.getOptions().getDetailHeight().intValue() + " )" );
//Do not pass column height and width mecause barbecue
//generates the image with wierd dimensions. Pass 0 in both cases
String applicationIdentifier = barcodeColumn.getApplicationIdentifier();
if (applicationIdentifier != null && !"".equals(applicationIdentifier.trim()) ){
applicationIdentifier = "$F{" + applicationIdentifier + "}";
} else {
applicationIdentifier = "\"\"";
}
imageExp.setText("ar.com.fdvs.dj.core.BarcodeHelper.getBarcodeImage("+barcodeColumn.getBarcodeType() + ", "+ column.getTextForExpression()+ ", "+ barcodeColumn.isShowText() + ", " + barcodeColumn.isCheckSum() + ", " + applicationIdentifier + ",0,0 )" );
imageExp.setValueClass(java.awt.Image.class);
image.setExpression(imageExp);
image.setHeight(getReport().getOptions().getDetailHeight().intValue());
image.setWidth(column.getWidth().intValue());
image.setX(column.getPosX().intValue());
image.setScaleImage(barcodeColumn.getScaleMode().getValue());
image.setOnErrorType(JRDesignImage.ON_ERROR_TYPE_ICON); //FIXME should we provide control of this to the user?
if (column.getLink() != null) {
String name = "column_" + getReport().getColumns().indexOf(column);