mirror of
https://gitlab.com/kicad/code/kicad.git
synced 2025-04-20 08:31:40 +00:00
Honour sheet-level DNP & Exclude from BOM in symbol fields table.
(And also in netlist exporter.) Fixes https://gitlab.com/kicad/code/kicad/-/issues/18717
This commit is contained in:
parent
7da8b42206
commit
e04f873765
eeschema
@ -555,11 +555,17 @@ void FIELDS_EDITOR_GRID_DATA_MODEL::RebuildRows()
|
||||
if( !m_filter.IsEmpty() && !WildCompareString( m_filter, ref.GetFullRef(), false ) )
|
||||
continue;
|
||||
|
||||
if( m_excludeDNP && ref.GetSymbol()->GetDNP() )
|
||||
if( m_excludeDNP && ( ref.GetSymbol()->GetDNP()
|
||||
|| ref.GetSheetPath().GetDNP() ) )
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
if( !m_includeExcluded && ref.GetSymbol()->GetExcludedFromBOM() )
|
||||
if( !m_includeExcluded && ( ref.GetSymbol()->GetExcludedFromBOM()
|
||||
|| ref.GetSheetPath().GetExcludedFromBOM() ) )
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
// Check if the symbol if on the current sheet or, in the sheet path somewhere
|
||||
// depending on scope
|
||||
|
@ -368,19 +368,19 @@ XNODE* NETLIST_EXPORTER_XML::makeSymbols( unsigned aCtl )
|
||||
xproperty->AddAttribute( wxT( "value" ), sheetField.GetText() );
|
||||
}
|
||||
|
||||
if( symbol->GetExcludedFromBOM() )
|
||||
if( symbol->GetExcludedFromBOM() || sheet.GetExcludedFromBOM() )
|
||||
{
|
||||
xcomp->AddChild( xproperty = node( wxT( "property" ) ) );
|
||||
xproperty->AddAttribute( wxT( "name" ), wxT( "exclude_from_bom" ) );
|
||||
}
|
||||
|
||||
if( symbol->GetExcludedFromBoard() )
|
||||
if( symbol->GetExcludedFromBoard() || sheet.GetExcludedFromBoard() )
|
||||
{
|
||||
xcomp->AddChild( xproperty = node( wxT( "property" ) ) );
|
||||
xproperty->AddAttribute( wxT( "name" ), wxT( "exclude_from_board" ) );
|
||||
}
|
||||
|
||||
if( symbol->GetDNP() )
|
||||
if( symbol->GetDNP() || sheet.GetDNP() )
|
||||
{
|
||||
xcomp->AddChild( xproperty = node( wxT( "property" ) ) );
|
||||
xproperty->AddAttribute( wxT( "name" ), wxT( "dnp" ) );
|
||||
|
Loading…
Reference in New Issue
Block a user