From 7ed755ac613696403da017a22f4f7ad9b30defea Mon Sep 17 00:00:00 2001 From: Stefan <2252537-stefan_test@users.noreply.gitlab.com> Date: Tue, 30 Apr 2024 03:07:14 +0000 Subject: [PATCH] Handle piechart case for Altium lib import This doesn't parse the data but it will let the user know what wasn't properly parsed. --- eeschema/sch_io/altium/sch_io_altium.cpp | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/eeschema/sch_io/altium/sch_io_altium.cpp b/eeschema/sch_io/altium/sch_io_altium.cpp index 16c7f1464e..04172b6bab 100644 --- a/eeschema/sch_io/altium/sch_io_altium.cpp +++ b/eeschema/sch_io/altium/sch_io_altium.cpp @@ -889,9 +889,9 @@ void SCH_IO_ALTIUM::ParseRecord( int index, std::map& proper ParseEllipse( properties ); break; - case ALTIUM_SCH_RECORD::PIECHART: - m_reporter->Report( _( "Record 'PIECHART' not handled." ), RPT_SEVERITY_INFO ); - break; + case ALTIUM_SCH_RECORD::PIECHART: + m_reporter->Report( _( "Record 'PIECHART' not handled." ), RPT_SEVERITY_INFO ); + break; case ALTIUM_SCH_RECORD::ROUND_RECTANGLE: ParseRoundRectangle( properties ); @@ -4212,6 +4212,13 @@ std::map SCH_IO_ALTIUM::ParseLibFile( const ALTIUM_COMPOUN case ALTIUM_SCH_RECORD::ELLIPSE: ParseEllipse( properties, symbols ); break; + case ALTIUM_SCH_RECORD::PIECHART: + m_reporter->Report( wxString::Format( _( "Record 'PIECHART' not handled, found " + "in %s." ), + symbols[0]->GetName() ), + RPT_SEVERITY_ERROR ); + break; + case ALTIUM_SCH_RECORD::ROUND_RECTANGLE: ParseRoundRectangle( properties, symbols ); break; case ALTIUM_SCH_RECORD::ELLIPTICAL_ARC: ParseEllipticalArc( properties, symbols ); break;