Open tjunnu opened 3 years ago
@tjunnu
Can you please clarify what do you mean by cell with a particular size? For point # 2, do you mean padding around the barcode? If it is bar size (cell with a particular size) and padding (quite zones) around the barcode then these parameters can be configured as shown below:
BarcodeGenerator generator = new BarcodeGenerator(EncodeTypes.QR); generator.setCodeText("78EED"); generator.getParameters().getBarcode().getCodeTextParameters().setLocation(CodeLocation.NONE); generator.getParameters().getBarcode().getPadding().getLeft().setPixels(10); generator.getParameters().getBarcode().getPadding().getTop().setPixels(10); generator.getParameters().getBarcode().getPadding().getBottom().setPixels(10); generator.getParameters().getBarcode().getPadding().getRight().setPixels(10);
Thanks Muzammil-kahn.
QR code consist black squares arranged in square grid. So I am assuming cell means each black square. Is it correct or not? And If the black square is cell can we configure square size.
Please correct me if anything wrong on my assumptions.
@tjunnu
The height and width of the QR code can be adjusted as follows:
generator.getParameters().setAutoSizeMode(AutoSizeMode.NEAREST); generator.getParameters().getImageWidth().setPixels(500); generator.getParameters().getImageHeight().setPixels(500);
This will create a 500x500 px QR code and Cells (black squares) shall be adjusted accordingly. It is not possible to configure square size for individual squares.
Thanks a lot Muzammil-khan.
Could please confirm to me with below question. Is cell means black square? Still i am in confusion. That's why am asking you.
@tjunnu
The term "cell" usually goes for the tabular representation, whereas the QR code does not generate a table form. QR consists of fixed shape black and white squares arranged in a specific order. I hope I have answered your question.
Thank you Muzammil-khan for clarifying my all doubts.
So we can not customize the black and white square sizes. Right?
Please clarify my doubt.
No, we cannot customize the size of the individual black and white squares at the moment. However, we can adjust the size of the whole QR code image as explained above.
Thanks Muzammil-khan
Hi Farooq,
I have integrated the Aspose library to generate the QR code with Java .But I having below are the doubts. Please clarify can we achieve with Aspose or not.
1.Can we configure the each cell with particular size(ex:- .20mm) .
Please reply to ASAP. It would be helpful to me.