Fixes https://gitlab.com/kicad/code/kicad/issues/12487
This also allows for easier migration to DRAWSEGMENT::S_RECTs by auto-converting 4 rectilinear lines to a rectangle.