Custom barcode font?

Using iReport 2.0.2.

I have a barcode font that I would like to use, but the first problem is that it is not included in iReport. I tried to solve the problem using the barcode font as a regular font, and it works fine, but the problem occurs when I send the PDF to a component (pdfBox) that sends the PDF directly to the printer. The component cannot recognize the font (this is a long story and does not matter), even if it embeds and returns the barcode in Arial.

What I need is to somehow insert my barcode into iReport so that it can be used just like any other existing barcode (and generated as an image)?

0
source share
2 answers

It seems the problem is what exactly is pdfBox.

To get around this (and create a more stable solution), you can compile the report and generate a PDF file using JasperReports (via Java code) and then use the Java printer library to automatically send it to the default printer (or display a printer dialog of choice).

+1
source

Have you tried using isPdfEmbedded?

IsPDFEmbedded tag in Jasper reports

0
source

Source: https://habr.com/ru/post/906204/


All Articles