How to cancel creating lines and polygons
Use
You can cancel the operation when creating lines or polygons.
Procedure
If you have not finished drawing a line or polygon and would like to cancel the operation, press the Esc key. Existing segments will be deleted.
You can also right-click.
Result
The line or polygon is not created.