Eeschema: add missing alternate body style to new schematic file format.

Fixes https://gitlab.com/kicad/code/kicad/issues/4321
This commit is contained in:
Wayne Stambaugh 2020-05-05 09:14:14 -04:00
parent a43e4fa163
commit 0ef97ac486
3 changed files with 13 additions and 3 deletions

View File

@ -2090,6 +2090,11 @@ SCH_COMPONENT* SCH_SEXPR_PARSER::parseSchematicSymbol()
NeedRIGHT(); NeedRIGHT();
break; break;
case T_convert:
symbol->SetConvert( parseInt( "symbol convert" ) );
NeedRIGHT();
break;
case T_uuid: case T_uuid:
NeedSYMBOL(); NeedSYMBOL();
const_cast<KIID&>( symbol->m_Uuid ) = KIID( FromUTF8() ); const_cast<KIID&>( symbol->m_Uuid ) = KIID( FromUTF8() );

View File

@ -416,6 +416,7 @@ void SCH_SEXPR_PLUGIN::init( KIWAY* aKiway, const PROPERTIES* aProperties )
m_kiway = aKiway; m_kiway = aKiway;
m_cache = NULL; m_cache = NULL;
m_out = NULL; m_out = NULL;
m_fieldId = MANDATORY_FIELDS;
} }
@ -869,9 +870,12 @@ void SCH_SEXPR_PLUGIN::saveSymbol( SCH_COMPONENT* aSymbol, int aNestLevel )
} }
if( !( aSymbol->GetInstanceReferences().size() > 1 ) ) if( !( aSymbol->GetInstanceReferences().size() > 1 ) )
m_out->Print( 0, " (unit %d)\n", aSymbol->GetUnit() ); m_out->Print( 0, " (unit %d)", aSymbol->GetUnit() );
else
m_out->Print( 0, "\n" ); if( aSymbol->GetConvert() == LIB_ITEM::LIB_CONVERT::DEMORGAN )
m_out->Print( 0, " (convert %d)", aSymbol->GetConvert() );
m_out->Print( 0, "\n" );
// @todo Convert to full UUID if current UUID is a legacy time stamp. // @todo Convert to full UUID if current UUID is a legacy time stamp.
m_out->Print( aNestLevel + 1, "(uuid %s)\n", m_out->Print( aNestLevel + 1, "(uuid %s)\n",

View File

@ -19,6 +19,7 @@ clock_low
color color
comment comment
company company
convert
dash dash
dash_dot dash_dot
data data