Polygon and LineStrip now draw by dragging
A curved outline takes a click at each bend, and the shore of a pond has many.
In Labelme v7.10.0, Polygon and LineStrip also draw by dragging. Choose Polygon, press on the outline, and follow it with the button held. Release near the point where you started, and Labelme closes the polygon and asks for the Label. A trace too thin to make a polygon is the exception, covered below.
Which points Labelme keeps
While you drag, Labelme records the path under the cursor. When you release, it simplifies the path with a tolerance of 2 screen pixels, so a straight stretch keeps few points and a bend keeps more (#2757). In the recording, the drag passed through 331 positions and the polygon kept 109.
The tolerance is measured on screen. Zoom in before you drag to keep finer detail.
Clicks still work
A click adds one point, as before. A press becomes a drag once the cursor has moved 4 screen pixels (#2757). Both work in one Shape: click one end of a straight side, then press at its other end and drag on along the curve.
A drag that ends away from the Shape's first point leaves the Shape open. Continue it with clicks or another drag, and press Return (the main Enter key) or Space to finish.
When a trace is too thin
A polygon needs three points in different places, and a LineStrip needs two. A trace thinner than the tolerance, such as a straight line out and back, can keep fewer and does not become a Shape. Zoom in and trace again, pressing Esc first if the trace is still open.
The Shapes are saved as an ordinary polygon or LineStrip, so the Annotation File format is unchanged.
Thanks to im-jaeu, who contributed drag drawing to trace cracks with a pen tablet.