How do I fix the alignment problem for the cells atttached. here is the code that is producing this
Table table = new Table();
table.setColumnWidths(“47 47 96 192 64 64 64”);
Row row = table.getRows().add();
Cell cellNumber = row.getCells().add();
TextFragment fragment = new TextFragment(fieldMaster.getDisplayText(BuyerInvoice_ConfigureMainDocuments_Fields.INVOICE_LINE_NUMBER));
fragment.setHorizontalAlignment(HorizontalAlignment.Center);
cellNumber.setBorder(new BorderInfo(BorderSide.Right|BorderSide.Bottom|BorderSide.Top ));
cellNumber.getParagraphs().add(fragment);
Cell cellType = row.getCells().add();
fragment = new TextFragment(fieldMaster.getDisplayText(BuyerInvoice_ConfigureMainDocuments_Fields.INVOICE_LINE_TYPE));
fragment.getTextState().setFontSize(6);
fragment.setHorizontalAlignment(HorizontalAlignment.Center);
cellType.setBorder(new BorderInfo(BorderSide.Right|BorderSide.Bottom|BorderSide.Top));
cellType.getParagraphs().add(fragment);
for (int x=0;x<5;x++){
Cell cellEmpty = row.getCells().add();
cellEmpty.setBorder(new BorderInfo(BorderSide.Right|BorderSide.Bottom));
}
Hi Mark,
Thanks for contacting support.
We are working on testing the scenario in our environment and will get back to you soon. We are sorry for your inconvenience.
Hi Mark,
Thanks for your patience.
I have tested the scenario and I am able to
notice the same problem. For the sake of correction, I have logged this problem
as PDFNEWJAVA-35385 in our issue tracking system. We will
further look into the details of this problem and will keep you updated on the
status of correction. Please be patient and spare us little time. We are sorry
for this inconvenience.
notice the same problem. For the sake of correction, I have logged this problem
as PDFNEWJAVA-35385 in our issue tracking system. We will
further look into the details of this problem and will keep you updated on the
status of correction. Please be patient and spare us little time. We are sorry
for this inconvenience.
Hi Mark,
Thanks for your patience. In reference to above issue, please use following code snippet, it will resolve the issue.
BorderInfo borders = new BorderInfo(BorderSide.Right | BorderSide.Bottom | BorderSide.Top);<o:p></o:p>
borders.getTop().setColor(Color.getTransparent());
cellEmpty.setBorder(borders);
Instead
cellEmpty.setBorder(new
BorderInfo(BorderSide.Right|BorderSide.Bottom));
Please feel free to contact us for any further assistance.
Best Regards,