Javascript: TXTextControl.ImageFormat Enumeration
Description
Specifies the file format of an image.
Members
| Member | Description |
|---|---|
| Bmp | Bitmap image format. |
| Emf | Enhanced metafile image format. |
| Gif | Graphics Interchange Format image format. |
| Jpeg | Joint Photographic Experts Group image format. |
| Png | W3C Portable Network Graphics image format. |
| Tiff | Tagged Image File Format image format. |
| Wmf | Windows metafile image format. |
Examples
The following example uses TXTextControl.ImageFormat.Bmp (bitmap image format.) in a document-editing workflow.
function onTxError(error) {
console.error("TX Text Control error:", error.msg);
error.handled = true;
}
function applyImageFormat(page) {
page.getImage(
TXTextControl.ImageFormat.Bmp,
100,
TXTextControl.PageContent.Background,
function(result) {
console.log("get image result:", result);
},
onTxError
);
}