Class ImageBehavior
Inheritance
Namespace: IronPdf.Imaging
Assembly: IronPdf.dll
Syntax
public sealed class ImageBehavior : Enum
The ImageBehavior enumeration in IronPDF declares how a source image is positioned and scaled when it becomes a PDF page.
Part of the IronPdf.Imaging namespace, it includes FitToPage, FitToPageAndMaintainAspectRatio, CenteredOnPage, CropPage, and 4 corner placements (8 total).
Pass a member to ImageToPdfConverter to control layout when converting JPGs, PNGs, or TIFFs. See Image to PDF for the conversion API in C#.
Fields
BottomLeftCornerOfPage
Image should be placed to the left bottom corner of the page
Declaration
public const ImageBehavior BottomLeftCornerOfPage
Field Value
| Type | Description |
|---|---|
| ImageBehavior |
BottomRightCornerOfPage
Image should be placed to the right bottom corner of the page
Declaration
public const ImageBehavior BottomRightCornerOfPage
Field Value
| Type | Description |
|---|---|
| ImageBehavior |
CenteredOnPage
Image should be placed on center of the page
Declaration
public const ImageBehavior CenteredOnPage
Field Value
| Type | Description |
|---|---|
| ImageBehavior |
CropPage
Page should fit to the image
Declaration
public const ImageBehavior CropPage
Field Value
| Type | Description |
|---|---|
| ImageBehavior |
FitToPage
Image should fit to the page
Declaration
public const ImageBehavior FitToPage
Field Value
| Type | Description |
|---|---|
| ImageBehavior |
FitToPageAndMaintainAspectRatio
Image should fit to the page and keep aspect ratio
Declaration
public const ImageBehavior FitToPageAndMaintainAspectRatio
Field Value
| Type | Description |
|---|---|
| ImageBehavior |
TopLeftCornerOfPage
Image should be placed to the left top corner of the page
Declaration
public const ImageBehavior TopLeftCornerOfPage
Field Value
| Type | Description |
|---|---|
| ImageBehavior |
TopRightCornerOfPage
Image should be placed to the right top corner of the page
Declaration
public const ImageBehavior TopRightCornerOfPage
Field Value
| Type | Description |
|---|---|
| ImageBehavior |
value__
Declaration
public int value__
Field Value
| Type | Description |
|---|---|
| System.Int32 |