Define shape size

Use the width and height attributes in the <svg> element to specify the size of the shape:

<svg version="1.1" id="MyShapeType" width="100px" height="60px">

Warning

Make sure to use explicit values like 100px. The system relies on these values to calculate the correct size of the shape when it is rendered in the schematic widget. Using relative values like 100% or omitting the units can lead to incorrect rendering.

Example

<svg version="1.1" id="NewShapeType" width="100px" height="60px">
  <rect x="0" y="20" fill="red" width="100" height="20" />
  <rect x="0" y="0" fill="red" width="40" height="60" />
  <rect x="60" y="0" fill="red" width="40" height="60" />
</svg>