*/
@Override
public void onGenericTag(PdfWriter writer, Document document,
Rectangle rect, String text) {
rect.setBottom(rect.getBottom() - 3);
PdfFormField field = genericChunkFields.get(text);
if (field == null) {
TextField tf = new TextField(writer, new Rectangle(rect.getLeft(padding), rect.getBottom(padding), rect.getRight(padding), rect.getTop(padding)), text);
tf.setFontSize(14);
try {
field = tf.getTextField();
} catch (Exception e) {
throw new ExceptionConverter(e);
}
}
else {
field.put(PdfName.RECT, new PdfRectangle(rect.getLeft(padding), rect.getBottom(padding), rect.getRight(padding), rect.getTop(padding)));
}
if (parent == null)
writer.addAnnotation(field);
else
parent.addKid(field);