Don't use canonical name for user fields with an id of -1.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16715
This commit is contained in:
parent
8b56b3d999
commit
179ab1011f
|
@ -1033,7 +1033,7 @@ wxString SCH_FIELD::GetCanonicalName() const
|
||||||
{
|
{
|
||||||
if( m_parent && m_parent->Type() == SCH_SYMBOL_T )
|
if( m_parent && m_parent->Type() == SCH_SYMBOL_T )
|
||||||
{
|
{
|
||||||
if( m_id < MANDATORY_FIELDS )
|
if( m_id >= 0 && m_id < MANDATORY_FIELDS )
|
||||||
return GetCanonicalFieldName( m_id );
|
return GetCanonicalFieldName( m_id );
|
||||||
else
|
else
|
||||||
return m_name;
|
return m_name;
|
||||||
|
|
Loading…
Reference in New Issue