From 04aff932481f95b0b922e1073df2279d65dd575b Mon Sep 17 00:00:00 2001 From: Jeff Young Date: Mon, 20 Sep 2021 21:18:06 +0100 Subject: [PATCH] Eagle doesn't use netclass clearance so make them the board clearance. Fixes https://gitlab.com/kicad/code/kicad/issues/2442 --- pcbnew/plugins/eagle/eagle_plugin.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pcbnew/plugins/eagle/eagle_plugin.cpp b/pcbnew/plugins/eagle/eagle_plugin.cpp index b14f532a93..c5960e50d0 100644 --- a/pcbnew/plugins/eagle/eagle_plugin.cpp +++ b/pcbnew/plugins/eagle/eagle_plugin.cpp @@ -409,6 +409,10 @@ BOARD* EAGLE_PLUGIN::Load( const wxString& aFileName, BOARD* aAppendToMe, auto finishNetclass = [&]( NETCLASSPTR netclass ) { + // If Eagle has a clearance matrix then we'll build custom rules from that. + // Netclasses should just be the board minimum clearance. + netclass->SetClearance( KiROUND( designSettings.m_MinClearance ) ); + if( netclass->GetTrackWidth() == INT_MAX ) netclass->SetTrackWidth( defaults.GetTrackWidth() );