ImageEn, unit iemio

TImageEnMIO.PrintImagesToFile

TImageEnMIO.PrintImagesToFile


Declaration


procedure PrintImagesToFile(const sFilename: string; iJpegQuality: Integer; iImageWidth, iImageHeight: integer; iColumns: integer; iRows: integer; iHorzSpace: Integer = 6; iVertSpace: Integer = 6; bPrintSelectedOnly: Boolean = False; iHorzMargin: Integer = 12; iVertMargin: Integer = 12; bDrawBox: Boolean = False; bDrawText: Boolean = True; bDrawShadow: Boolean = True; BackgroundColor: TColor = clWhite; BoxColor: TColor = clBlack; const Heading: string = ''; HeadingHeight: Integer = 5; HeadingColor: TColor = clBlack; iPageNo: Integer = -1);


Description


Outputs multiple images (all or just selected) in the attached TImageEnMView or TIEMultiBitmap as rows and columns of thumbnails to a file.

Parameter Description
sFilename The destination filename for these thumbnails. If all pages are being printed (see iPageNo) then this filename will be automatically adjusted in the format image.jpg, image_2.jpg, image_3.jpg, etc.
iJpegQuality If sFilename is a JPEG file then specify the output quality (e.g. 80)
iImageWidth The output width for the image (in pixels)
iImageHeight The output height for the image (in pixels)
iColumns Specifies how many thumbnails span across the page
iRows Specifies how many thumbnails span down the page
iHorzSpace The horizontal space between thumbnails (in pixels)
iVertSpace The vertical space between thumbnails (in pixels)
bPrintSelectedOnly Set to true to print only selected images. False to print all image in the TImageEnMView
iHorzMargin Page margin on left and right of the image (in pixels)
iVertMargin Page margin on top and bottom of the image (in pixels)
bDrawBox Set to true to draw a box around the images (image space). Image is always stretched to maintain aspect ratio.
bDrawText Set to true to draw text associated with every image.
bDrawShadow Set to true to draw a shadow around the image.
BackgroundColor Specifies the fill color of the image.
BoxColor Specifies the color of the box around the image if DrawBox is True.
Heading Specifies the heading to print at the top of the page. If you append ### (e.g. 'Thumbnails###') it will append "Page x" to printed pages after the first one.
HeadingHeight The height of the heading, as a PERCENTAGE of the overall page height, e.g. 5 will make the heading 5% of the page height.
HeadingColor Specifies the color of the heading text.
iPageNo The page of thumbnails to output. If this is -1 (default) then all pages are output and the filename is automatically incremented


Note: Use the OnPrintPage or OnPrintPage event to customize the heading


Example


// Save image of thumbnails
ImageEnMView1.MIO.PrintImagesToFile('C:\SomeImage.jpg', 80, Screen.Width, Screen.Height, 6, 4, ...);


See Also


- PrintImages
- PrintImagesToBitmap
- OnPrintPage
- DoPrintPreviewDialog
- PreviewPrintImages