Add show_wire_loops option to suppress cable self-loop edges

Cable self-loop edges (W1:e → W1:w) arc over the cable table to show
internal wire routing, but add visual noise on straight-through
harnesses. New Options field defaults to True for backward compat.

Usage:
  options:
    show_wire_loops: false
This commit is contained in:
Ryan Malloy 2026-02-13 16:52:33 -07:00
parent 65af27e0da
commit b44c3e0766
2 changed files with 5 additions and 3 deletions

View File

@ -86,6 +86,7 @@ class Options:
bgcolor_bundle: SingleColor = None
color_output_mode: ColorOutputMode = ColorOutputMode.EN_UPPER
mini_bom_mode: bool = True
show_wire_loops: bool = True
template_separator: str = "."
output_dpi: Optional[float] = 96.0
_pad: int = 0

View File

@ -387,6 +387,7 @@ class Harness:
if not (r1, r2) == (None, None):
dot.edge(r1, r2)
if self.options.show_wire_loops:
for color, we, ww in gv_edge_wire_inside(cable):
if not (we, ww) == (None, None):
dot.edge(we, ww, color=color, straight="straight", href='')