KiCad PCB EDA Suite
SCH_SHEET_LIST Class Reference

A container for handling SCH_SHEET_PATH objects in a flattened hierarchy. More...

#include <sch_sheet_path.h>

Inheritance diagram for SCH_SHEET_LIST:

Public Member Functions

 SCH_SHEET_LIST (SCH_SHEET *aSheet=nullptr, bool aCheckIntegrity=false)
 Construct a flattened list of SCH_SHEET_PATH objects from aSheet. More...
 
 ~SCH_SHEET_LIST ()
 
bool IsModified () const
 Check the entire hierarchy for any modifications. More...
 
void ClearModifyStatus ()
 
SCH_ITEMGetItem (const KIID &aID, SCH_SHEET_PATH *aPathOut=nullptr) const
 Fetch a SCH_ITEM by ID. More...
 
void FillItemMap (std::map< KIID, EDA_ITEM * > &aMap)
 Fill an item cache for temporary use when many items need to be fetched. More...
 
void AnnotatePowerSymbols ()
 Silently annotate the not yet annotated power symbols of the entire hierarchy of the sheet path list. More...
 
void GetSymbols (SCH_REFERENCE_LIST &aReferences, bool aIncludePowerSymbols=true, bool aForceIncludeOrphanSymbols=false) const
 Add a SCH_REFERENCE object to aReferences for each symbol in the list of sheets. More...
 
void GetSymbolsWithinPath (SCH_REFERENCE_LIST &aReferences, const SCH_SHEET_PATH &aSheetPath, bool aIncludePowerSymbols=true, bool aForceIncludeOrphanSymbols=false) const
 Add a SCH_REFERENCE object to aReferences for each symbol in the list of sheets that are contained within aSheetPath as well as recursively downwards inside aSheetPath. More...
 
void GetSheetsWithinPath (SCH_SHEET_PATHS &aSheets, const SCH_SHEET_PATH &aSheetPath) const
 Add a SCH_SHEET_PATH object to aSheets for each sheet in the list that are contained within aSheetPath as well as recursively downwards inside aSheetPath. More...
 
std::optional< SCH_SHEET_PATHGetSheetPathByKIIDPath (const KIID_PATH &aPath, bool aIncludeLastSheet=true) const
 Finds a SCH_SHEET_PATH that matches the provided KIID_PATH. More...
 
void GetMultiUnitSymbols (SCH_MULTI_UNIT_REFERENCE_MAP &aRefList, bool aIncludePowerSymbols=true) const
 Add a SCH_REFERENCE_LIST object to aRefList for each same-reference set of multi-unit parts in the list of sheets. More...
 
bool TestForRecursion (const SCH_SHEET_LIST &aSrcSheetHierarchy, const wxString &aDestFileName)
 Test every SCH_SHEET_PATH in this SCH_SHEET_LIST to verify if adding the sheets stored in aSrcSheetHierarchy to the sheet stored in aDestFileName will cause recursion. More...
 
SCH_SHEET_PATHFindSheetForPath (const SCH_SHEET_PATH *aPath)
 Return a pointer to the first SCH_SHEET_PATH object (not necessarily the only one) matching the provided path. More...
 
SCH_SHEET_PATHFindSheetForScreen (const SCH_SCREEN *aScreen)
 Return a pointer to the first SCH_SHEET_PATH object (not necessarily the only one) using a particular screen. More...
 
SCH_SHEET_LIST FindAllSheetsForScreen (const SCH_SCREEN *aScreen) const
 Return a SCH_SHEET_LIST with a copy of all the SCH_SHEET_PATH using a particular screen. More...
 
void BuildSheetList (SCH_SHEET *aSheet, bool aCheckIntegrity)
 Build the list of sheets and their sheet path from aSheet. More...
 
void SortByPageNumbers (bool aUpdateVirtualPageNums=true)
 Sort the list of sheets by page number. More...
 
bool NameExists (const wxString &aSheetName) const
 
bool PageNumberExists (const wxString &aPageNumber) const
 
void UpdateSymbolInstanceData (const std::vector< SCH_SYMBOL_INSTANCE > &aSymbolInstances)
 Update all of the symbol instance information using aSymbolInstances. More...
 
void UpdateSheetInstanceData (const std::vector< SCH_SHEET_INSTANCE > &aSheetInstances)
 Update all of the sheet instance information using aSheetInstances. More...
 
std::vector< KIID_PATHGetPaths () const
 
std::vector< SCH_SHEET_INSTANCEGetSheetInstances () const
 Fetch the instance information for all of the sheets in the hiearchy. More...
 
bool AllSheetPageNumbersEmpty () const
 Check all of the sheet instance for empty page numbers. More...
 
void SetInitialPageNumbers ()
 Set initial sheet page numbers. More...
 
void AddNewSymbolInstances (const SCH_SHEET_PATH &aPrefixSheetPath)
 Attempt to add new symbol instances for all symbols in this list of sheet paths prefixed with aPrefixSheetPath. More...
 
void AddNewSheetInstances (const SCH_SHEET_PATH &aPrefixSheetPath, int aLastVirtualPageNumber)
 
int GetLastVirtualPageNumber () const
 
void RemoveSymbolInstances (const SCH_SHEET_PATH &aPrefixSheetPath)
 

Private Attributes

SCH_SHEET_PATH m_currentSheetPath
 

Detailed Description

A container for handling SCH_SHEET_PATH objects in a flattened hierarchy.

SCH_SHEET objects are not unique, there can be many sheets with the same filename and that share the same SCH_SCREEN reference. Each The schematic file (SCH_SCREEN) may be shared between these sheets and symbol references are specific to a sheet path. When a sheet is entered, symbol references and sheet page number are updated.

Definition at line 460 of file sch_sheet_path.h.

Constructor & Destructor Documentation

◆ SCH_SHEET_LIST()

SCH_SHEET_LIST::SCH_SHEET_LIST ( SCH_SHEET aSheet = nullptr,
bool  aCheckIntegrity = false 
)

Construct a flattened list of SCH_SHEET_PATH objects from aSheet.

If aSheet == NULL, then this is an empty hierarchy which the user can populate.

Definition at line 660 of file sch_sheet_path.cpp.

661{
662 if( aSheet != nullptr )
663 {
664 BuildSheetList( aSheet, aCheckIntegrity );
665
666 if( aSheet->IsRootSheet() )
668 }
669}
void SortByPageNumbers(bool aUpdateVirtualPageNums=true)
Sort the list of sheets by page number.
void BuildSheetList(SCH_SHEET *aSheet, bool aCheckIntegrity)
Build the list of sheets and their sheet path from aSheet.
bool IsRootSheet() const
Definition: sch_sheet.cpp:194

