Adds ATX-style color coding to the block diagram visualizer for VoltageSink, VoltageSource ports and VoltageLink edges. Supports ~3.3v (orange), ~5v (red), ~12v (yellow), GND (blue). Colors are somewhat muted (67% blend with foreground color). The specifics of the visuals probably need fine-tuning, but that's for another day and another PR.
VoltageSink ports are only colored if the voltage is restricted to the range. Wider tolerances (common on many parts) will not be color-coded.
Wire drawing also changed to a polyline, which should eliminate overlap artifacting for outlines.
Other refactoring:
Architecturally wire colors are implemented as a stroke modifier argument
Graphics2D makeTransformer now returns a new Graphics2D object instead of mutating in-place
Better encapsulation of paintEdge, with outline layering handled with an isOutline arg
Adds ATX-style color coding to the block diagram visualizer for VoltageSink, VoltageSource ports and VoltageLink edges. Supports ~3.3v (orange), ~5v (red), ~12v (yellow), GND (blue). Colors are somewhat muted (67% blend with foreground color). The specifics of the visuals probably need fine-tuning, but that's for another day and another PR.
VoltageSink ports are only colored if the voltage is restricted to the range. Wider tolerances (common on many parts) will not be color-coded.
Wire drawing also changed to a polyline, which should eliminate overlap artifacting for outlines.
Other refactoring: