public class Auto extends ImageMapping
Images with a meaningful resolution, e.g. scans or graphics,
are converted to PDF pages fitting the image. The
image size is preserved if it is smaller than getMaxPageSize()
.
Otherwise, it is scaled down.
For all images except scans, a margin getDefaultPageMargin()
is used.
Images with no meaningful resolution, e.g. photos are scaled, to fit onto
getMaxPageSize()
.
Constructor | Description |
---|---|
Auto() |
Modifier and Type | Method | Description |
---|---|---|
Margin |
getDefaultPageMargin() |
The default page margin (Getter)
|
Size |
getMaxPageSize() |
The maximum page size (Getter)
|
void |
setDefaultPageMargin(Margin value) |
The default page margin (Setter)
|
void |
setMaxPageSize(Size value) |
The maximum page size (Setter)
|
equals, hashCode
public Size getMaxPageSize()
Each image is scaled individually such that neither the width nor the height exceeds the maximum page size. For landscape images the maximum page size is assumed to be landscape, and equivalently for portrait images.
Default value: "A4" (210mm 297mm)
public void setMaxPageSize(Size value)
Each image is scaled individually such that neither the width nor the height exceeds the maximum page size. For landscape images the maximum page size is assumed to be landscape, and equivalently for portrait images.
Default value: "A4" (210mm 297mm)
java.lang.IllegalArgumentException
- The argument is smaller than "3pt 3pt" or larger than "14400pt 14400pt".java.lang.IllegalArgumentException
- if value
is null
public Margin getDefaultPageMargin()
public void setDefaultPageMargin(Margin value)
java.lang.IllegalArgumentException
- The argument has negative margin values.java.lang.IllegalArgumentException
- if value
is null