References BuildSheetList(), SCH_SHEET::IsRootSheet(), and SortByPageNumbers().

◆ ~SCH_SHEET_LIST()

SCH_SHEET_LIST::~SCH_SHEET_LIST ( )
inline

Definition at line 470 of file sch_sheet_path.h.

470{}

Member Function Documentation

◆ AddNewSheetInstances()

void SCH_SHEET_LIST::AddNewSheetInstances ( const SCH_SHEET_PATH aPrefixSheetPath,
int  aLastVirtualPageNumber 
)

Definition at line 1226 of file sch_sheet_path.cpp.

1228{
1229 wxString pageNumber;
1230 int lastUsedPageNumber = 1;
1231 int nextVirtualPageNumber = aLastVirtualPageNumber;
1232
1233 // Fetch the list of page numbers already in use.
1234 std::vector< wxString > usedPageNumbers;
1235
1236 if( aPrefixSheetPath.size() )
1237 {
1238 SCH_SHEET_LIST prefixHierarchy( aPrefixSheetPath.at( 0 ) );
1239
1240 for( const SCH_SHEET_PATH& path : prefixHierarchy )
1241 {
1242 pageNumber = path.GetPageNumber();
1243
1244 if( !pageNumber.IsEmpty() )
1245 usedPageNumbers.emplace_back( pageNumber );
1246 }
1247 }
1248
1249 for( SCH_SHEET_PATH& sheetPath : *this )
1250 {
1251 SCH_SHEET_PATH tmp( sheetPath );
1252 SCH_SHEET_PATH newSheetPath( aPrefixSheetPath );
1253
1254 // Prefix the new hierarchical path.
1255 newSheetPath = newSheetPath + sheetPath;
1256
1257 // Sheets cannot have themselves in the path.
1258 tmp.pop_back();
1259
1260 SCH_SHEET* sheet = sheetPath.Last();
1261
1262 wxCHECK2( sheet, continue );
1263
1264 nextVirtualPageNumber += 1;
1265
1266 SCH_SHEET_INSTANCE instance;
1267
1268 if( sheet->getInstance( instance, tmp.Path(), true )
1269 && !instance.m_PageNumber.IsEmpty() )
1270 {
1271 newSheetPath.SetPageNumber( instance.m_PageNumber );
1272 usedPageNumbers.push_back( instance.m_PageNumber );
1273 }
1274 else
1275 {
1276 // Generate the next available page number.
1277 do
1278 {
1279 pageNumber.Printf( wxT( "%d" ), lastUsedPageNumber );
1280 lastUsedPageNumber += 1;
1281 } while( std::find( usedPageNumbers.begin(), usedPageNumbers.end(), pageNumber ) !=
1282 usedPageNumbers.end() );
1283
1284 newSheetPath.SetVirtualPageNumber( nextVirtualPageNumber );
1285 newSheetPath.SetPageNumber( pageNumber );
1286 usedPageNumbers.push_back( pageNumber );
1287 }
1288 }
1289}
A container for handling SCH_SHEET_PATH objects in a flattened hierarchy.
Handle access to a stack of flattened SCH_SHEET objects by way of a path for creating a flattened sch...
SCH_SHEET * at(size_t aIndex) const
Forwarded method from std::vector.
size_t size() const
Forwarded method from std::vector.
void pop_back()
Forwarded method from std::vector.
Sheet symbol placed in a schematic, and is the entry point for a sub schematic.
Definition: sch_sheet.h:57
bool getInstance(SCH_SHEET_INSTANCE &aInstance, const KIID_PATH &aSheetPath, bool aTestFromEnd=false) const
Definition: sch_sheet.cpp:1247
A simple container for sheet instance information.

References SCH_SHEET_PATH::at(), SCH_SHEET::getInstance(), SCH_SHEET_INSTANCE::m_PageNumber, SCH_SHEET_PATH::Path(), path, SCH_SHEET_PATH::pop_back(), SCH_SHEET_PATH::SetPageNumber(), SCH_SHEET_PATH::SetVirtualPageNumber(), and SCH_SHEET_PATH::size().

Referenced by SCH_EDIT_FRAME::LoadSheetFromFile().

◆ AddNewSymbolInstances()

void SCH_SHEET_LIST::AddNewSymbolInstances ( const SCH_SHEET_PATH aPrefixSheetPath)

Attempt to add new symbol instances for all symbols in this list of sheet paths prefixed with aPrefixSheetPath.

Parameters
aPrefixSheetPathis the sheet path to append the new symbol instances to.

Definition at line 1212 of file sch_sheet_path.cpp.

1213{
1214 for( SCH_SHEET_PATH& sheetPath : *this )
1215 sheetPath.AddNewSymbolInstances( aPrefixSheetPath );
1216}
void AddNewSymbolInstances(const SCH_SHEET_PATH &aPrefixSheetPath)
Attempt to add new symbol instances for all symbols in this sheet path prefixed with aPrefixSheetPath...

References SCH_SHEET_PATH::AddNewSymbolInstances().

Referenced by SCH_EDIT_FRAME::LoadSheetFromFile().

◆ AllSheetPageNumbersEmpty()

bool SCH_SHEET_LIST::AllSheetPageNumbersEmpty ( ) const

Check all of the sheet instance for empty page numbers.

Note
This should only return true when loading a legacy schematic or an s-expression schematic before version 20201005.
Returns
true if all sheet instance page numbers are not defined. Otherwise false.

Definition at line 1183 of file sch_sheet_path.cpp.

1184{
1185 for( const SCH_SHEET_PATH& instance : *this )
1186 {
1187 if( !instance.GetPageNumber().IsEmpty() )
1188 return false;
1189 }
1190
1191 return true;
1192}
wxString GetPageNumber() const

References SCH_SHEET_PATH::GetPageNumber().

Referenced by BOOST_AUTO_TEST_CASE(), SCH_EDIT_FRAME::OpenProjectFiles(), and SetInitialPageNumbers().

◆ AnnotatePowerSymbols()

void SCH_SHEET_LIST::AnnotatePowerSymbols ( )

Silently annotate the not yet annotated power symbols of the entire hierarchy of the sheet path list.

It is called before creating a netlist, to annotate power symbols, without prompting the user about not annotated or duplicate for these symbols, if only these symbols need annotation ( a very frequent case ).

