FillImageBlock

Blocks, Interaction

Description

Personalizes an image block by drawing a registered image into its rectangle

Syntax

Delphi

Function FillImageBlock(Page, BlockIndex: Integer; ImageID: Integer;
  Options: Integer): Integer;

ActiveX

Function PDFlib::FillImageBlock(Page As Long, BlockIndex As Long, ImageID As Long, Options As Long) As Long

DLL

int DLFillImageBlock(int InstanceID, int Page, int BlockIndex, int ImageID, int Options);

Parameters

Page, BlockIndexBlock selector
ImageIDImage id returned by an AddImage entry point
OptionsBit 1 deletes the block annotation after a successful fill; bit 2 stretches to the exact rectangle instead of preserving the aspect ratio

Return values

1 when the image was placed, 0 when the block is missing, not an image block, or the image id is invalid

Remarks

The image is centred inside the rectangle and the previous image selection is restored

See also

GetBlockCount, AddBlock, GetBlockType, GetBlockRect