Clear numbers from non-numberable pads and don't run DRC on them.

This was also the last straw on the misnamed PAD::GetName() and
PAD::SetName(), which are now PAD::GetNumber() and PAD::SetNumber().

Fixes https://gitlab.com/kicad/code/kicad/issues/9017
This commit is contained in:
Jeff Young
2021-08-24 01:03:06 +01:00
parent baab2e6119
commit e6ca9837a2
47 changed files with 253 additions and 329 deletions
+3 -3
View File
@@ -106,9 +106,9 @@ void BRDITEMS_PLOTTER::PlotPad( const PAD* aPad, const COLOR4D& aColor, OUTLINE_
const bool useUTF8 = false;
const bool useQuoting = false;
gbr_metadata.SetPadName( aPad->GetName(), useUTF8, useQuoting );
gbr_metadata.SetPadName( aPad->GetNumber(), useUTF8, useQuoting );
if( !aPad->GetName().IsEmpty() )
if( !aPad->GetNumber().IsEmpty() )
gbr_metadata.SetPadPinFunction( aPad->GetPinFunction(), useUTF8, useQuoting );
gbr_metadata.SetNetName( aPad->GetNetname() );
@@ -116,7 +116,7 @@ void BRDITEMS_PLOTTER::PlotPad( const PAD* aPad, const COLOR4D& aColor, OUTLINE_
// Some pads are mechanical pads ( through hole or smd )
// when this is the case, they have no pad name and/or are not plated.
// In this case gerber files have slightly different attributes.
if( aPad->GetAttribute() == PAD_ATTRIB::NPTH || aPad->GetName().IsEmpty() )
if( aPad->GetAttribute() == PAD_ATTRIB::NPTH || aPad->GetNumber().IsEmpty() )
gbr_metadata.m_NetlistMetadata.m_NotInNet = true;
if( !plotOnExternalCopperLayer )