The project rule says all line drawing goes through drawStyledLine in lines_v2.dart. But drawStyledLine is a local closure inside _drawLinesV2 (lib/rendering/components/lines_v2.dart:567), so nothing outside that function can call it.
The result is three inline copies of "resolve arc or biarc, build a Path, stroke with ad-hoc paints" for selection and hover rings: lib/rendering/components/highlights.dart (around lines 22 to 110) and lib/rendering/components/selection_v2.dart (around 455 to 530 and 805 to 880). They ignore corner fillet trimming and always use round caps, so a ring on a flat-capped end will not match the line. Overlay only, never exported.
Related debt in the same file: _drawStyledPath (lines 40 to 162) is a second full copy of the style table, with different caps, and the road and dashed dash loops exist four times.
Doc fix to go with it: CLAUDE.md calls lines.dart "the older pass", but it owns _drawSegmentsForLine, the only geometry pass, which lines_v2.dart calls 12 times. Deleting it as legacy would break all line rendering.
Status: confirmed by reading.
Fix sketch: lift drawStyledLine to an extension method and have the rings go through _drawSegmentsForLine(customPath:).
From the engineering review on 2026-10-13.
The project rule says all line drawing goes through `drawStyledLine` in `lines_v2.dart`. But `drawStyledLine` is a local closure inside `_drawLinesV2` (`lib/rendering/components/lines_v2.dart:567`), so nothing outside that function can call it.
The result is three inline copies of "resolve arc or biarc, build a `Path`, stroke with ad-hoc paints" for selection and hover rings: `lib/rendering/components/highlights.dart` (around lines 22 to 110) and `lib/rendering/components/selection_v2.dart` (around 455 to 530 and 805 to 880). They ignore corner fillet trimming and always use round caps, so a ring on a flat-capped end will not match the line. Overlay only, never exported.
Related debt in the same file: `_drawStyledPath` (lines 40 to 162) is a second full copy of the style table, with different caps, and the road and dashed dash loops exist four times.
Doc fix to go with it: `CLAUDE.md` calls `lines.dart` "the older pass", but it owns `_drawSegmentsForLine`, the only geometry pass, which `lines_v2.dart` calls 12 times. Deleting it as legacy would break all line rendering.
**Status:** confirmed by reading.
**Fix sketch:** lift `drawStyledLine` to an extension method and have the rings go through `_drawSegmentsForLine(customPath:)`.
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
From the engineering review on 2026-10-13.
The project rule says all line drawing goes through
drawStyledLineinlines_v2.dart. ButdrawStyledLineis a local closure inside_drawLinesV2(lib/rendering/components/lines_v2.dart:567), so nothing outside that function can call it.The result is three inline copies of "resolve arc or biarc, build a
Path, stroke with ad-hoc paints" for selection and hover rings:lib/rendering/components/highlights.dart(around lines 22 to 110) andlib/rendering/components/selection_v2.dart(around 455 to 530 and 805 to 880). They ignore corner fillet trimming and always use round caps, so a ring on a flat-capped end will not match the line. Overlay only, never exported.Related debt in the same file:
_drawStyledPath(lines 40 to 162) is a second full copy of the style table, with different caps, and the road and dashed dash loops exist four times.Doc fix to go with it:
CLAUDE.mdcallslines.dart"the older pass", but it owns_drawSegmentsForLine, the only geometry pass, whichlines_v2.dartcalls 12 times. Deleting it as legacy would break all line rendering.Status: confirmed by reading.
Fix sketch: lift
drawStyledLineto an extension method and have the rings go through_drawSegmentsForLine(customPath:).