Definition at line 856 of file sch_sheet_path.cpp.

857{
858 // List of reference for power symbols
859 SCH_REFERENCE_LIST references;
860 SCH_REFERENCE_LIST additionalreferences; // Todo: add as a parameter to this function
861
862 // Map of locked symbols (not used, but needed by Annotate()
863 SCH_MULTI_UNIT_REFERENCE_MAP lockedSymbols;
864
865 // Build the list of power symbols:
866 for( SCH_SHEET_PATH& sheet : *this )
867 {
868 for( SCH_ITEM* item : sheet.LastScreen()->Items().OfType( SCH_SYMBOL_T ) )
869 {
870 SCH_SYMBOL* symbol = static_cast<SCH_SYMBOL*>( item );
871 LIB_SYMBOL* libSymbol = symbol->GetLibSymbolRef().get();
872
873 if( libSymbol && libSymbol->IsPower() )
874 {
875 SCH_REFERENCE schReference( symbol, libSymbol, sheet );
876 references.AddItem( schReference );
877 }
878 }
879 }
880
881 // Find duplicate, and silently clear annotation of duplicate
882 std::map<wxString, int> ref_list; // stores the existing references
883
884 for( unsigned ii = 0; ii< references.GetCount(); ++ii )
885 {
886 wxString curr_ref = references[ii].GetRef();
887
888 if( ref_list.find( curr_ref ) == ref_list.end() )
889 {
890 ref_list[curr_ref] = ii;
891 continue;
892 }
893
894 // Possible duplicate, if the ref ends by a number:
895 if( curr_ref.Last() < '0' && curr_ref.Last() > '9' )
896 continue; // not annotated
897
898 // Duplicate: clear annotation by removing the number ending the ref
899 while( curr_ref.Last() >= '0' && curr_ref.Last() <= '9' )
900 curr_ref.RemoveLast();
901
902 references[ii].SetRef( curr_ref );
903 }
904
905 // Break full symbol reference into name (prefix) and number:
906 // example: IC1 become IC, and 1
907 references.SplitReferences();
908
909 // Ensure all power symbols have the reference starting by '#'
910 // (Not sure this is really useful)
911 for( unsigned ii = 0; ii< references.GetCount(); ++ii )
912 {
913 if( references[ii].GetRef()[0] != '#' )
914 {
915 wxString new_ref = "#" + references[ii].GetRef();
916 references[ii].SetRef( new_ref );
917 }
918 }
919
920 // Recalculate and update reference numbers in schematic
921 references.Annotate( false, 0, 100, lockedSymbols, additionalreferences );
922 references.UpdateAnnotation();
923}
EE_TYPE OfType(KICAD_T aType) const
Definition: sch_rtree.h:238
Define a library symbol object.
Definition: lib_symbol.h:99
bool IsPower() const
Definition: lib_symbol.cpp:545
Base class for any item which can be embedded within the SCHEMATIC container class,...
Definition: sch_item.h:147
Container to create a flattened list of symbols because in a complex hierarchy, a symbol can be used ...
void Annotate(bool aUseSheetNum, int aSheetIntervalId, int aStartNumber, SCH_MULTI_UNIT_REFERENCE_MAP aLockedUnitMap, const SCH_REFERENCE_LIST &aAdditionalRefs, bool aStartAtCurrent=false)
Set the reference designators in the list that have not been annotated.
size_t GetCount() const
void SplitReferences()
Attempt to split all reference designators into a name (U) and number (1).
void AddItem(const SCH_REFERENCE &aItem)
void UpdateAnnotation()
Update the symbol references for the schematic project (or the current sheet).
A helper to define a symbol's reference designator in a schematic.
EE_RTREE & Items()
Gets the full RTree, usually for iterating.
Definition: sch_screen.h:109
SCH_SCREEN * LastScreen()
Schematic symbol object.
Definition: sch_symbol.h:81
std::unique_ptr< LIB_SYMBOL > & GetLibSymbolRef()
Definition: sch_symbol.h:192
std::map< wxString, SCH_REFERENCE_LIST > SCH_MULTI_UNIT_REFERENCE_MAP
Container to map reference designators for multi-unit parts.
@ SCH_SYMBOL_T
Definition: typeinfo.h:156

References SCH_REFERENCE_LIST::AddItem(), SCH_REFERENCE_LIST::Annotate(), SCH_REFERENCE_LIST::GetCount(), SCH_SYMBOL::GetLibSymbolRef(), LIB_SYMBOL::IsPower(), SCH_SCREEN::Items(), SCH_SHEET_PATH::LastScreen(), EE_RTREE::OfType(), SCH_SYMBOL_T, SCH_REFERENCE_LIST::SplitReferences(), and SCH_REFERENCE_LIST::UpdateAnnotation().

Referenced by KI_TEST::LoadSchematic(), EESCHEMA_HELPERS::LoadSchematic(), DIALOG_ERC::OnRunERCClick(), SCH::readSchematicFromFile(), SCH_EDIT_FRAME::ReadyToNetlist(), DIALOG_ERC::testErc(), and SCH_EDIT_FRAME::WriteNetListFile().

◆ BuildSheetList()

void SCH_SHEET_LIST::BuildSheetList ( SCH_SHEET aSheet,
bool  aCheckIntegrity 
)

Build the list of sheets and their sheet path from aSheet.

If aSheet is the root sheet, the full sheet path and sheet list are built.

The list will be ordered as per SCH_SCREEN::GetSheets which results in sheets being ordered in the legacy way of using the X and Y positions of the sheets.

See also
SortByPageNumbers to sort by page numbers
Parameters
aSheetis the starting sheet from which the list is built, or NULL indicating that g_RootSheet should be used.
Exceptions
std::bad_allocif the memory for the sheet path list could not be allocated.

Definition at line 672 of file sch_sheet_path.cpp.

