AnnotateImage

Places text onto an image, starting at a specified coordinate.

Syntax

bool AnnotateImage ( string  DisplayText ,  string  xCoordinate ,  string  yCoordinate ,  string  FontName ,  string  FontSize ,  string  Opaque ,  string  WidthAdjustment)

Parameters

DisplayText
The text to place onto the current page image.
xCoordinate
The X coordinate for the starting position of the text on the image.
yCoordinate
The Y coordinate for the starting position of the text on the image.
FontName
Optional. Allows specification of the font for the text. The default value is Times New Roman.
FontSize
Optional. The font name to use for the annotation text. The default value is 12.
Opaque
Optional. 0 = Black text. 1 = White text. The default value is 0.
WidthAdjustment
Optional. Allows adjustment to the width of the text. The default value is 30.

All parameters support smart parameters.

Returns

False if there is an error. Otherwise, True.

Level

Page level.

Details

Imprints the text that you specify onto the current page's image file with a maximum color depth of 24 bits.

By default, this action does not save a backup of the original image. If desired, it is possible to save a copy of the original image. To retain a backup of the original image, on the current page DCO object set the variable KeepOriginalImage to a value of 1. The backup file appends _Annotate to the file name.

Example

AnnotateImage("@BATCHID+ Page:+@ID","5","10", "Arial", "10", "", "100")

This example will place the Batch ID followed by ' Page:' and the calling object ID at the top of the image using the 'Arial' font with a point size of 10 and a width of 100.

See also

This action requires the source image to be 24 bits or less. Refer to the action "SaveImageAs" in the ImageUtilities action library for an example set of actions that will reduce the color depth for 32 bit images

Refer to the top level help of the ApplicationObjects action help for an overview of the DCO.

Refer to the top level help of the RuleRunnerLogic action library for a reference guide for smart parameters.