this.dataFieldOriginal = pDataField;
this.dataFieldCloned = pDataField.cloneComponentForRenderer();
ArrayFieldCellHelper.setUpCellRenderer(this.dataFieldOriginal, this.dataFieldCloned); // CraigM: 28/03/2008
// TF:29 Oct 2008:Set this up to handle fixed length documents
if (this.dataFieldOriginal.getDocument() instanceof FixedLengthDocument) {
FixedLengthDocument doc = (FixedLengthDocument)this.dataFieldOriginal.getDocument();
this.dataFieldCloned.setDocument(new FixedLengthDocument(doc.getMaxLength()));
}
else {
this.dataFieldCloned.setDocument(new PlainDocument()); // we can't reuse the document
}
this.dataFieldCloned.setFormatterFactory(new DataFieldFormatterFactory()); // we can't reuse the formatter