Return the first interior tap position on wire, or None.
(self, wire, wires, comps)
| 1035 | break # restart after topology change |
| 1036 | |
| 1037 | def _interior_tap(self, wire, wires, comps): |
| 1038 | """Return the first interior tap position on wire, or None.""" |
| 1039 | for other in wires: |
| 1040 | if other is wire: |
| 1041 | continue |
| 1042 | for ep in (other.points[0], other.points[-1]): |
| 1043 | pk = _pt_key(ep) |
| 1044 | if _on_wire_interior(pk, wire): |
| 1045 | return pk |
| 1046 | for comp in comps: |
| 1047 | for pin_pt in comp.pin_scene_pos(): |
| 1048 | pk = _pt_key(pin_pt) |
| 1049 | if _on_wire_interior(pk, wire): |
| 1050 | return pk |
| 1051 | return None |
| 1052 | |
| 1053 | def _split_wire_at(self, wire, pt_key: tuple) -> None: |
| 1054 | """Split wire at an interior position, creating two sub-segments.""" |
no test coverage detected