Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Barcode isn't well displayed in PDF documents #1

Open
alexisgstalter opened this issue Oct 25, 2017 · 7 comments
Open

Barcode isn't well displayed in PDF documents #1

alexisgstalter opened this issue Oct 25, 2017 · 7 comments

Comments

@alexisgstalter
Copy link

Good morning,

I'm trying to generate a PDF document with a barcode generated with your font. The problem is that the barcode is totally smashed inside : http://prntscr.com/h1ql8p

but is rendering correctly in the webpage : http://prntscr.com/h1qliy

I used Code128 fonts to do similar things, and it worked, my PDF library use the CSS inline and external that is mentionned in the HTML code... but it doesn't work with your font.

@Holger-Will
Copy link
Owner

that looks like there are only the stop codes. Do you encode the text properly? can you post an encoded string please.

@alexisgstalter
Copy link
Author

alexisgstalter commented Oct 25, 2017

yeah sure, the encoded string is : _3L4L6G6G6G7L3**R4R7R3R6R2R1

(the ***** caract are also between _3 and L4, and at the end of the string, but it's corrected)

@Holger-Will
Copy link
Owner

how do you generate the PDF? One explanaion is that the software you use to render the PDF does not support ligatures... i have used LaTeX und postscript to generate PDF so far. both worked well...

@alexisgstalter
Copy link
Author

I use IronPDF, I can write Code128 barcodes on it (with libre code 128 font for example)

@Holger-Will
Copy link
Owner

Holger-Will commented Oct 25, 2017

i can not test ironPDF (no Windows machine available) and the PDF's i created so far do work... It might be a font loading issue, but on the other hand the font does get loaded... my guess is still missing ligature support. Does the libre code 128 font use ligatures? My code 128 font does not...

@alexisgstalter
Copy link
Author

It seems like it could be the problem, I don't know if libre font 128 (it's a google font) use ligatures, but I will assume that it doesn't. I tried with SelecPDF library as well, it doesn't work, I believe that it's a CSS problem (I use Bootstrap).

@Holger-Will
Copy link
Owner

I just realised that the web example (and the ean13_all.css just references the woff font without fallback. What you could try to do is install the ttf font and then use the installed font. try it with different tools. the installed font should work everywhere on windows (word, editor, paint...).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants