While flags are in prefs, actual clearance values are in board setup.
Fixes https://gitlab.com/kicad/code/kicad/issues/10852
This commit is contained in:
parent
fc5772ad92
commit
7ddd3137a3
|
@ -1028,11 +1028,26 @@ void PCB_EDIT_FRAME::ShowBoardSetupDialog( const wxString& aInitialPage )
|
||||||
|
|
||||||
Kiway().CommonSettingsChanged( false, true );
|
Kiway().CommonSettingsChanged( false, true );
|
||||||
|
|
||||||
|
PCBNEW_SETTINGS* settings = GetPcbNewSettings();
|
||||||
|
|
||||||
GetCanvas()->GetView()->UpdateAllItemsConditionally( KIGFX::REPAINT,
|
GetCanvas()->GetView()->UpdateAllItemsConditionally( KIGFX::REPAINT,
|
||||||
[&]( KIGFX::VIEW_ITEM* aItem ) -> bool
|
[&]( KIGFX::VIEW_ITEM* aItem ) -> bool
|
||||||
{
|
{
|
||||||
if( dynamic_cast<EDA_TEXT*>( aItem ) )
|
if( dynamic_cast<PCB_TRACK*>( aItem ) )
|
||||||
|
{
|
||||||
|
if( settings->m_Display.m_PadClearance )
|
||||||
|
return true; // clearance values
|
||||||
|
}
|
||||||
|
else if( dynamic_cast<PAD*>( aItem ) )
|
||||||
|
{
|
||||||
|
if( settings->m_Display.m_TrackClearance == SHOW_WITH_VIA_ALWAYS )
|
||||||
|
return true; // clearance values
|
||||||
|
}
|
||||||
|
else if( dynamic_cast<EDA_TEXT*>( aItem ) )
|
||||||
|
{
|
||||||
|
if( dynamic_cast<EDA_TEXT*>( aItem )->HasTextVars() )
|
||||||
return true; // text variables
|
return true; // text variables
|
||||||
|
}
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
} );
|
} );
|
||||||
|
|
Loading…
Reference in New Issue