Clear[strokeArea];
Clear[strokeArea];
strokeArea[image_] :=
Manipulate[
DynamicModule[{pts = {}},
Column[{
Dynamic@LocatorPane[Dynamic[pts],
Dynamic@
Show[{image,
Graphics[{color, EdgeForm[{color, Thickness[thickness]}],
Opacity[opacity], Polygon[pts]}]
}, ImageSize -> imageSize],
LocatorAutoCreate -> True,
Appearance ->
Graphics[{{color, Thickness[thickness],
Circle[{0, 0}, 0.5]}}, ImageSize -> 10]
],
Button["Pick up the stroked Area",
Clear[graphicsPolygon];
graphicsPolygon =
Graphics[{color, EdgeForm[{color, Thickness[thickness]}],
Opacity[opacity], Thickness[thickness], Polygon[pts]}];
]
}]
], Row[{Control[{{thickness, 0.005}, 0, 0.015}], Spacer[15],
Control[{color, Red}]}], Column[{
Control[{{imageSize, 450}, 300, 600}],
Row[{Spacer[12], Control[{{opacity, 0.5}, 0, 1}]}]
}],
ControlType -> {Slider, ColorSlider, VerticalSlider},
ControlPlacement -> {Top, Left}, SaveDefinitions -> True];
The cursorcursors are visivlevisible as thin circles here, and the blue boundary is given in order to guide the eye, you may remove it and change parameters. Say, after you have successfully finished to built the polygon, change the color and the opacity to that you want the arrow to have.