Check for ".SchDoc" before replacing to ".kicad_sch" for subsheet
This commit is contained in:
parent
f83b9236ac
commit
2c289b3f35
|
@ -1982,9 +1982,16 @@ void SCH_ALTIUM_PLUGIN::ParseFileName( const std::map<wxString, wxString>& aProp
|
|||
SCH_FIELD& filenameField = sheet->second->GetFields()[SHEETFILENAME];
|
||||
|
||||
filenameField.SetPosition( elem.location + m_sheetOffset );
|
||||
elem.text.RemoveLast( 6 );
|
||||
elem.text += "kicad_sch";
|
||||
|
||||
// If last symbols are ".sChDoC", change them to ".kicad_sch"
|
||||
if( ( elem.text.Right( GetFileExtension().length() + 1 ).Lower() ) == ( "." + GetFileExtension().Lower() ))
|
||||
{
|
||||
elem.text.RemoveLast( 6 );
|
||||
elem.text += "kicad_sch";
|
||||
}
|
||||
|
||||
filenameField.SetText( elem.text );
|
||||
|
||||
filenameField.SetVisible( !elem.isHidden );
|
||||
|
||||
filenameField.SetHorizJustify( EDA_TEXT_HJUSTIFY_T::GR_TEXT_HJUSTIFY_LEFT );
|
||||
|
|
Loading…
Reference in New Issue