I am struggling with positioning the image in the attached PDF. Here is the code that I used
PdfReader reader = new PdfReader(getResources().openRawResource(R.raw.template3));
PdfStamper stamper = new PdfStamper(reader, output);
Bitmap bmp = FileUtils.getResizedBitmap(mInvoice.getProfile().getLogoImagePath(), 150, 150);
ByteArrayOutputStream stream = new ByteArrayOutputStream();
bmp.compress(Bitmap.CompressFormat.PNG, 100, stream);
Image image = Image.getInstance(stream.toByteArray());
image.scaleAbsolute(150f, 150f);
image.setAbsolutePosition(385f, 768f);
image.setSpacingBefore(50f);
PdfContentByte overContent = stamper.getOverContent(1);
overContent.addImage(image);
I have tried many variables as far as the inputs for the setAbsolutePath without success. I added spacing before hoping to push the image down without success. I want to push the image down the page a little, It is currently sitting at the top right edge.
Any input is appreciated.