673{
674 wxCHECK_RET( aSheet != nullptr, wxT( "Cannot build sheet list from undefined sheet." ) );
675
676 std::vector<SCH_SHEET*> badSheets;
677
679 m_currentSheetPath.SetVirtualPageNumber( static_cast<int>( size() ) + 1 );
680 push_back( m_currentSheetPath );
681
683 {
684 wxString parentFileName = aSheet->GetFileName();
685 std::vector<SCH_ITEM*> childSheets;
686 m_currentSheetPath.LastScreen()->GetSheets( &childSheets );
687
688 for( SCH_ITEM* item : childSheets )
689 {
690 SCH_SHEET* sheet = static_cast<SCH_SHEET*>( item );
691
692 if( aCheckIntegrity )
693 {
694 if( !m_currentSheetPath.TestForRecursion( sheet->GetFileName(), parentFileName ) )
695 BuildSheetList( sheet, true );
696 else
697 badSheets.push_back( sheet );
698 }
699 else
700 {
701 BuildSheetList( sheet, false );
702 }
703 }
704 }
705
706 if( aCheckIntegrity )
707 {
708 for( SCH_SHEET* sheet : badSheets )
709 {
712 }
713 }
714
716}
void SetContentModified(bool aModified=true)
Definition: base_screen.h:59
bool Remove(SCH_ITEM *aItem, bool aUpdateLibSymbol=true)
Remove aItem from the schematic associated with this screen.
Definition: sch_screen.cpp:307
void GetSheets(std::vector< SCH_ITEM * > *aItems) const
Similar to Items().OfType( SCH_SHEET_T ), but return the sheets in a deterministic order (L-R,...
SCH_SHEET_PATH m_currentSheetPath
bool TestForRecursion(const wxString &aSrcFileName, const wxString &aDestFileName)
Test the SCH_SHEET_PATH file names to check adding the sheet stored in the file aSrcFileName to the s...
void SetVirtualPageNumber(int aPageNumber)
Set the sheet instance virtual page number.
void push_back(SCH_SHEET *aSheet)
Forwarded method from std::vector.
wxString GetFileName() const
Return the filename corresponding to this sheet.
Definition: sch_sheet.h:302

References BuildSheetList(), SCH_SHEET::GetFileName(), SCH_SCREEN::GetSheets(), SCH_SHEET_PATH::LastScreen(), m_currentSheetPath, SCH_SHEET_PATH::pop_back(), SCH_SHEET_PATH::push_back(), SCH_SCREEN::Remove(), BASE_SCREEN::SetContentModified(), SCH_SHEET_PATH::SetVirtualPageNumber(), and SCH_SHEET_PATH::TestForRecursion().

Referenced by BuildSheetList(), SCH_PLOTTER::createDXFFiles(), SCH_PLOTTER::createHPGLFiles(), SCH_PLOTTER::createPDFFile(), SCH_PLOTTER::createPSFiles(), SCH_PLOTTER::createSVGFiles(), SCHEMATIC::GetFullHierarchy(), and SCH_SHEET_LIST().

◆ ClearModifyStatus()

void SCH_SHEET_LIST::ClearModifyStatus ( )

Definition at line 782 of file sch_sheet_path.cpp.

783{
784 for( const SCH_SHEET_PATH& sheet : *this )
785 {
786 if( sheet.LastScreen() )
787 sheet.LastScreen()->SetContentModified( false );
788 }
789}

References SCH_SHEET_PATH::LastScreen(), and BASE_SCREEN::SetContentModified().

Referenced by SCH_EDIT_FRAME::doCloseWindow().

◆ FillItemMap()

void SCH_SHEET_LIST::FillItemMap ( std::map< KIID, EDA_ITEM * > &  aMap)

Fill an item cache for temporary use when many items need to be fetched.

Definition at line 836 of file sch_sheet_path.cpp.

837{
838 for( const SCH_SHEET_PATH& sheet : *this )
839 {
840 SCH_SCREEN* screen = sheet.LastScreen();
841
842 for( SCH_ITEM* aItem : screen->Items() )
843 {
844 aMap[ aItem->m_Uuid ] = aItem;
845
846 aItem->RunOnChildren(
847 [&]( SCH_ITEM* aChild )
848 {
849 aMap[ aChild->m_Uuid ] = aChild;
850 } );
851 }
852 }
853}
const KIID m_Uuid
Definition: eda_item.h:492

References SCH_SCREEN::Items(), SCH_SHEET_PATH::LastScreen(), and EDA_ITEM::m_Uuid.

Referenced by SCH_EDITOR_CONTROL::Paste(), and DIALOG_ERC::writeReport().

◆ FindAllSheetsForScreen()

SCH_SHEET_LIST SCH_SHEET_LIST::FindAllSheetsForScreen ( const SCH_SCREEN aScreen) const

Return a SCH_SHEET_LIST with a copy of all the SCH_SHEET_PATH using a particular screen.

Definition at line 1060 of file sch_sheet_path.cpp.

1061{
1062 SCH_SHEET_LIST retval;
1063
1064 for( const SCH_SHEET_PATH& sheetpath : *this )
1065 {
1066 if( sheetpath.LastScreen() == aScreen )
1067 retval.push_back( sheetpath );
1068 }
1069
1070 return retval;
1071}

References SCH_SHEET_PATH::LastScreen().

Referenced by SCH_EDITOR_CONTROL::Paste(), SCH_DRAWING_TOOLS::PlaceSymbol(), and SCH_FIND_REPLACE_TOOL::ReplaceAll().

◆ FindSheetForPath()

SCH_SHEET_PATH * SCH_SHEET_LIST::FindSheetForPath ( const SCH_SHEET_PATH aPath)

Return a pointer to the first SCH_SHEET_PATH object (not necessarily the only one) matching the provided path.

Returns nullptr if not found.

Definition at line 1036 of file sch_sheet_path.cpp.

1037{
1038 for( SCH_SHEET_PATH& path : *this )
1039 {
1040 if( path.Path() == aPath->Path() )
1041 return &path;
1042 }
1043
1044 return nullptr;
1045}
KIID_PATH Path() const
Get the sheet path as an KIID_PATH.

References SCH_SHEET_PATH::Path(), and path.

Referenced by SCH_REFERENCE_LIST::ReannotateByOptions().

◆ FindSheetForScreen()

SCH_SHEET_PATH * SCH_SHEET_LIST::FindSheetForScreen ( const SCH_SCREEN aScreen)

Return a pointer to the first SCH_SHEET_PATH object (not necessarily the only one) using a particular screen.

Definition at line 1048 of file sch_sheet_path.cpp.

1049{
1050 for( SCH_SHEET_PATH& sheetpath : *this )
1051 {
1052 if( sheetpath.LastScreen() == aScreen )
1053 return &sheetpath;
1054 }
1055
1056 return nullptr;
1057}

References SCH_SHEET_PATH::LastScreen().

Referenced by SCH_EDIT_FRAME::PutDataInPreviousState().

◆ GetItem()

SCH_ITEM * SCH_SHEET_LIST::GetItem ( const KIID aID,
SCH_SHEET_PATH aPathOut = nullptr 
) const

Fetch a SCH_ITEM by ID.

Also returns the sheet the item was found on in aPathOut.

Definition at line 792 of file sch_sheet_path.cpp.

793{
794 for( const SCH_SHEET_PATH& sheet : *this )
795 {
796 SCH_ITEM* item = sheet.GetItem( aID );
797
798 if( item )
799 {
800 if( aPathOut )
801 *aPathOut = sheet;
802
803 return item;
804 }
805 }
806
807 // Not found; weak reference has been deleted.
809}
static DELETED_SHEET_ITEM * GetInstance()
SCH_ITEM * GetItem(const KIID &aID) const
Fetch a SCH_ITEM by ID.

References DELETED_SHEET_ITEM::GetInstance(), and SCH_SHEET_PATH::GetItem().

Referenced by SCHEMATIC::ConvertKIIDsToRefs(), SCH_EDIT_FRAME::FocusOnItem(), SCH_EDIT_FRAME::GetItem(), TEST_SCH_REFERENCE_LIST_FIXTURE::getSymbolByKIID(), DIALOG_ERC::OnERCItemSelected(), SCHEMATIC::ResolveCrossReference(), SCH_EDIT_FRAME::ResolveERCExclusions(), and SCH_EDIT_FRAME::SaveSymbolToSchematic().

◆ GetLastVirtualPageNumber()

int SCH_SHEET_LIST::GetLastVirtualPageNumber ( ) const

Definition at line 1292 of file sch_sheet_path.cpp.

1293{
1294 int lastVirtualPageNumber = 1;
1295
1296 for( const SCH_SHEET_PATH& sheetPath : *this )
1297 {
1298 if( sheetPath.GetVirtualPageNumber() > lastVirtualPageNumber )
1299 lastVirtualPageNumber = sheetPath.GetVirtualPageNumber();
1300 }
1301
1302 return lastVirtualPageNumber;
1303}
int GetVirtualPageNumber() const

References SCH_SHEET_PATH::GetVirtualPageNumber().

Referenced by SCH_EDIT_FRAME::LoadSheetFromFile().

◆ GetMultiUnitSymbols()

void SCH_SHEET_LIST::GetMultiUnitSymbols ( SCH_MULTI_UNIT_REFERENCE_MAP aRefList,
bool  aIncludePowerSymbols = true 
) const

Add a SCH_REFERENCE_LIST object to aRefList for each same-reference set of multi-unit parts in the list of sheets.

The map key for each element will be the reference designator.

Parameters
aRefListMap of reference designators to reference lists
aIncludePowerSymbolsSet to false to only get normal symbols.

Definition at line 976 of file sch_sheet_path.cpp.

978{
979 for( SCH_SHEET_PATHS::const_iterator it = begin(); it != end(); ++it )
980 {
982 ( *it ).GetMultiUnitSymbols( tempMap, aIncludePowerSymbols );
983
984 for( SCH_MULTI_UNIT_REFERENCE_MAP::value_type& pair : tempMap )
985 {
986 // Merge this list into the main one
987 unsigned n_refs = pair.second.GetCount();
988
989 for( unsigned thisRef = 0; thisRef < n_refs; ++thisRef )
990 aRefList[pair.first].AddItem( pair.second[thisRef] );
991 }
992 }
993}

Referenced by SCH_EDIT_FRAME::AnnotateSymbols(), BACK_ANNOTATE::BackAnnotateSymbols(), ERC_TESTER::TestMissingUnits(), and ERC_TESTER::TestMultiunitFootprints().

◆ GetPaths()

std::vector< KIID_PATH > SCH_SHEET_LIST::GetPaths ( ) const

Definition at line 1148 of file sch_sheet_path.cpp.

1149{
1150 std::vector<KIID_PATH> paths;
1151
1152 for( const SCH_SHEET_PATH& sheetPath : *this )
1153 paths.emplace_back( sheetPath.Path() );
1154
1155 return paths;
1156}

References SCH_SHEET_PATH::Path().

◆ GetSheetInstances()

std::vector< SCH_SHEET_INSTANCE > SCH_SHEET_LIST::GetSheetInstances ( ) const

Fetch the instance information for all of the sheets in the hiearchy.

Returns
all of the sheet instance data for the hierarchy.

Definition at line 1159 of file sch_sheet_path.cpp.

1160{
1161 std::vector<SCH_SHEET_INSTANCE> retval;
1162
1163 for( const SCH_SHEET_PATH& path : *this )
1164 {
1165 const SCH_SHEET* sheet = path.Last();
1166
1167 wxCHECK2( sheet, continue );
1168
1169 SCH_SHEET_INSTANCE instance;
1170 SCH_SHEET_PATH tmpPath = path;
1171
1172 tmpPath.pop_back();
1173 instance.m_Path = tmpPath.Path();
1174 instance.m_PageNumber = path.GetPageNumber();
1175
1176 retval.push_back( instance );
1177 }
1178
1179 return retval;
1180}

References SCH_SHEET_INSTANCE::m_PageNumber, SCH_SHEET_INSTANCE::m_Path, SCH_SHEET_PATH::Path(), path, and SCH_SHEET_PATH::pop_back().

Referenced by SCH_SEXPR_PLUGIN::Format().

◆ GetSheetPathByKIIDPath()

std::optional< SCH_SHEET_PATH > SCH_SHEET_LIST::GetSheetPathByKIIDPath ( const KIID_PATH aPath,
bool  aIncludeLastSheet = true 
) const

Finds a SCH_SHEET_PATH that matches the provided KIID_PATH.

Parameters
aPathThe KIID_PATH to search for.

Definition at line 958 of file sch_sheet_path.cpp.

960{
961 for( const SCH_SHEET_PATH& sheet : *this )
962 {
963 KIID_PATH testPath = sheet.Path();
964
965 if( !aIncludeLastSheet )
966 testPath.pop_back();
967
968 if( testPath == aPath )
969 return SCH_SHEET_PATH( sheet );
970 }
971
972 return std::nullopt;
973}

References SCH_SHEET_PATH::Path().

Referenced by SCH_MARKER::Deserialize(), findItemsFromSyncSelection(), SCH_SEXPR_PLUGIN::saveSheet(), and SCH_SEXPR_PLUGIN::saveSymbol().

◆ GetSheetsWithinPath()

void SCH_SHEET_LIST::GetSheetsWithinPath ( SCH_SHEET_PATHS aSheets,
const SCH_SHEET_PATH aSheetPath 
) const

Add a SCH_SHEET_PATH object to aSheets for each sheet in the list that are contained within aSheetPath as well as recursively downwards inside aSheetPath.

Parameters
aReferencesList of sheets to populate.
aSheetPathPath to return sheets from

Definition at line 947 of file sch_sheet_path.cpp.

949{
950 for( const SCH_SHEET_PATH& sheet : *this )
951 {
952 if( sheet.IsContainedWithin( aSheetPath ) )
953 aSheets.push_back( sheet );
954 }
955}
bool IsContainedWithin(const SCH_SHEET_PATH &aSheetPathToTest) const
Check if this path is contained inside aSheetPathToTest.

References SCH_SHEET_PATH::IsContainedWithin().

Referenced by SCH_EDIT_FRAME::AnnotateSymbols(), SCH_EDIT_FRAME::CheckAnnotate(), SCH_EDIT_FRAME::DeleteAnnotation(), and SCH_SEXPR_PLUGIN::Format().

◆ GetSymbols()

void SCH_SHEET_LIST::GetSymbols ( SCH_REFERENCE_LIST aReferences,
bool  aIncludePowerSymbols = true,
bool  aForceIncludeOrphanSymbols = false 
) const

Add a SCH_REFERENCE object to aReferences for each symbol in the list of sheets.

Parameters
aReferencesList of references to populate.
aIncludePowerSymbolsSet to false to only get normal symbols.
aForceIncludeOrphanSymbolsSet to true to include symbols having no symbol found in lib. The normal option is false, and set to true only to build the full list of symbols.

Definition at line 926 of file sch_sheet_path.cpp.

928{
929 for( const SCH_SHEET_PATH& sheet : *this )
930 sheet.GetSymbols( aReferences, aIncludePowerSymbols, aForceIncludeOrphanSymbols );
931}
void GetSymbols(SCH_REFERENCE_LIST &aReferences, bool aIncludePowerSymbols=true, bool aForceIncludeOrphanSymbols=false) const
Adds SCH_REFERENCE object to aReferences for each symbol in the sheet.

References SCH_SHEET_PATH::GetSymbols().

Referenced by SCH_EDIT_FRAME::AnnotateSymbols(), SCH_EDITOR_CONTROL::AssignFootprints(), BACK_ANNOTATE::BackAnnotateSymbols(), SCH_EDIT_FRAME::CheckAnnotate(), SCHEMATIC::ConvertRefsToKIIDs(), DIALOG_SYMBOL_FIELDS_TABLE::DIALOG_SYMBOL_FIELDS_TABLE(), SCH_EDITOR_CONTROL::ExportSymbolsToLibrary(), TEST_SCH_REFERENCE_LIST_FIXTURE::getAdditionalRefs(), DIALOG_EDIT_SYMBOLS_LIBID::initDlg(), EESCHEMA_JOBS_HANDLER::JobExportNetlist(), EESCHEMA_JOBS_HANDLER::JobExportPythonBom(), SCH_EDIT_FRAME::mapExistingAnnotation(), DIALOG_SCH_FIELD_PROPERTIES::onScintillaCharAdded(), DIALOG_TEXT_PROPERTIES::onScintillaCharAdded(), SCH_EDITOR_CONTROL::Paste(), SCH_DRAWING_TOOLS::PlaceSymbol(), and SCH_EDITOR_CONTROL::processCmpToFootprintLinkFile().

◆ GetSymbolsWithinPath()

void SCH_SHEET_LIST::GetSymbolsWithinPath ( SCH_REFERENCE_LIST aReferences,
const SCH_SHEET_PATH aSheetPath,
bool  aIncludePowerSymbols = true,
bool  aForceIncludeOrphanSymbols = false 
) const

Add a SCH_REFERENCE object to aReferences for each symbol in the list of sheets that are contained within aSheetPath as well as recursively downwards inside aSheetPath.

Parameters
aReferencesList of references to populate.
aSheetPathPath to return symbols from
aIncludePowerSymbolsSet to false to only get normal symbols.
aForceIncludeOrphanSymbolsSet to true to include symbols having no symbol found in lib. The normal option is false, and set to true only to build the full list of symbols.

Definition at line 934 of file sch_sheet_path.cpp.

938{
939 for( const SCH_SHEET_PATH& sheet : *this )
940 {
941 if( sheet.IsContainedWithin( aSheetPath ) )
942 sheet.GetSymbols( aReferences, aIncludePowerSymbols, aForceIncludeOrphanSymbols );
943 }
944}

References SCH_SHEET_PATH::GetSymbols(), and SCH_SHEET_PATH::IsContainedWithin().

Referenced by SCH_EDIT_FRAME::AnnotateSymbols(), and SCH_SEXPR_PLUGIN::Format().

◆ IsModified()

bool SCH_SHEET_LIST::IsModified ( ) const

Check the entire hierarchy for any modifications.

Returns
True if the hierarchy is modified otherwise false.

Definition at line 770 of file sch_sheet_path.cpp.

771{
772 for( const SCH_SHEET_PATH& sheet : *this )
773 {
774 if( sheet.LastScreen() && sheet.LastScreen()->IsContentModified() )
775 return true;
776 }
777
778 return false;
779}
bool IsContentModified() const
Definition: base_screen.h:60

References BASE_SCREEN::IsContentModified(), and SCH_SHEET_PATH::LastScreen().

Referenced by SCH_EDIT_FRAME::canCloseWindow(), SCH_EDIT_FRAME::IsContentModified(), and SCH_EDIT_FRAME::OpenProjectFiles().

◆ NameExists()

bool SCH_SHEET_LIST::NameExists ( const wxString &  aSheetName) const

Definition at line 746 of file sch_sheet_path.cpp.

747{
748 for( const SCH_SHEET_PATH& sheet : *this )
749 {
750 if( sheet.Last()->GetName() == aSheetName )
751 return true;
752 }
753
754 return false;
755}
SCH_SHEET * Last() const
Return a pointer to the last SCH_SHEET of the list.
wxString GetName() const
Definition: sch_sheet.h:103

References SCH_SHEET::GetName(), and SCH_SHEET_PATH::Last().

Referenced by SCH_EDITOR_CONTROL::Paste().

◆ PageNumberExists()

bool SCH_SHEET_LIST::PageNumberExists ( const wxString &  aPageNumber) const

Definition at line 758 of file sch_sheet_path.cpp.

759{
760 for( const SCH_SHEET_PATH& sheet : *this )
761 {
762 if( sheet.GetPageNumber() == aPageNumber )
763 return true;
764 }
765
766 return false;
767}

References SCH_SHEET_PATH::GetPageNumber().

Referenced by SCH_EDITOR_CONTROL::Paste().

◆ RemoveSymbolInstances()

void SCH_SHEET_LIST::RemoveSymbolInstances ( const SCH_SHEET_PATH aPrefixSheetPath)

Definition at line 1219 of file sch_sheet_path.cpp.

1220{
1221 for( SCH_SHEET_PATH& sheetPath : *this )
1222 sheetPath.RemoveSymbolInstances( aPrefixSheetPath );
1223}
void RemoveSymbolInstances(const SCH_SHEET_PATH &aPrefixSheetPath)

References SCH_SHEET_PATH::RemoveSymbolInstances().

◆ SetInitialPageNumbers()

void SCH_SHEET_LIST::SetInitialPageNumbers ( )

Set initial sheet page numbers.

The number scheme is base on the old pseudo sheet numbering algorithm prior to the implementation of user definable sheet page numbers.

Definition at line 1195 of file sch_sheet_path.cpp.

1196{
1197 // Don't accidentally renumber existing sheets.
1198 wxCHECK( AllSheetPageNumbersEmpty(), /* void */ );
1199
1200 wxString tmp;
1201 int pageNumber = 1;
1202
1203 for( SCH_SHEET_PATH& instance : *this )
1204 {
1205 tmp.Printf( "%d", pageNumber );
1206 instance.SetPageNumber( tmp );
1207 pageNumber += 1;
1208 }
1209}
bool AllSheetPageNumbersEmpty() const
Check all of the sheet instance for empty page numbers.
void SetPageNumber(const wxString &aPageNumber)
Set the sheet instance user definable page number.

References AllSheetPageNumbersEmpty(), and SCH_SHEET_PATH::SetPageNumber().

Referenced by BOOST_AUTO_TEST_CASE(), and SCH_EDIT_FRAME::OpenProjectFiles().

◆ SortByPageNumbers()

void SCH_SHEET_LIST::SortByPageNumbers ( bool  aUpdateVirtualPageNums = true)

Sort the list of sheets by page number.

This should be called after BuildSheetList

If page numbers happen to be equal, then it compares the sheet names to ensure deterministic ordering.

Parameters
aUpdateVirtualPageNumsIf true, updates the virtual page numbers to match the new ordering

Enforce strict ordering. If the page numbers are the same, use UUIDs

Definition at line 719 of file sch_sheet_path.cpp.

720{
721 std::sort( begin(), end(),
722 []( SCH_SHEET_PATH a, SCH_SHEET_PATH b ) -> bool
723 {
724 int retval = a.ComparePageNum( b );
725
726 if( retval < 0 )
727 return true;
728 else if( retval > 0 )
729 return false;
730 else
731 return a.GetCurrentHash() < b.GetCurrentHash();
732 } );
733
734 if( aUpdateVirtualPageNums )
735 {
736 int virtualPageNum = 1;
737
738 for( SCH_SHEET_PATH& sheet : *this )
739 {
740 sheet.SetVirtualPageNumber( virtualPageNum++ );
741 }
742 }
743}
int ComparePageNum(const SCH_SHEET_PATH &aSheetPathToTest) const
Compare sheets by their page number.
size_t GetCurrentHash() const

References SCH_SHEET_PATH::ComparePageNum(), SCH_SHEET_PATH::GetCurrentHash(), and SCH_SHEET_PATH::SetVirtualPageNumber().

Referenced by SCH_PLOTTER::createDXFFiles(), SCH_PLOTTER::createHPGLFiles(), SCH_PLOTTER::createPDFFile(), SCH_PLOTTER::createPSFiles(), SCH_PLOTTER::createSVGFiles(), DIALOG_TEXT_PROPERTIES::DIALOG_TEXT_PROPERTIES(), SCH_SEXPR_PLUGIN::Format(), SCH_EDITOR_CONTROL::Paste(), SCH_DRAWING_TOOLS::PlaceSymbol(), and SCH_SHEET_LIST().

◆ TestForRecursion()

bool SCH_SHEET_LIST::TestForRecursion ( const SCH_SHEET_LIST aSrcSheetHierarchy,
const wxString &  aDestFileName 
)

Test every SCH_SHEET_PATH in this SCH_SHEET_LIST to verify if adding the sheets stored in aSrcSheetHierarchy to the sheet stored in aDestFileName will cause recursion.

Parameters
aSrcSheetHierarchyis the SCH_SHEET_LIST of the source sheet add to aDestFileName.
aDestFileNameis the file name of the destination sheet for aSrcFileName.
Returns
true if aFileName will cause recursion in the sheet path. Otherwise false.

Definition at line 996 of file sch_sheet_path.cpp.

998{
999 if( empty() )
1000 return false;
1001
1002 SCHEMATIC* sch = at( 0 ).LastScreen()->Schematic();
1003
1004 wxCHECK_MSG( sch, false, "No SCHEMATIC found in SCH_SHEET_LIST::TestForRecursion!" );
1005
1006 wxFileName rootFn = sch->GetFileName();
1007 wxFileName destFn = aDestFileName;
1008
1009 if( destFn.IsRelative() )
1010 destFn.MakeAbsolute( rootFn.GetPath() );
1011
1012 // Test each SCH_SHEET_PATH in this SCH_SHEET_LIST for potential recursion.
1013 for( unsigned i = 0; i < size(); i++ )
1014 {
1015 // Test each SCH_SHEET_PATH in the source sheet.
1016 for( unsigned j = 0; j < aSrcSheetHierarchy.size(); j++ )
1017 {
1018 const SCH_SHEET_PATH* sheetPath = &aSrcSheetHierarchy[j];
1019
1020 for( unsigned k = 0; k < sheetPath->size(); k++ )
1021 {
1022 if( at( i ).TestForRecursion( sheetPath->GetSheet( k )->GetFileName(),
1023 aDestFileName ) )
1024 {
1025 return true;
1026 }
1027 }
1028 }
1029 }
1030
1031 // The source sheet file can safely be added to the destination sheet file.
1032 return false;
1033}
Holds all the data relating to one schematic.
Definition: schematic.h:61
wxString GetFileName() const override
Helper to retrieve the filename from the root sheet screen.
Definition: schematic.cpp:199
const SCH_SHEET * GetSheet(unsigned aIndex) const
static bool empty(const wxTextEntryBase *aCtrl)

References empty(), SCH_SHEET::GetFileName(), SCHEMATIC::GetFileName(), SCH_SHEET_PATH::GetSheet(), and SCH_SHEET_PATH::size().

Referenced by SCH_EDIT_FRAME::CheckSheetForRecursion(), and SCH_EDITOR_CONTROL::Paste().

◆ UpdateSheetInstanceData()

void SCH_SHEET_LIST::UpdateSheetInstanceData ( const std::vector< SCH_SHEET_INSTANCE > &  aSheetInstances)

Update all of the sheet instance information using aSheetInstances.

Warning
Do not call this on anything other than the full hierarchy.
Parameters
aSymbolInstancesis the symbol path information loaded from the root schematic.

Definition at line 1118 of file sch_sheet_path.cpp.

1119{
1120
1121 for( SCH_SHEET_PATH& path : *this )
1122 {
1123 SCH_SHEET* sheet = path.Last();
1124
1125 wxCHECK2( sheet && path.Last(), continue );
1126
1127 auto it = std::find_if( aSheetInstances.begin(), aSheetInstances.end(),
1128 [ path ]( const SCH_SHEET_INSTANCE& r ) -> bool
1129 {
1130 return path.Path() == r.m_Path;
1131 } );
1132
1133 if( it == aSheetInstances.end() )
1134 {
1135 wxLogTrace( traceSchSheetPaths, "No sheet instance found for path '%s'",
1136 path.Path().AsString() );
1137 continue;
1138 }
1139
1140 wxLogTrace( traceSchSheetPaths, "Setting sheet '%s' instance '%s' page number '%s'",
1141 ( sheet->GetName().IsEmpty() ) ? wxString( wxT( "root" ) ) : sheet->GetName(),
1142 path.Path().AsString(), it->m_PageNumber );
1143 path.SetPageNumber( it->m_PageNumber );
1144 }
1145}
const wxChar *const traceSchSheetPaths
Flag to enable debug output of schematic symbol sheet path manipulation code.

References SCH_SHEET::GetName(), path, and traceSchSheetPaths.

Referenced by KI_TEST::LoadSchematic(), EESCHEMA_HELPERS::LoadSchematic(), and SCH_EDIT_FRAME::OpenProjectFiles().

◆ UpdateSymbolInstanceData()

void SCH_SHEET_LIST::UpdateSymbolInstanceData ( const std::vector< SCH_SYMBOL_INSTANCE > &  aSymbolInstances)

Update all of the symbol instance information using aSymbolInstances.

WARNING: Do not call this on anything other than the full hierarchy.

Parameters
aSymbolInstancesis the symbol path information loaded from the root schematic.

Definition at line 1074 of file sch_sheet_path.cpp.

1076{
1077 for( SCH_SHEET_PATH& sheetPath : *this )
1078 {
1079 for( SCH_ITEM* item : sheetPath.LastScreen()->Items().OfType( SCH_SYMBOL_T ) )
1080 {
1081 SCH_SYMBOL* symbol = static_cast<SCH_SYMBOL*>( item );
1082
1083 wxCHECK2( symbol, continue );
1084
1085 KIID_PATH sheetPathWithSymbolUuid = sheetPath.Path();
1086 sheetPathWithSymbolUuid.push_back( symbol->m_Uuid );
1087
1088 auto it = std::find_if( aSymbolInstances.begin(), aSymbolInstances.end(),
1089 [ sheetPathWithSymbolUuid ]( const SCH_SYMBOL_INSTANCE& r ) -> bool
1090 {
1091 return sheetPathWithSymbolUuid == r.m_Path;
1092 } );
1093
1094 if( it == aSymbolInstances.end() )
1095 {
1096 wxLogTrace( traceSchSheetPaths, "No symbol instance found for symbol '%s'",
1097 sheetPathWithSymbolUuid.AsString() );
1098 continue;
1099 }
1100
1101 // Symbol instance paths are stored and looked up in memory with the root path so use
1102 // the full path here.
1103 symbol->AddHierarchicalReference( sheetPath.Path(), it->m_Reference, it->m_Unit );
1104 symbol->GetField( REFERENCE_FIELD )->SetText( it->m_Reference );
1105
1106 if( !it->m_Value.IsEmpty() )
1107 symbol->SetValueFieldText( it->m_Value );
1108
1109 if( !it->m_Footprint.IsEmpty() )
1110 symbol->SetFootprintFieldText( it->m_Footprint );
1111
1112 symbol->UpdatePrefix();
1113 }
1114 }
1115}
virtual void SetText(const wxString &aText)
Definition: eda_text.cpp:165
wxString AsString() const
Definition: kiid.cpp:359
void UpdatePrefix()
Set the prefix based on the current reference designator.
Definition: sch_symbol.cpp:766
void SetValueFieldText(const wxString &aValue)
Definition: sch_symbol.cpp:844
SCH_FIELD * GetField(MANDATORY_FIELD_T aFieldType)
Return a mandatory field in this symbol.
Definition: sch_symbol.cpp:865
void SetFootprintFieldText(const wxString &aFootprint)
Definition: sch_symbol.cpp:859
void AddHierarchicalReference(const KIID_PATH &aPath, const wxString &aRef, int aUnit)
Add a full hierarchical reference to this symbol.
Definition: sch_symbol.cpp:572
A simple container for schematic symbol instance information.
@ REFERENCE_FIELD
Field Reference of part, i.e. "IC21".

References SCH_SYMBOL::AddHierarchicalReference(), KIID_PATH::AsString(), SCH_SYMBOL::GetField(), SCH_SCREEN::Items(), SCH_SHEET_PATH::LastScreen(), EDA_ITEM::m_Uuid, EE_RTREE::OfType(), SCH_SHEET_PATH::Path(), REFERENCE_FIELD, SCH_SYMBOL_T, SCH_SYMBOL::SetFootprintFieldText(), EDA_TEXT::SetText(), SCH_SYMBOL::SetValueFieldText(), traceSchSheetPaths, and SCH_SYMBOL::UpdatePrefix().

Referenced by KI_TEST::LoadSchematic(), EESCHEMA_HELPERS::LoadSchematic(), SCH_EDIT_FRAME::LoadSheetFromFile(), SCH_EDIT_FRAME::OpenProjectFiles(), and SCH::readSchematicFromFile().

Member Data Documentation

◆ m_currentSheetPath

SCH_SHEET_PATH SCH_SHEET_LIST::m_currentSheetPath
private

Definition at line 676 of file sch_sheet_path.h.

Referenced by BuildSheetList().


The documentation for this class was generated from the following files: