Transform

Transform

The <transform> element adjusts a decoration’s size, orientation, and position. Each decoration uses one transform.


XML structure

<transform
      scale="1.0"       // Scale factor: double, min 0.8, max 1.2
      mirror="none"     // Mirror mode: none | horizontal | vertical | both
      rotation="0"      // Rotation angle in degrees (+/-)
      dx="0.0"          // X translation in mm (from location top-left)
      dy="0.0"          // Y translation in mm (from location top-left)
/>


Transform order

Transformations apply in this order:
  1. Scale → around the decoration’s center
  2. Mirror → horizontal/vertical/both, around center
  3. Rotate → around center, clockwise (+) or counterclockwise (–)
  4. Translate (dx/dy) → moves the transformed decoration right and down from the location’s top-left corner.

Attributes

Attribute
Details
scale
Scale factor: 0.8 (80%) to 1.2 (120%). Embroidery scaling is limited to ±20% for quality.
mirror
Flip mode: none (default), horizontal, vertical, or both.
rotation
Degrees of rotation. 0 means no rotation. Positive = clockwise.
dx / dy
X and Y offsets in mm, relative to the location’s top-left corner.

Remarks

  1. The client must ensure that after transformation, the decoration still fits within its placement area.
  2. Invalid scale values (below 0.8 or above 1.2) are rejected.


  1. EWA design recipe
  2. EWA API methods overview
  3. EWA data packages overview