OkapiBarcode icon indicating copy to clipboard operation
OkapiBarcode copied to clipboard

QR code: Input too long for selected symbol size

Open mabsofxanadu opened this issue 4 years ago • 1 comments

QrCode qr = new QrCode();
qr.setPreferredEccLevel(QrCode.EccLevel.L);
qr.setPreferredVersion(1);

//pass
qr.setContent("HTTPS://AA.AA/9C5HNT0CJE6");

//failing
qr.setContent("HTTPS://AA.AA/9293750CJE7");

Exception in thread "main" uk.org.okapibarcode.backend.OkapiException: Input too long for selected symbol size
at uk.org.okapibarcode.backend.QrCode.encode(QrCode.java:423)
at uk.org.okapibarcode.backend.Symbol.setContent(Symbol.java:529)

however it works fine on https://qrcode.tec-it.com/en/Raw and with Zint which is supposed to be the base for okapiBarcode

mabsofxanadu avatar May 27 '21 13:05 mabsofxanadu

Thanks for the report. It might take some time for us to look into this -- in the meantime, please feel free to dig in and suggest a fix with a PR.

gredler avatar Jan 20 '22 01:01 gredler