Three bugs prevented the simplifier from working on ellipse geometry:
1. Sweep angle check blocked initial fit — the 5-degree minimum sweep
was inside TryFit(), killing candidates before the extension loop
could accumulate enough segments. Moved to TryFitArcAt() after
extension.
2. Layer reference equality split runs — entities from separate DXF
ellipses had different Layer object instances for the same layer "0",
splitting them into independent runs. Changed to compare Layer.Name.
3. Symmetrize replaced arcs with mirrored copies whose endpoints didn't
match the target's original geometry, creating ~0.014 gaps. Now only
applies mirrored arcs when endpoints are within tolerance of the
target's boundary points.
Also: default tolerance 0.02 -> 0.004, Export DXF button in
CadConverterForm for debugging simplified geometry.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>