![]() If i convert the 17cm and 29,70cm to pixels, and set it in the img. img.scaleToFit(2090, 1208) // i tried a lot of modifications, i can set i to 500x500 or something like this in have all showed in the pdf, but how can i calculate marginsÄoc.add(new Paragraph("TEST: text under the b4 image") Image img = Image.getInstance(arraypath) // the array store the path to the image Os = new FileOutputStream(arquivonomecompleto) The international standard for paper sizes is ISO 216 which include series of A papers such as A2, A3, A5 and more You can use this free A paper size converter to convert any A paper size to pixels accurately for free. If i do this: doc = new Document(PageSize.A4, 0, 0, 0, 0) You may usually deal with A4 papers which is the most popular A paper size in the world. but im unable to scale it with margins, and not even without margins, i need to insert the B4 image into the PDF A4 size, using LEFT margin of 2,5cm and the RIGH margin 2cm, but how can i make it fit calculating the sizes, since a paper Ax3508, the B4 image has 2048x2929, if i insert, it cut? the b4 is bigger :| how? considering size of A4, and the b4 should fit perfectly inside the A4 Im creating a PDF as A4 size (2480px x 3508px) using itext. Its scanned have the size in pixels -> 2048 x 2929
0 Comments
Leave a Reply. |