Forum How do I...?

Extend an image into the bleed area

locksley
Hi,

I seem to be unable to extend an image into the bleed area properly. What is the preferred method?

I tried using the following css:

@page {
size: 5.8in 4.11in;
marks: crop;
prince-trim: 0.2in;
prince-bleed: 0.2in;
background-image: url('imagecorrectaspect.jpg');
background-repeat: no-repeat;
background-position: -0.1in -0.1in;
margin: 0in;
}

The image is 5.8 x 4.11 inch
I use the background-position to move the image into the bleed area. You would expect it to be centered. But it's not. What am i doing wrong?

Thanks in advance.
mikeday
Does the image have the correct intrinsic resolution to ensure that it ends up being the right size? You can use the prince-background-image-resolution property to specify a resolution if it doesn't have an intrinsic one.
locksley
Thanks for the reply! I just figured it out 2 seconds ago :-) I thought prince would use the pagebox + bleed area as the size of the image but instead it uses the dpi to calculate dimensions and reflect it into a screen resolution of 96pixels per inch. I assume the default resolution is 300 dpi? Thus changing the dpi using the setting i can reduce or increase the endresult.

Hurray!