PatternOperationTranslate

Typestatement
DictionaryLCB
LibraryLiveCode Builder
Syntax
translate <mPattern> by <mTranslation>
Associationscom.livecode.canvas
Summary

Apply a translation to a pattern.

Parameters
NameTypeDescription
mPattern

An expression which evaluates to a pattern.

mTranslation

An expression which evaluates to a list of 2 numbers, the x and y offsets of the translation.

Example
// Create a new pattern paint from an image file
variable tPattern
put pattern with image from file "images/pattern.png" into tPattern

// Translate the pattern 20 units to the left.
translate tPattern by [-20,0]
Description

translates the transform of mPattern by mTranslation

Tagscanvas