Images

The Encodian population engine supports image insertion using the following two methods:

Insert an Image via URL

Insert an Image via Base64

Please ensure you have followed the Document Preparation steps, please also review the Image Formatting options.

Slide Preparation

When using the image token you must add the token inside a shape, please follow this instruction:

1.gif

Insert Image - Hyperlink

The URL must be publicly accessible, if the URL requires authentication the image cannot be accessed and therefore would not be inserted.

Example File: Encodian - Template Syntax - Image - Hyperlink.pptx

Example JSON Data:

{
"imageUrl": "https://cdn.apps-encodian.com/logos/enc-small-logo.png"
}

The image token requires a single parameter, the URL value, see below:

<<image [imageUrl]>>

This generates the following output:

Clearly, this doesn't look great! This has happened as by default the image will be constrained to the size of the shape containing the token.

To address this issue either increase the size of the shape or use the 'fitSize' switch to dynamically alter the size of the shape aligned to the size of the image as explained in the Image Formatting section of this article. 

<<image [imageUrl] -fitSize>>

This generates the following output:

Insert Image - Base64

Example File: Encodian - Template Syntax - Image - Base64.pptx

Example JSON Data:

{
"imageBase64": "iVBORw0KGgoAAAANSUhEUgAAAS0AAAEuCAYAAADbd0RAAAAACXBIWXMAAAsSAAALEgHS3X78AAASKUlEQVR4nO3dUWwU953A8Z8xsbJZGwfKsRfHRsE+TNSYrS5GIdh58HE4JyNZlMtDHZKUVNE5EVKRKoeKh1SYSx56NSiST6rCRiddDnDchwiQK6zGqPFDvIQTq6qLkcq63rTYcroRhRrvshKc4R7MEuN4d2Z3Z2fmt/v9PNGwO/MnNd/857//mS17ffDOUyLylACA+/1ppYi8LiKHHB4IAJhxeIXTIwCAbBAtAKoQLQCqEC0AqhAtAKoQLQCqEC0AqhAtAKoQLQCqEC0AqhAtAKoQLQCqEC0AqhAtAKoQLQCqEC0AqhAtAKoQLQCqEC0AqhAtAKoQLQCqEC0AqhAtAKoQLQCqEC0AqhAtAKoQLQCqEC0AqhAtAKoQLQCqEC0AqhAtAKoQLQCqEC0AqhAtAKoQLQCqEC0AqhAtAKqsdHoAbpCcjsrNS19IYiIsyemozCcTTg8JRaDc4xVPbb14N/pl9dZ/loo1PqeHVBRKOlo3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QWbsu5Mj4poWCYxXbABp7aenlkjU+q/c/LKv82x2ZWSzkerZRbdxY2oX7+5eJ/+qiIfHfhl+u/K7JeZMNOBwYHwDV4CCAAVYgWAFWIFgBViBYAVYgWAFWIFgBViBYAVYgWAFWIFgBViBYAVYgWAFWIFgBViBYAVYgWAFWIFgBViBYAVYgWAFWIFgBViBYAVYgWAFWIFgBViBYAVYgWAFWIFgBViBYAVYgWAFWIFgBViBYAVYgWAFWIFgBViBYAVYgWAFWIFgBViBYAVYgWAFWIFgBViBYAVYgWAABAofw/36PYU+6IrrQAAAAASUVORK5CYII="
}

The image token requires a single parameter, the Base64 value, see below:

<<image [imageBase64]>>

This generates the following output:

Clearly, this doesn't look great! This has happened as by default the image will be constrained to the size of the shape containing the token.

To address this issue either increase the size of the shape or use the 'fitSize' switch to dynamically alter the size of the shape aligned to the size of the image as explained in the Image Formatting section of this article. 

<<image [imageUrl] -fitSize>>

This generates the following output:

Image Formatting

The image token requires a single parameter, the URL value, see below:

<<image [imageUrl]>>

Additionally, the following switches can be added to control how the image is formatted once inserted into the text box within the document:

The -keepRatio preserves the size of the textbox and stretches the image within bounds of the shape preserving the ratio of the image.

<<image [imageUrl] -keepRatio>>

The -fitHeight preserves the width of the textbox but changes its height according to the ratio of the image.

<<image [imageUrl] -fitHeight>>

The -fitWidth preserves the height of the textbox but changes its width according to the ratio of the image.

<<image [imageUrl] -fitWidth>>

The -fitSize changes the size of the textbox according to the size of the image.

<<image [imageUrl] -fitSize>>

The -fitSizeLim changes the size of the textbox according to the size of the image without increasing the size of the textbox.

<<image [imageUrl] -fitSizeLim>>
Have more questions? Submit a request

0 Comments

Please sign in to leave a comment.
Powered by Zendesk