Pcbnew, show solder mask on VIAS: refinement: take in account the mask expansion.
This commit is contained in:
parent
ef1a2ff050
commit
ab4535f01b
|
@ -994,6 +994,17 @@ void PCB_PAINTER::draw( const PCB_VIA* aVia, int aLayer )
|
|||
m_gal->SetIsFill( true );
|
||||
m_gal->DrawCircle( center, getViaDrillSize( aVia ) / 2.0 );
|
||||
}
|
||||
else if( ( aLayer == F_Mask && aVia->IsOnLayer( F_Mask ) )
|
||||
|| ( aLayer == B_Mask && aVia->IsOnLayer( B_Mask ) ) )
|
||||
{
|
||||
int margin = board->GetDesignSettings().m_SolderMaskExpansion;
|
||||
|
||||
m_gal->SetIsFill( true );
|
||||
m_gal->SetIsStroke( false );
|
||||
|
||||
m_gal->SetLineWidth( margin );
|
||||
m_gal->DrawCircle( center, ( aVia->GetWidth() + margin ) / 2.0 );
|
||||
}
|
||||
else if( aLayer == LAYER_VIA_THROUGH || m_pcbSettings.IsPrinting() )
|
||||
{
|
||||
int annular_width = ( aVia->GetWidth() - getViaDrillSize( aVia ) ) / 2.0;
|
||||
|
|
|
@ -761,6 +761,14 @@ void PCB_VIA::ViewGetLayers( int aLayers[], int& aCount ) const
|
|||
|
||||
if( IsLocked() )
|
||||
aLayers[ aCount++ ] = LAYER_LOCKED_ITEM_SHADOW;
|
||||
|
||||
// Vias can also be on a solder mask layer. They are on these layers or not,
|
||||
// depending on the plot and solder mask options
|
||||
if( IsOnLayer( F_Mask ) )
|
||||
aLayers[ aCount++ ] = F_Mask;
|
||||
|
||||
if( IsOnLayer( B_Mask ) )
|
||||
aLayers[ aCount++ ] = B_Mask;
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue