use of com.itextpdf.kernel.font.PdfFont in project ComponentManagement by Bac3Phi.
the class InventoriesReportController method addDate.
private void addDate(Document document) throws IOException {
Paragraph date;
date = new Paragraph("Tháng: " + cbbMonth.getSelectionModel().getSelectedItem() + "/2018");
// Setting font of the text
PdfFont font = PdfFontFactory.createFont(FontConstants.TIMES_ROMAN);
date.setFont(font);
date.setFontSize(12);
date.setTextAlignment(TextAlignment.CENTER);
document.add(date);
}
Aggregations