<overlay>
Inside a drawing tool written in HAM, the paths the tool draws over the pad, like a lasso's outline.
<draw-tool name="lasso"
label="Lasso"
icon="gesture"
cursor="crosshair"
@on.touch.start="$tool.points = $event.doc_x + ',' + $event.doc_y"
@on.touch.move="$tool.points = $tool.points + ' ' + $event.doc_x + ',' + $event.doc_y"
@on.touch.end="#pad.select.path:$tool.points; $tool.points = ''">
<state points=""/>
<overlay>
<path in="$pad"
points="$tool.points"
closed="true"
stroke="#FFFFFF"
dash="6 4"/>
</overlay>
</draw-tool>
Any tag also takes gestures: @on.tap, @on.longpress, @on.doubletap and @on.swipeleft (and right, up and down). @click runs on a tap too.