Eeschema, PlotInteractiveLayer(): do not print useless info in a PDF plot.
It makes this info more easily readable. - Remove duplicate properties/fields - Do not plot empty properties/fields
This commit is contained in:
parent
a80ac8286d
commit
bc8cc826cc
|
@ -2266,18 +2266,21 @@ void SCH_SYMBOL::Plot( PLOTTER* aPlotter, bool aBackground ) const
|
||||||
|
|
||||||
for( const SCH_FIELD& field : GetFields() )
|
for( const SCH_FIELD& field : GetFields() )
|
||||||
{
|
{
|
||||||
|
wxString text_field = field.GetShownText( sheet, false);
|
||||||
|
|
||||||
|
if( text_field.IsEmpty() )
|
||||||
|
continue;
|
||||||
|
|
||||||
properties.emplace_back( wxString::Format( wxT( "!%s = %s" ),
|
properties.emplace_back( wxString::Format( wxT( "!%s = %s" ),
|
||||||
field.GetName(),
|
field.GetName(), text_field ) );
|
||||||
field.GetShownText( sheet, false) ) );
|
|
||||||
}
|
}
|
||||||
|
|
||||||
properties.emplace_back( wxString::Format( wxT( "!%s = %s" ),
|
if( !m_part->GetKeyWords().IsEmpty() )
|
||||||
_( "Description" ),
|
{
|
||||||
m_part->GetDescription() ) );
|
|
||||||
|
|
||||||
properties.emplace_back( wxString::Format( wxT( "!%s = %s" ),
|
properties.emplace_back( wxString::Format( wxT( "!%s = %s" ),
|
||||||
_( "Keywords" ),
|
_( "Keywords" ),
|
||||||
m_part->GetKeyWords() ) );
|
m_part->GetKeyWords() ) );
|
||||||
|
}
|
||||||
|
|
||||||
aPlotter->HyperlinkMenu( GetBoundingBox(), properties );
|
aPlotter->HyperlinkMenu( GetBoundingBox(), properties );
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue