KiCad PCB EDA Suite
|
Build a wxGridTableBase by wrapping an SYMBOL_LIB_TABLE object. More...
Public Types | |
enum | SAVE_T { SAVE_OK , SAVE_SKIPPED } |
The set of return values from SaveSymbol() below. More... | |
Public Member Functions | |
void | SetValue (int aRow, int aCol, const wxString &aValue) override |
SYMBOL_LIB_TABLE_GRID (const SYMBOL_LIB_TABLE &aTableToEdit) | |
int | GetNumberRows () override |
int | GetNumberCols () override |
wxString | GetValue (int aRow, int aCol) override |
bool | CanGetValueAs (int aRow, int aCol, const wxString &aTypeName) override |
bool | GetValueAsBool (int aRow, int aCol) override |
void | SetValueAsBool (int aRow, int aCol, bool aValue) override |
bool | IsEmptyCell (int aRow, int aCol) override |
bool | InsertRows (size_t aPos=0, size_t aNumRows=1) override |
bool | AppendRows (size_t aNumRows=1) override |
bool | DeleteRows (size_t aPos, size_t aNumRows) override |
wxString | GetColLabelValue (int aCol) override |
bool | ContainsNickname (const wxString &aNickname) |
LIB_TABLE_ROW * | At (size_t aIndex) |
PROJECT::ELEM | ProjectElementType () override |
virtual void | Parse (LIB_TABLE_LEXER *aLexer) override |
Parse the #LIB_TABLE_LEXER s-expression library table format into the appropriate LIB_TABLE_ROW objects. | |
virtual void | Format (OUTPUTFORMATTER *aOutput, int aIndentLevel) const override |
Generate the table in s-expression format to aOutput with an indentation level of aIndentLevel. | |
SYMBOL_LIB_TABLE_ROW * | FindRow (const wxString &aNickName, bool aCheckIfEnabled=false) |
Return an SYMBOL_LIB_TABLE_ROW if aNickName is found in this table or in any chained fallBack table fragment. | |
int | GetModifyHash () |
void | EnumerateSymbolLib (const wxString &aNickname, wxArrayString &aAliasNames, bool aPowerSymbolsOnly=false) |
Return a list of symbol alias names contained within the library given by aNickname. | |
void | LoadSymbolLib (std::vector< LIB_SYMBOL * > &aAliasList, const wxString &aNickname, bool aPowerSymbolsOnly=false) |
LIB_SYMBOL * | LoadSymbol (const wxString &aNickname, const wxString &aName) |
Load a LIB_SYMBOL having aName from the library given by aNickname. | |
LIB_SYMBOL * | LoadSymbol (const LIB_ID &aLibId) |
SAVE_T | SaveSymbol (const wxString &aNickname, const LIB_SYMBOL *aSymbol, bool aOverwrite=true) |
Write aSymbol to an existing library given by aNickname. | |
void | DeleteSymbol (const wxString &aNickname, const wxString &aSymbolName) |
Deletes the aSymbolName from the library given by aNickname. | |
bool | IsSymbolLibWritable (const wxString &aNickname) |
Return true if the library given by aNickname is writable. | |
bool | IsSymbolLibLoaded (const wxString &aNickname) |
Return true if the library given by aNickname was successfully loaded. | |
void | DeleteSymbolLib (const wxString &aNickname) |
void | CreateSymbolLib (const wxString &aNickname) |
LIB_SYMBOL * | LoadSymbolWithOptionalNickname (const LIB_ID &aId) |
Load a LIB_SYMBOL having aFootprintId with possibly an empty library nickname. | |
bool | operator== (const SYMBOL_LIB_TABLE &aOther) const |
Compares this table against another. | |
bool | operator== (const LIB_TABLE &r) const |
Compares this table against another. | |
bool | operator!= (const SYMBOL_LIB_TABLE &aOther) const |
bool | operator!= (const LIB_TABLE &r) const |
unsigned | GetCount () const |
Get the number of rows contained in the table. | |
LIB_TABLE_ROW & | At (unsigned aIndex) |
Get the 'n'th LIB_TABLE_ROW object. | |
const LIB_TABLE_ROW & | At (unsigned aIndex) const |
Get the 'n'th LIB_TABLE_ROW object. | |
bool | IsEmpty (bool aIncludeFallback=true) |
Return true if the table is empty. | |
const wxString | GetDescription (const wxString &aNickname) |
bool | HasLibrary (const wxString &aNickname, bool aCheckEnabled=false) const |
Test for the existence of aNickname in the library table. | |
bool | HasLibraryWithPath (const wxString &aPath) const |
Test for the existence of aPath in the library table. | |
std::vector< wxString > | GetLogicalLibs () |
Return the logical library names, all of them that are pertinent to a look up done on this LIB_TABLE. | |
wxString | GetFullURI (const wxString &aLibNickname, bool aExpandEnvVars=true) const |
Return the full URI of the library mapped to aLibNickname. | |
bool | InsertRow (LIB_TABLE_ROW *aRow, bool doReplace=false) |
Adds aRow if it does not already exist or if doReplace is true. | |
bool | RemoveRow (const LIB_TABLE_ROW *aRow) |
Removes a row from the table and frees the pointer. | |
bool | ReplaceRow (size_t aIndex, LIB_TABLE_ROW *aRow) |
Replaces the Nth row with the given new row. | |
bool | ChangeRowOrder (size_t aIndex, int aOffset) |
Moves a row within the table. | |
void | TransferRows (LIB_TABLE_ROWS &aRowsList) |
Takes ownership of another list of rows; the original list will be freed. | |
const LIB_TABLE_ROW * | FindRowByURI (const wxString &aURI) |
void | Load (const wxString &aFileName) |
Load the library table using the path defined by aFileName aFallBackTable. | |
void | Save (const wxString &aFileName) const |
Write this library table to aFileName in s-expression form. | |
int | GetVersion () const |
Returns the version number (0 if unset) | |
Static Public Member Functions | |
static bool | LoadGlobalTable (SYMBOL_LIB_TABLE &aTable) |
Load the global symbol library table into aTable. | |
static wxString | GetGlobalTableFileName () |
Fetch the global symbol library table file name. | |
static const wxString | GlobalPathEnvVariableName () |
Return the name of the environment variable used to hold the directory of locally installed "KiCad sponsored" system symbol libraries. | |
static SYMBOL_LIB_TABLE & | GetGlobalLibTable () |
static const wxString & | GetSymbolLibTableFileName () |
static std::map< std::string, UTF8 > * | ParseOptions (const std::string &aOptionsList) |
Parses aOptionsList and places the result into a #PROPERTIES object which is returned. | |
static UTF8 | FormatOptions (const std::map< std::string, UTF8 > *aProperties) |
Returns a list of options from the aProperties parameter. | |
Static Public Attributes | |
static const char * | PropPowerSymsOnly = "pwr_sym_only" |
static const char * | PropNonPowerSymsOnly = "non_pwr_sym_only" |
Protected Member Functions | |
LIB_TABLE_ROW * | at (size_t aIndex) override |
size_t | size () const override |
LIB_TABLE_ROW * | makeNewRow () override |
LIB_TABLE_ROWS_ITER | begin () override |
LIB_TABLE_ROWS_ITER | insert (LIB_TABLE_ROWS_ITER aIterator, LIB_TABLE_ROW *aRow) override |
void | push_back (LIB_TABLE_ROW *aRow) override |
LIB_TABLE_ROWS_ITER | erase (LIB_TABLE_ROWS_ITER aFirst, LIB_TABLE_ROWS_ITER aLast) override |
void | clear () |
LIB_TABLE_ROW * | findRow (const wxString &aNickname, bool aCheckIfEnabled=false) const |
Return a LIB_TABLE_ROW if aNickname is found in this table or in any chained fallBack table fragment, else NULL. | |
bool | doInsertRow (LIB_TABLE_ROW *aRow, bool doReplace=false) |
Performs the mechanics of inserting a row, but without locking or reindexing. | |
bool | migrate () |
Updates the env vars from older version of KiCad, provided they do not currently resolve to anything. | |
void | reindex () |
Protected Attributes | |
std::unique_ptr< LIB_TABLE_IO > | m_io |
LIB_TABLE * | m_fallBack |
int | m_version |
Versioning to handle importing old tables. | |
LIB_TABLE_ROWS | m_rows |
Owning set of rows. | |
std::map< wxString, LIB_TABLE_ROWS_ITER > | m_rowsMap |
this is a non-owning index into the LIB_TABLE_ROWS table | |
std::shared_mutex | m_mutex |
Mutex to protect access to the rows vector. | |
Static Private Attributes | |
static int | m_modifyHash = 1 |
helper for GetModifyHash() | |
Friends | |
class | PANEL_SYM_LIB_TABLE |
class | SYMBOL_GRID_TRICKS |
Build a wxGridTableBase by wrapping an SYMBOL_LIB_TABLE object.
Definition at line 87 of file panel_sym_lib_table.cpp.
|
inherited |
The set of return values from SaveSymbol() below.
Enumerator | |
---|---|
SAVE_OK | |
SAVE_SKIPPED |
Definition at line 219 of file symbol_lib_table.h.
|
inline |
Definition at line 139 of file panel_sym_lib_table.cpp.
References LIB_TABLE::m_rows.
|
inlineoverrideinherited |
Definition at line 170 of file lib_table_grid.h.
References LIB_TABLE_GRID::makeNewRow(), and LIB_TABLE_GRID::push_back().
Referenced by DESIGN_BLOCK_GRID_TRICKS::paste_text(), SYMBOL_GRID_TRICKS::paste_text(), and FP_GRID_TRICKS::paste_text().
|
inlineinherited |
Definition at line 234 of file lib_table_grid.h.
References LIB_TABLE_GRID::at().
Referenced by LIB_TABLE_GRID_TRICKS::doPopupSelection(), and LIB_TABLE_GRID_TRICKS::showPopupMenu().
|
inlineoverrideprotectedvirtual |
Implements LIB_TABLE_GRID.
Definition at line 93 of file panel_sym_lib_table.cpp.
References LIB_TABLE::m_rows.
Referenced by SYMBOL_GRID_TRICKS::optionsEditor(), and SetValue().
|
inlineinherited |
Get the 'n'th LIB_TABLE_ROW object.
aIndex | index of row (must exist: from 0 to GetCount() - 1) |
Definition at line 435 of file lib_table_base.h.
Referenced by DESIGN_BLOCK_LIB_TABLE::LoadGlobalTable(), FP_LIB_TABLE::LoadGlobalTable(), SYMBOL_LIB_TABLE::LoadGlobalTable(), DESIGN_BLOCK_GRID_TRICKS::paste_text(), SYMBOL_GRID_TRICKS::paste_text(), FP_GRID_TRICKS::paste_text(), and PCB::IFACE::SaveFileAs().
|
inlineinherited |
Definition at line 443 of file lib_table_base.h.
|
inlineoverrideprotectedvirtual |
Implements LIB_TABLE_GRID.
Definition at line 102 of file panel_sym_lib_table.cpp.
References LIB_TABLE::m_rows.
|
inlineoverrideinherited |
Definition at line 84 of file lib_table_grid.h.
References COL_ENABLED, COL_VISIBLE, and LIB_TABLE_GRID::size().
|
inherited |
Moves a row within the table.
aIndex | is the current index of the row to move |
aOffset | is the number of positions to move it by in the table |
Definition at line 435 of file lib_table_base.cpp.
References LIB_TABLE::m_mutex, LIB_TABLE::m_rows, and LIB_TABLE::reindex().
Referenced by PANEL_SYM_LIB_TABLE::moveDownHandler(), and PANEL_SYM_LIB_TABLE::moveUpHandler().
|
protectedinherited |
Definition at line 186 of file lib_table_base.cpp.
References LIB_TABLE::m_rows, and LIB_TABLE::m_rowsMap.
Referenced by LIB_TABLE::Load(), DESIGN_BLOCK_LIB_TABLE::LoadGlobalTable(), and LIB_TABLE::TransferRows().
|
inlineinherited |
Definition at line 222 of file lib_table_grid.h.
References LIB_TABLE_GRID::at(), LIB_TABLE_ROW::GetNickName(), and LIB_TABLE_GRID::size().
|
inherited |
Definition at line 517 of file symbol_lib_table.cpp.
References SYMBOL_LIB_TABLE::FindRow(), LIB_TABLE_ROW::GetFullURI(), LIB_TABLE_ROW::GetProperties(), and SYMBOL_LIB_TABLE_ROW::plugin.
Referenced by SYMBOL_LIBRARY_MANAGER::addLibrary().
|
inlineoverrideinherited |
Definition at line 185 of file lib_table_grid.h.
References LIB_TABLE_GRID::begin(), LIB_TABLE_GRID::erase(), and LIB_TABLE_GRID::size().
|
inherited |
Deletes the aSymbolName from the library given by aNickname.
aNickname | is a locator for the "library", it is a "name" in LIB_TABLE_ROW. |
aSymbolName | is the name of a symbol to delete from the specified library. |
IO_ERROR | if there is a problem finding the footprint or the library, or deleting it. |
Definition at line 486 of file symbol_lib_table.cpp.
References SYMBOL_LIB_TABLE::FindRow(), LIB_TABLE_ROW::GetFullURI(), LIB_TABLE_ROW::GetProperties(), and SYMBOL_LIB_TABLE_ROW::plugin.
|
inherited |
Definition at line 509 of file symbol_lib_table.cpp.
References SYMBOL_LIB_TABLE::FindRow(), LIB_TABLE_ROW::GetFullURI(), LIB_TABLE_ROW::GetProperties(), and SYMBOL_LIB_TABLE_ROW::plugin.
|
protectedinherited |
Performs the mechanics of inserting a row, but without locking or reindexing.
Definition at line 361 of file lib_table_base.cpp.
References LIB_TABLE_ROW::GetNickName(), LIB_TABLE::m_rows, LIB_TABLE::m_rowsMap, LIB_TABLE::reindex(), and LIB_TABLE_ROW::SetParent().
Referenced by LIB_TABLE::InsertRow(), SYMBOL_LIB_TABLE::Parse(), DESIGN_BLOCK_LIB_TABLE::Parse(), and FP_LIB_TABLE::Parse().
|
inherited |
Return a list of symbol alias names contained within the library given by aNickname.
aNickname | is a locator for the "library", it is a "name" in LIB_TABLE_ROW. |
aAliasNames | is a reference to an array for the alias names. |
aPowerSymbolsOnly | is a flag to enumerate only power symbols. |
IO_ERROR | if the library cannot be found or loaded. |
Definition at line 339 of file symbol_lib_table.cpp.
References SYMBOL_LIB_TABLE::FindRow(), LIB_TABLE_ROW::GetFullURI(), LIB_TABLE_ROW::GetOptions(), LIB_TABLE_ROW::GetProperties(), SYMBOL_LIB_TABLE_ROW::plugin, SYMBOL_LIB_TABLE::PropPowerSymsOnly, LIB_TABLE_ROW::SetLoaded(), and LIB_TABLE_ROW::SetOptions().
Referenced by SYMBOL_LIBRARY_MANAGER::getOriginalSymbols(), DIALOG_EDIT_SYMBOLS_LIBID::onClickOrphansButton(), and SYMBOL_VIEWER_FRAME::ReCreateLibList().
|
inlineoverrideprotectedvirtual |
Implements LIB_TABLE_GRID.
Definition at line 111 of file panel_sym_lib_table.cpp.
References LIB_TABLE::m_rows.
|
inherited |
Return an SYMBOL_LIB_TABLE_ROW if aNickName is found in this table or in any chained fallBack table fragment.
The SCH_IO is loaded and attached to the "plugin" fieldf the SYMBOL_LIB_TABLE_ROW if not already loaded.
aNickName | is the name of the row to find. |
aCheckIfEnabled | is a flag to verify if the table entry is enabled or disabled. |
Definition at line 359 of file symbol_lib_table.cpp.
References LIB_TABLE::findRow(), SYMBOL_LIB_TABLE_ROW::plugin, SYMBOL_LIB_TABLE_ROW::setPlugin(), and SYMBOL_LIB_TABLE_ROW::type.
Referenced by SYMBOL_TREE_MODEL_ADAPTER::AddLibraries(), SYMBOL_LIB_TABLE::CreateSymbolLib(), SYMBOL_LIB_TABLE::DeleteSymbol(), SYMBOL_LIB_TABLE::DeleteSymbolLib(), EE_INSPECTION_TOOL::DiffSymbol(), SYMBOL_VIEWER_FRAME::DisplayLibInfos(), SYMBOL_LIB_TABLE::EnumerateSymbolLib(), SCH_EDITOR_CONTROL::ExportSymbolsToLibrary(), SYMBOL_LIBRARY_MANAGER::GetLibrary(), SYMBOL_LIB_TABLE::GetModifyHash(), SYMBOL_LIB_TABLE::IsSymbolLibLoaded(), SYMBOL_LIB_TABLE::IsSymbolLibWritable(), SYMBOL_EDIT_FRAME::KiwayMailIn(), SYMBOL_VIEWER_FRAME::KiwayMailIn(), SYMBOL_LIB_TABLE::LoadGlobalTable(), SCH_EDIT_FRAME::LoadSheetFromFile(), SYMBOL_LIB_TABLE::LoadSymbol(), SYMBOL_LIB_TABLE::LoadSymbolLib(), SYMBOL_LIB_TABLE_RESCUER::OpenRescueLibrary(), PANEL_SYMBOL_CHOOSER::PANEL_SYMBOL_CHOOSER(), SYMBOL_VIEWER_FRAME::ReCreateLibList(), SYMBOL_VIEWER_FRAME::ReCreateSymbolList(), SYMBOL_EDIT_FRAME::replaceLibTableEntry(), SYMBOL_LIB_TABLE::SaveSymbol(), SCH_BASE_FRAME::setSymWatcher(), SYMBOL_TREE_SYNCHRONIZING_ADAPTER::Sync(), ERC_TESTER::TestLibSymbolIssues(), and SYMBOL_LIB_TABLE_RESCUER::WriteRescueLibrary().
|
protectedinherited |
Return a LIB_TABLE_ROW if aNickname is found in this table or in any chained fallBack table fragment, else NULL.
aNickname | is the name of the library table entry to find. |
aCheckIfEnabled | is a flag to check if the library table entry is enabled. |
Definition at line 250 of file lib_table_base.cpp.
References LIB_TABLE_ROW::GetIsEnabled(), LIB_TABLE::m_fallBack, LIB_TABLE::m_mutex, and LIB_TABLE::m_rowsMap.
Referenced by SYMBOL_LIB_TABLE::FindRow(), DESIGN_BLOCK_LIB_TABLE::FindRow(), FP_LIB_TABLE::FindRow(), LIB_TABLE::GetDescription(), LIB_TABLE::GetFullURI(), and LIB_TABLE::HasLibrary().
|
inherited |
Definition at line 293 of file lib_table_base.cpp.
References LIB_TABLE::m_fallBack, LIB_TABLE::m_io, and LIB_TABLE::m_rows.
Referenced by PCB_EDIT_FRAME::ExportFootprintsToLibrary(), SYMBOL_EDIT_FRAME::KiwayMailIn(), FOOTPRINT_EDIT_FRAME::KiwayMailIn(), and DIALOG_SYMBOL_REMAP::remapSymbolToLibTable().
|
overridevirtualinherited |
Generate the table in s-expression format to aOutput with an indentation level of aIndentLevel.
aOutput | is the OUTPUTFORMATTER to format the table into. |
aIndentLevel | is the indentation level (2 spaces) to indent. |
IO_ERROR | if an I/O error occurs during output. |
boost::interprocess::lock_except | if separate process attempt to access the table. |
Implements LIB_TABLE.
Definition at line 304 of file symbol_lib_table.cpp.
References LIB_TABLE::m_rows, LIB_TABLE::m_version, and OUTPUTFORMATTER::Print().
Referenced by DIALOG_SYMBOL_REMAP::createProjectSymbolLibTable(), SCH_IO_ALTIUM::LoadSchematicFile(), SCH_IO_CADSTAR_ARCHIVE::LoadSchematicFile(), SCH_IO_EAGLE::LoadSchematicFile(), and SCH_IO_EASYEDAPRO::LoadSchematicFile().
Returns a list of options from the aProperties parameter.
The name=value pairs will be separated with the '|' character. The =value portion may not be present. You might expect something like "name1=value1|name2=value2|flag_me". Notice that flag_me does not have a value. This is ok.
aProperties | is the PROPERTIES to format or NULL. If NULL the returned string will be empty. |
Definition at line 606 of file lib_table_base.cpp.
References UTF8::begin(), UTF8::end(), name, OPT_SEP, and UTF8::size().
Referenced by DIALOG_PLUGIN_OPTIONS::TransferDataFromWindow().
|
inlineoverrideinherited |
Definition at line 204 of file lib_table_grid.h.
References _, COL_DESCR, COL_ENABLED, COL_NICKNAME, COL_OPTIONS, COL_TYPE, COL_URI, and COL_VISIBLE.
|
inlineinherited |
Get the number of rows contained in the table.
Definition at line 425 of file lib_table_base.h.
Referenced by FP_TREE_SYNCHRONIZING_ADAPTER::GetLibrariesCount(), DESIGN_BLOCK_LIB_TABLE::LoadGlobalTable(), FP_LIB_TABLE::LoadGlobalTable(), SYMBOL_LIB_TABLE::LoadGlobalTable(), DESIGN_BLOCK_GRID_TRICKS::paste_text(), SYMBOL_GRID_TRICKS::paste_text(), FP_GRID_TRICKS::paste_text(), and PCB::IFACE::SaveFileAs().
|
inherited |
Definition at line 202 of file lib_table_base.cpp.
References LIB_TABLE::findRow(), and LIB_TABLE_ROW::GetDescr().
Referenced by SYMBOL_TREE_MODEL_ADAPTER::AddLibraries(), SYMBOL_TREE_MODEL_ADAPTER::AddLibrary(), SAVE_AS_DIALOG::SAVE_AS_DIALOG(), and PCB_BASE_FRAME::SelectLibrary().
|
inherited |
Return the full URI of the library mapped to aLibNickname.
Definition at line 237 of file lib_table_base.cpp.
References LIB_TABLE::findRow(), and LIB_TABLE_ROW::GetFullURI().
Referenced by CVPCB_MAINFRAME::DisplayStatus(), SCH_EDIT_FRAME::LoadSheetFromFile(), NETLIST_EXPORTER_XML::makeLibraries(), FOOTPRINT_EDITOR_CONTROL::SaveAs(), FOOTPRINT_EDIT_FRAME::SaveFootprintAs(), and SYMBOL_EDIT_FRAME::saveLibrary().
|
staticinherited |
Definition at line 136 of file symbol_lib_table.cpp.
References g_symbolLibraryTable.
Referenced by SYMBOL_EDIT_FRAME::AddLibraryFile(), SYMBOL_EDIT_FRAME::addLibTableEntry(), DIALOG_SYMBOL_REMAP::createProjectSymbolLibTable(), SYMBOL_EDIT_FRAME::DdAddLibrary(), SCH_EDITOR_CONTROL::ExportSymbolsToLibrary(), DIALOG_SYMBOL_REMAP::getLibsNotInGlobalSymbolLibTable(), InvokeSchEditSymbolLibTable(), SCH::IFACE::loadGlobalLibTable(), SYMBOL_EDIT_FRAME::replaceLibTableEntry(), SCH_BASE_FRAME::saveSymbolLibTables(), PROJECT_SCH::SchSymbolLibTable(), SCH_BASE_FRAME::SelectSymLibTable(), SYMBOL_TREE_PANE::SYMBOL_TREE_PANE(), and DIALOG_GLOBAL_SYM_LIB_TABLE_CONFIG::TransferDataFromWindow().
|
staticinherited |
Fetch the global symbol library table file name.
Definition at line 741 of file symbol_lib_table.cpp.
References PATHS::GetUserSettingsPath(), and global_tbl_name.
Referenced by SYMBOL_EDIT_FRAME::addLibTableEntry(), SCH_EDITOR_CONTROL::ExportSymbolsToLibrary(), DIALOG_GLOBAL_SYM_LIB_TABLE_CONFIG::GetGlobalTableFileName(), InvokeSchEditSymbolLibTable(), SCH::IFACE::loadGlobalLibTable(), SYMBOL_LIB_TABLE::LoadGlobalTable(), SYMBOL_EDIT_FRAME::replaceLibTableEntry(), SCH_BASE_FRAME::saveSymbolLibTables(), and DIALOG_GLOBAL_SYM_LIB_TABLE_CONFIG::TransferDataFromWindow().
|
inherited |
Return the logical library names, all of them that are pertinent to a look up done on this LIB_TABLE.
Definition at line 314 of file lib_table_base.cpp.
References LIB_TABLE_ROW::GetIsEnabled(), LIB_TABLE_ROW::GetNickName(), LIB_TABLE::m_fallBack, and LIB_TABLE::m_rows.
Referenced by DESIGN_BLOCK_TREE_MODEL_ADAPTER::AddLibraries(), FP_TREE_MODEL_ADAPTER::AddLibraries(), CVPCB_MAINFRAME::BuildLibrariesList(), DIALOG_SYMBOL_REMAP::createProjectSymbolLibTable(), DESIGN_BLOCK_LIB_TABLE::DesignBlockLoadWithOptionalNickname(), FP_LIB_TABLE::FootprintLoadWithOptionalNickname(), DESIGN_BLOCK_LIB_TABLE::GenerateTimestamp(), FP_LIB_TABLE::GenerateTimestamp(), GetFootprintLibraries(), SYMBOL_LIBRARY_MANAGER::GetLibraryCount(), SYMBOL_LIB_TABLE::GetModifyHash(), guessNickname(), SYMBOL_VIEWER_FRAME::loadAllLibraries(), CVPCB_MAINFRAME::LoadFootprintFiles(), SYMBOL_LIB_TABLE::LoadSymbolWithOptionalNickname(), FOOTPRINT_VIEWER_FRAME::OnActivate(), DIALOG_EDIT_SYMBOLS_LIBID::onClickOrphansButton(), PANEL_SYMBOL_CHOOSER::PANEL_SYMBOL_CHOOSER(), DESIGN_BLOCK_LIST_IMPL::ReadDesignBlockFiles(), FOOTPRINT_LIST_IMPL::ReadFootprintFiles(), SYMBOL_VIEWER_FRAME::ReCreateLibList(), FOOTPRINT_VIEWER_FRAME::ReCreateLibraryList(), SAVE_AS_DIALOG::SAVE_AS_DIALOG(), PCB_BASE_FRAME::SelectLibrary(), SCH_BASE_FRAME::SelectLibraryFromList(), and FP_TREE_SYNCHRONIZING_ADAPTER::Sync().
|
inherited |
Definition at line 316 of file symbol_lib_table.cpp.
References SYMBOL_LIB_TABLE::FindRow(), LIB_TABLE::GetLogicalLibs(), SYMBOL_LIB_TABLE::m_modifyHash, and SYMBOL_LIB_TABLE_ROW::plugin.
Referenced by SCH_IO_DATABASE::cacheLib(), SYMBOL_LIBRARY_MANAGER::GetHash(), and LIB_SYMBOL_LIBRARY_MANAGER::Sync().
|
inlineoverrideinherited |
Definition at line 60 of file lib_table_grid.h.
References COL_COUNT.
|
inlineoverrideinherited |
Definition at line 58 of file lib_table_grid.h.
References LIB_TABLE_GRID::size().
Referenced by DESIGN_BLOCK_GRID_TRICKS::optionsEditor(), SYMBOL_GRID_TRICKS::optionsEditor(), FP_GRID_TRICKS::optionsEditor(), DESIGN_BLOCK_GRID_TRICKS::paste_text(), SYMBOL_GRID_TRICKS::paste_text(), and FP_GRID_TRICKS::paste_text().
|
staticinherited |
Definition at line 752 of file symbol_lib_table.cpp.
References global_tbl_name.
Referenced by SYMBOL_EDIT_FRAME::addLibTableEntry(), DIALOG_SYMBOL_REMAP::backupProject(), DIALOG_SYMBOL_REMAP::createProjectSymbolLibTable(), SCH_EDITOR_CONTROL::ExportSymbolsToLibrary(), InvokeSchEditSymbolLibTable(), SCH_IO_ALTIUM::LoadSchematicFile(), SCH_IO_CADSTAR_ARCHIVE::LoadSchematicFile(), SCH_IO_EAGLE::LoadSchematicFile(), SCH_IO_EASYEDAPRO::LoadSchematicFile(), SCH_EDIT_FRAME::LoadSheetFromFile(), DIALOG_SYMBOL_REMAP::OnRemapSymbols(), SYMBOL_EDIT_FRAME::replaceLibTableEntry(), SCH_BASE_FRAME::saveSymbolLibTables(), PROJECT_SCH::SchSymbolLibTable(), and SYMBOL_LIB_TABLE_RESCUER::WriteRescueLibrary().
|
inlineoverrideinherited |
Definition at line 62 of file lib_table_grid.h.
References LIB_TABLE_GRID::at(), COL_DESCR, COL_ENABLED, COL_NICKNAME, COL_OPTIONS, COL_TYPE, COL_URI, COL_VISIBLE, LIB_TABLE_ROW::GetDescr(), LIB_TABLE_ROW::GetFullURI(), LIB_TABLE_ROW::GetIsEnabled(), LIB_TABLE_ROW::GetIsVisible(), LIB_TABLE_ROW::GetNickName(), LIB_TABLE_ROW::GetOptions(), LIB_TABLE_ROW::GetType(), LIB_TABLE_GRID::size(), and UnescapeString().
Referenced by LIB_TABLE_GRID::IsEmptyCell(), and LIB_TABLE_GRID_TRICKS::showPopupMenu().
|
inlineoverrideinherited |
Definition at line 102 of file lib_table_grid.h.
References LIB_TABLE_GRID::at(), COL_ENABLED, COL_VISIBLE, LIB_TABLE_ROW::GetIsEnabled(), LIB_TABLE_ROW::GetIsVisible(), and LIB_TABLE_GRID::size().
Referenced by LIB_TABLE_GRID_TRICKS::showPopupMenu().
|
inlineinherited |
Returns the version number (0 if unset)
Definition at line 585 of file lib_table_base.h.
|
staticinherited |
Return the name of the environment variable used to hold the directory of locally installed "KiCad sponsored" system symbol libraries.
These can be either legacy or sweet format. The only thing special about this particular environment variable is that it is set automatically by KiCad on program start up, if it is not set already in the environment.
Definition at line 555 of file symbol_lib_table.cpp.
References ENV_VAR::GetVersionedEnvVarName().
Referenced by PANEL_SYM_LIB_TABLE::populateEnvironReadOnlyTable().
|
inherited |
Test for the existence of aNickname in the library table.
aCheckEnabled | if true will only return true for enabled libraries |
Definition at line 214 of file lib_table_base.cpp.
References LIB_TABLE::findRow().
Referenced by SYMBOL_EDIT_FRAME::addLibTableEntry(), BOARD_INSPECTION_TOOL::DiffFootprint(), EE_INSPECTION_TOOL::DiffSymbol(), CVPCB_MAINFRAME::DisplayStatus(), SCH_EDITOR_CONTROL::ExportSymbolsToLibrary(), DISPLAY_FOOTPRINTS_FRAME::GetFootprint(), CV::kiface(), SYMBOL_EDIT_FRAME::KiwayMailIn(), FOOTPRINT_EDIT_FRAME::KiwayMailIn(), SYMBOL_LIBRARY_MANAGER::LibraryExists(), SCH_IO_ALTIUM::LoadSchematicFile(), SCH_IO_CADSTAR_ARCHIVE::LoadSchematicFile(), SCH_IO_EAGLE::LoadSchematicFile(), SCH_IO_EASYEDAPRO::LoadSchematicFile(), SCH_EDIT_FRAME::LoadSheetFromFile(), NETLIST_EXPORTER_XML::makeLibraries(), PCM_DESIGN_BLOCK_LIB_TRAVERSER::OnDir(), PCM_FP_LIB_TRAVERSER::OnDir(), PCM_SYM_LIB_TRAVERSER::OnFile(), PANEL_SYMBOL_CHOOSER::PANEL_SYMBOL_CHOOSER(), DRC_TEST_PROVIDER_LIBRARY_PARITY::Run(), SYMBOL_EDIT_FRAME::saveLibrary(), SYMBOL_TREE_SYNCHRONIZING_ADAPTER::Sync(), FP_TREE_SYNCHRONIZING_ADAPTER::Sync(), ERC_TESTER::TestLibSymbolIssues(), and SCH_SCREEN::UpdateSymbolLinks().
|
inherited |
Test for the existence of aPath in the library table.
aCheckEnabled | if true will only return true for enabled libraries |
Definition at line 225 of file lib_table_base.cpp.
References LIB_TABLE::m_rows.
Referenced by PCM_DESIGN_BLOCK_LIB_TRAVERSER::OnDir(), PCM_FP_LIB_TRAVERSER::OnDir(), and PCM_SYM_LIB_TRAVERSER::OnFile().
|
inlineoverrideprotectedvirtual |
Implements LIB_TABLE_GRID.
Definition at line 104 of file panel_sym_lib_table.cpp.
References LIB_TABLE::m_rows.
|
inherited |
Adds aRow if it does not already exist or if doReplace is true.
If doReplace is not true and the key for aRow already exists, the function fails and returns false.
The key for the table is the nickName, and all in this table must be unique.
aRow | is the new row to insert, or to forcibly add if doReplace is true. |
doReplace | if true, means insert regardless of whether aRow's key already exists. If false, then fail if the key already exists. |
Definition at line 350 of file lib_table_base.cpp.
References LIB_TABLE::doInsertRow(), LIB_TABLE::m_mutex, and LIB_TABLE::reindex().
Referenced by SCH_EDIT_FRAME::AddDesignBlockLibrary(), SYMBOL_LIBRARY_MANAGER::addLibrary(), PCB_BASE_EDIT_FRAME::AddLibrary(), SYMBOL_EDIT_FRAME::addLibTableEntry(), DIALOG_SYMBOL_REMAP::createProjectSymbolLibTable(), SCH_IO_ALTIUM::LoadSchematicFile(), SCH_IO_CADSTAR_ARCHIVE::LoadSchematicFile(), SCH_IO_EAGLE::LoadSchematicFile(), SCH_IO_EASYEDAPRO::LoadSchematicFile(), SCH_EDIT_FRAME::LoadSheetFromFile(), PCM_DESIGN_BLOCK_LIB_TRAVERSER::OnDir(), PCM_FP_LIB_TRAVERSER::OnDir(), PCM_SYM_LIB_TRAVERSER::OnFile(), PCB_EDIT_FRAME::OpenProjectFiles(), and SYMBOL_LIB_TABLE_RESCUER::WriteRescueLibrary().
|
inlineoverrideinherited |
Definition at line 144 of file lib_table_grid.h.
References LIB_TABLE_GRID::begin(), LIB_TABLE_GRID::insert(), LIB_TABLE_GRID::makeNewRow(), and LIB_TABLE_GRID::size().
|
inherited |
Return true if the table is empty.
aIncludeFallback | is used to determine if the fallback table should be included in the test. |
Definition at line 193 of file lib_table_base.cpp.
References LIB_TABLE::IsEmpty(), LIB_TABLE::m_fallBack, and LIB_TABLE::m_rows.
Referenced by DIALOG_SYMBOL_REMAP::createProjectSymbolLibTable(), LIB_TABLE::IsEmpty(), and SCH_EDIT_FRAME::LoadSheetFromFile().
|
inlineoverrideinherited |
Definition at line 139 of file lib_table_grid.h.
References LIB_TABLE_GRID::GetValue().
|
inherited |
Return true if the library given by aNickname was successfully loaded.
aNickname | is the library nickname in the symbol library table. |
IO_ERROR | if no library at aNickname exists. |
Definition at line 501 of file symbol_lib_table.cpp.
References SYMBOL_LIB_TABLE::FindRow(), and LIB_TABLE_ROW::GetIsLoaded().
Referenced by SYMBOL_LIBRARY_MANAGER::IsLibraryLoaded().
|
inherited |
Return true if the library given by aNickname is writable.
It is possible that some symbols libraries are read only because of where they are installed.
aNickname | is the library nickname in the symbol library table. |
IO_ERROR | if no library at aNickname exists. |
Definition at line 494 of file symbol_lib_table.cpp.
References SYMBOL_LIB_TABLE::FindRow(), LIB_TABLE_ROW::GetFullURI(), and SYMBOL_LIB_TABLE_ROW::plugin.
Referenced by SYMBOL_LIBRARY_MANAGER::IsLibraryReadOnly().
|
inherited |
Load the library table using the path defined by aFileName aFallBackTable.
aFileName | contains the full path to the s-expression file. |
IO_ERROR | if an error occurs attempting to load the footprint library table. |
Definition at line 504 of file lib_table_base.cpp.
References LIB_TABLE::clear(), LIB_TABLE::m_io, LIB_TABLE::m_mutex, LIB_TABLE::m_version, LIB_TABLE::migrate(), LIB_TABLE::Parse(), LIB_TABLE::reindex(), and LIB_TABLE::Save().
Referenced by PROJECT::DesignBlockLibs(), DESIGN_BLOCK_LIB_TABLE::LoadGlobalTable(), FP_LIB_TABLE::LoadGlobalTable(), SYMBOL_LIB_TABLE::LoadGlobalTable(), SCH_EDIT_FRAME::LoadSheetFromFile(), PROJECT::PcbFootprintLibs(), PROJECT_PCB::PcbFootprintLibs(), PCB::IFACE::SaveFileAs(), PROJECT_SCH::SchSymbolLibTable(), DIALOG_GLOBAL_DESIGN_BLOCK_LIB_TABLE_CONFIG::TransferDataFromWindow(), DIALOG_GLOBAL_SYM_LIB_TABLE_CONFIG::TransferDataFromWindow(), DIALOG_GLOBAL_FP_LIB_TABLE_CONFIG::TransferDataFromWindow(), and WriteDRCReport().
|
staticinherited |
Load the global symbol library table into aTable.
This probably should be move into the application object when KiCad is changed to a single process application. This is the least painful solution for the time being.
aTable | the SYMBOL_LIB_TABLE object to load. |
IO_ERROR | if an error occurs attempting to load the symbol library table. |
Definition at line 626 of file symbol_lib_table.cpp.
References _, SEARCH_STACK::AddPaths(), LIB_TABLE::At(), SYMBOL_LIB_TABLE::FindRow(), SETTINGS_MANAGER::GetAppSettings(), LIB_TABLE::GetCount(), LIB_TABLE_ROW::GetFullURI(), SYMBOL_LIB_TABLE::GetGlobalTableFileName(), PGM_BASE::GetLocalEnvVariables(), LIB_TABLE_ROW::GetNickName(), PGM_BASE::GetSettingsManager(), ENV_VAR::GetVersionedEnvVarValue(), global_tbl_name, LIB_TABLE::Load(), KICAD_SETTINGS::m_PcmLibAutoAdd, KICAD_SETTINGS::m_PcmLibAutoRemove, KICAD_SETTINGS::m_PcmLibPrefix, path, Pgm(), LIB_TABLE::RemoveRow(), LIB_TABLE::Save(), SystemDirsAppend(), and THROW_IO_ERROR.
Referenced by SCH::IFACE::loadGlobalLibTable(), and DIALOG_GLOBAL_SYM_LIB_TABLE_CONFIG::TransferDataFromWindow().
|
inlineinherited |
Definition at line 211 of file symbol_lib_table.h.
References LIB_ID::GetLibItemName(), LIB_ID::GetLibNickname(), and SYMBOL_LIB_TABLE::LoadSymbol().
|
inherited |
Load a LIB_SYMBOL having aName from the library given by aNickname.
aNickname | is a locator for the "library", it is a "name" in LIB_TABLE_ROW |
aName | is the name of the LIB_SYMBOL to load. |
aFlatten | set to true to flatten derived parts. |
IO_ERROR | if the library cannot be found or read. No exception is thrown in the case where aNickname cannot be found. |
Definition at line 416 of file symbol_lib_table.cpp.
References SYMBOL_LIB_TABLE::FindRow(), LIB_TABLE_ROW::GetFullURI(), LIB_SYMBOL::GetLibId(), LIB_TABLE_ROW::GetMutex(), LIB_TABLE_ROW::GetNickName(), LIB_TABLE_ROW::GetProperties(), SYMBOL_LIB_TABLE_ROW::plugin, LIB_SYMBOL::SetLibId(), and LIB_ID::SetLibNickname().
Referenced by EE_INSPECTION_TOOL::DiffSymbol(), SYMBOL_PREVIEW_WIDGET::DisplaySymbol(), FOOTPRINT_INFO_GENERATOR::GenerateHtml(), SYMBOL_LIBRARY_MANAGER::GetAlias(), SYMBOL_LIBRARY_MANAGER::GetBufferedSymbol(), SYMBOL_LIBRARY_MANAGER::getOriginalSymbols(), SYMBOL_VIEWER_FRAME::GetSelectedSymbol(), SCH_IO_EAGLE::loadInstance(), SYMBOL_LIB_TABLE::LoadSymbol(), SYMBOL_EDIT_FRAME::LoadSymbol(), SYMBOL_EDIT_FRAME::LoadSymbolFromCurrentLib(), SCH_IO_HTTP_LIB::loadSymbolFromPart(), SCH_IO_DATABASE::loadSymbolFromRow(), SYMBOL_LIB_TABLE::LoadSymbolWithOptionalNickname(), PANEL_SYMBOL_CHOOSER::populateFootprintSelector(), SchGetLibSymbol(), PANEL_SYMBOL_CHOOSER::showFootprintFor(), SYMBOL_LIBRARY_MANAGER::SymbolExists(), DIALOG_EDIT_SYMBOLS_LIBID::TransferDataFromWindow(), and SCH_SCREEN::UpdateSymbolLinks().
|
inherited |
Definition at line 379 of file symbol_lib_table.cpp.
References SYMBOL_LIB_TABLE::FindRow(), LIB_TABLE_ROW::GetFullURI(), LIB_TABLE_ROW::GetMutex(), LIB_TABLE_ROW::GetNickName(), LIB_TABLE_ROW::GetOptions(), LIB_TABLE_ROW::GetProperties(), SYMBOL_LIB_TABLE_ROW::plugin, SYMBOL_LIB_TABLE::PropPowerSymsOnly, LIB_ID::SetLibNickname(), LIB_TABLE_ROW::SetLoaded(), and LIB_TABLE_ROW::SetOptions().
Referenced by SYMBOL_TREE_MODEL_ADAPTER::AddLibrary(), SYMBOL_LIBRARY_MANAGER::GetAliases(), SYMBOL_LIB_TABLE_RESCUER::OpenRescueLibrary(), SYMBOL_VIEWER_FRAME::ReCreateSymbolList(), and SYMBOL_ASYNC_LOADER::worker().
|
inherited |
Load a LIB_SYMBOL having aFootprintId with possibly an empty library nickname.
aId | the library nickname and name of the symbol to load. |
IO_ERROR | if the library cannot be found or read. No exception is thrown in the case where aId cannot be found. |
PARSE_ERROR | if aId is not parsed OK. |
Definition at line 525 of file symbol_lib_table.cpp.
References LIB_ID::GetLibItemName(), LIB_ID::GetLibNickname(), LIB_TABLE::GetLogicalLibs(), SYMBOL_LIB_TABLE::LoadSymbol(), and name.
|
inlineoverrideprotectedvirtual |
Implements LIB_TABLE_GRID.
Definition at line 97 of file panel_sym_lib_table.cpp.
|
protectedinherited |
Updates the env vars from older version of KiCad, provided they do not currently resolve to anything.
Definition at line 479 of file lib_table_base.cpp.
References LIB_TABLE::m_rows.
Referenced by LIB_TABLE::Load().
|
inlineinherited |
Definition at line 420 of file lib_table_base.h.
|
inlineinherited |
Definition at line 330 of file symbol_lib_table.h.
|
inlineinherited |
Compares this table against another.
This compares the row contents against each other. Any fallback tables are not checked.
Definition at line 404 of file lib_table_base.h.
References LIB_TABLE::m_rows.
|
inherited |
Compares this table against another.
This compares the row contents against each other.
Definition at line 721 of file symbol_lib_table.cpp.
References LIB_TABLE::m_rows.
|
overridevirtualinherited |
Parse the #LIB_TABLE_LEXER s-expression library table format into the appropriate LIB_TABLE_ROW objects.
aLexer | is the lexer to parse. |
IO_ERROR | if an I/O error occurs during parsing. |
PARSER_ERROR | if the lexer format to parse is invalid. |
boost::bad_pointer | if an any attempt to add an invalid pointer to the boost::ptr_vector. |
boost::bad_index | if an index outside the row table bounds is accessed. |
Implements LIB_TABLE.
Definition at line 142 of file symbol_lib_table.cpp.
References _, LIB_TABLE::doInsertRow(), LIB_TABLE::m_version, and THROW_IO_ERROR.
Referenced by SYMBOL_GRID_TRICKS::paste_text().
|
staticinherited |
Parses aOptionsList and places the result into a #PROPERTIES object which is returned.
If the options field is empty, then the returned PROPERTIES will be a NULL pointer.
Typically aOptionsList comes from the "options" field within a LIB_TABLE_ROW and the format is simply a comma separated list of name value pairs. e.g.: [name1[=value1][|name2[=value2]]] etc. When using the UI to create or edit a library table, this formatting is handled for you.
Definition at line 541 of file lib_table_base.cpp.
Referenced by PANEL_SYM_LIB_TABLE::onConvertLegacyLibraries(), PANEL_DESIGN_BLOCK_LIB_TABLE::onMigrateLibraries(), PANEL_FP_LIB_TABLE::onMigrateLibraries(), LIB_TABLE_ROW::SetOptions(), and DIALOG_PLUGIN_OPTIONS::TransferDataToWindow().
|
inlineoverridevirtualinherited |
Implements PROJECT::_ELEM.
Definition at line 149 of file symbol_lib_table.h.
References PROJECT::SYMBOL_LIB_TABLE.
Referenced by PROJECT_SCH::SchSymbolLibTable().
|
inlineoverrideprotectedvirtual |
Implements LIB_TABLE_GRID.
Definition at line 109 of file panel_sym_lib_table.cpp.
References LIB_TABLE::m_rows.
|
protectedinherited |
Definition at line 467 of file lib_table_base.cpp.
References LIB_TABLE::m_rows, and LIB_TABLE::m_rowsMap.
Referenced by LIB_TABLE::ChangeRowOrder(), LIB_TABLE::doInsertRow(), LIB_TABLE::InsertRow(), LIB_TABLE::Load(), LIB_TABLE::RemoveRow(), LIB_TABLE::ReplaceRow(), and LIB_TABLE::TransferRows().
|
inherited |
Removes a row from the table and frees the pointer.
aRow | is the row to remove |
Definition at line 383 of file lib_table_base.cpp.
References LIB_TABLE_ROW::GetNickName(), LIB_TABLE::m_mutex, LIB_TABLE::m_rows, LIB_TABLE::m_rowsMap, and LIB_TABLE::reindex().
Referenced by SYMBOL_LIBRARY_MANAGER::addLibrary(), DESIGN_BLOCK_LIB_TABLE::LoadGlobalTable(), FP_LIB_TABLE::LoadGlobalTable(), and SYMBOL_LIB_TABLE::LoadGlobalTable().
|
inherited |
Replaces the Nth row with the given new row.
Definition at line 420 of file lib_table_base.cpp.
References LIB_TABLE::m_mutex, LIB_TABLE::m_rows, LIB_TABLE::m_rowsMap, and LIB_TABLE::reindex().
Referenced by SYMBOL_GRID_TRICKS::paste_text().
|
inherited |
Write this library table to aFileName in s-expression form.
aFileName | is the name of the file to write to. |
Definition at line 526 of file lib_table_base.cpp.
References _, LIB_TABLE::Format(), LIB_TABLE::m_io, LIB_TABLE::m_version, and THROW_IO_ERROR.
Referenced by SCH_EDIT_FRAME::AddDesignBlockLibrary(), PCB_BASE_EDIT_FRAME::AddLibrary(), SYMBOL_EDIT_FRAME::addLibTableEntry(), SCH_EDITOR_CONTROL::ExportSymbolsToLibrary(), InvokeEditDesignBlockLibTable(), InvokePcbLibTableEditor(), InvokeSchEditSymbolLibTable(), LIB_TABLE::Load(), SCH::IFACE::loadGlobalDesignBlockLibTable(), DESIGN_BLOCK_LIB_TABLE::LoadGlobalTable(), FP_LIB_TABLE::LoadGlobalTable(), SYMBOL_LIB_TABLE::LoadGlobalTable(), SCH_EDIT_FRAME::LoadSheetFromFile(), PCB_EDIT_FRAME::OpenProjectFiles(), SYMBOL_EDIT_FRAME::replaceLibTableEntry(), PCB::IFACE::SaveFileAs(), SCH_BASE_FRAME::saveSymbolLibTables(), DIALOG_GLOBAL_DESIGN_BLOCK_LIB_TABLE_CONFIG::TransferDataFromWindow(), DIALOG_GLOBAL_SYM_LIB_TABLE_CONFIG::TransferDataFromWindow(), DIALOG_GLOBAL_FP_LIB_TABLE_CONFIG::TransferDataFromWindow(), and SYMBOL_LIB_TABLE_RESCUER::WriteRescueLibrary().
|
inherited |
Write aSymbol to an existing library given by aNickname.
If a LIB_SYMBOL by the same name already exists or there are any conflicting alias names, the new LIB_SYMBOL will silently overwrite any existing aliases and/or part because libraries cannot have duplicate alias names. It is the responsibility of the caller to check the library for conflicts before saving.
aNickname | is a locator for the "library", it is a "name" in LIB_TABLE_ROW |
aSymbol | is what to store in the library. The library owns the symbol after this call. |
aOverwrite | when true means overwrite any existing symbol by the same name, else if false means skip the write and return SAVE_SKIPPED. |
IO_ERROR | if there is a problem saving the symbol. |
Definition at line 450 of file symbol_lib_table.cpp.
References SYMBOL_LIB_TABLE::FindRow(), LIB_TABLE_ROW::GetFullURI(), LIB_SYMBOL::GetLibId(), LIB_ID::GetLibItemName(), LIB_TABLE_ROW::GetProperties(), name, SYMBOL_LIB_TABLE_ROW::plugin, SYMBOL_LIB_TABLE::SAVE_OK, and SYMBOL_LIB_TABLE::SAVE_SKIPPED.
|
inlineoverride |
Definition at line 117 of file panel_sym_lib_table.cpp.
References at(), COL_TYPE, COL_URI, LIB_TABLE_ROW::GetFullURI(), SCH_IO_MGR::GuessPluginTypeFromLibPath(), SetValue(), LIB_TABLE_GRID::SetValue(), SCH_IO_MGR::ShowType(), and size().
Referenced by SetValue().
|
inlineoverrideinherited |
Definition at line 131 of file lib_table_grid.h.
References LIB_TABLE_GRID::at(), COL_ENABLED, COL_VISIBLE, LIB_TABLE_ROW::SetEnabled(), LIB_TABLE_ROW::SetVisible(), and LIB_TABLE_GRID::size().
Referenced by LIB_TABLE_GRID_TRICKS::doPopupSelection().
|
inlineoverrideprotectedvirtual |
Implements LIB_TABLE_GRID.
Definition at line 95 of file panel_sym_lib_table.cpp.
References LIB_TABLE::m_rows.
Referenced by SetValue().
|
inherited |
Takes ownership of another list of rows; the original list will be freed.
Definition at line 456 of file lib_table_base.cpp.
References LIB_TABLE::clear(), LIB_TABLE::m_mutex, LIB_TABLE::m_rows, and LIB_TABLE::reindex().
Referenced by PANEL_DESIGN_BLOCK_LIB_TABLE::TransferDataFromWindow(), PANEL_SYM_LIB_TABLE::TransferDataFromWindow(), and PANEL_FP_LIB_TABLE::TransferDataFromWindow().
|
friend |
Definition at line 89 of file panel_sym_lib_table.cpp.
|
friend |
Definition at line 90 of file panel_sym_lib_table.cpp.
|
protectedinherited |
Definition at line 628 of file lib_table_base.h.
Referenced by LIB_TABLE::findRow(), LIB_TABLE::FindRowByURI(), LIB_TABLE::GetLogicalLibs(), and LIB_TABLE::IsEmpty().
|
protectedinherited |
Definition at line 626 of file lib_table_base.h.
Referenced by LIB_TABLE::FindRowByURI(), LIB_TABLE::LIB_TABLE(), LIB_TABLE::Load(), and LIB_TABLE::Save().
|
staticprivateinherited |
helper for GetModifyHash()
Definition at line 337 of file symbol_lib_table.h.
Referenced by SYMBOL_LIB_TABLE::GetModifyHash().
|
mutableprotectedinherited |
Mutex to protect access to the rows vector.
Definition at line 642 of file lib_table_base.h.
Referenced by LIB_TABLE::ChangeRowOrder(), LIB_TABLE::findRow(), LIB_TABLE::InsertRow(), LIB_TABLE::Load(), LIB_TABLE::RemoveRow(), LIB_TABLE::ReplaceRow(), and LIB_TABLE::TransferRows().
|
protectedinherited |
Owning set of rows.
Definition at line 636 of file lib_table_base.h.
Referenced by DESIGN_BLOCK_LIB_TABLE_GRID::at(), at(), FP_LIB_TABLE_GRID::at(), DESIGN_BLOCK_LIB_TABLE_GRID::begin(), begin(), FP_LIB_TABLE_GRID::begin(), LIB_TABLE::ChangeRowOrder(), LIB_TABLE::clear(), DESIGN_BLOCK_LIB_TABLE_GRID::DESIGN_BLOCK_LIB_TABLE_GRID(), LIB_TABLE::doInsertRow(), DESIGN_BLOCK_LIB_TABLE_GRID::erase(), erase(), FP_LIB_TABLE_GRID::erase(), LIB_TABLE::FindRowByURI(), SYMBOL_LIB_TABLE::Format(), DESIGN_BLOCK_LIB_TABLE::Format(), FP_LIB_TABLE::Format(), FP_LIB_TABLE_GRID::FP_LIB_TABLE_GRID(), LIB_TABLE::GetLogicalLibs(), LIB_TABLE::HasLibraryWithPath(), DESIGN_BLOCK_LIB_TABLE_GRID::insert(), insert(), FP_LIB_TABLE_GRID::insert(), LIB_TABLE::IsEmpty(), LIB_TABLE::migrate(), PANEL_DESIGN_BLOCK_LIB_TABLE::moveDownHandler(), PANEL_SYM_LIB_TABLE::moveDownHandler(), PANEL_FP_LIB_TABLE::moveDownHandler(), PANEL_DESIGN_BLOCK_LIB_TABLE::moveUpHandler(), PANEL_FP_LIB_TABLE::moveUpHandler(), DESIGN_BLOCK_LIB_TABLE::operator==(), FP_LIB_TABLE::operator==(), LIB_TABLE::operator==(), SYMBOL_LIB_TABLE::operator==(), DESIGN_BLOCK_GRID_TRICKS::paste_text(), FP_GRID_TRICKS::paste_text(), DESIGN_BLOCK_LIB_TABLE_GRID::push_back(), push_back(), FP_LIB_TABLE_GRID::push_back(), LIB_TABLE::reindex(), LIB_TABLE::RemoveRow(), LIB_TABLE::ReplaceRow(), DESIGN_BLOCK_LIB_TABLE_GRID::size(), size(), FP_LIB_TABLE_GRID::size(), SYMBOL_LIB_TABLE_GRID(), and LIB_TABLE::TransferRows().
|
protectedinherited |
this is a non-owning index into the LIB_TABLE_ROWS table
Definition at line 639 of file lib_table_base.h.
Referenced by LIB_TABLE::clear(), LIB_TABLE::doInsertRow(), LIB_TABLE::findRow(), LIB_TABLE::reindex(), LIB_TABLE::RemoveRow(), and LIB_TABLE::ReplaceRow().
|
mutableprotectedinherited |
Versioning to handle importing old tables.
Definition at line 631 of file lib_table_base.h.
Referenced by SYMBOL_LIB_TABLE::Format(), DESIGN_BLOCK_LIB_TABLE::Format(), FP_LIB_TABLE::Format(), LIB_TABLE::Load(), SYMBOL_LIB_TABLE::Parse(), DESIGN_BLOCK_LIB_TABLE::Parse(), FP_LIB_TABLE::Parse(), and LIB_TABLE::Save().
|
staticinherited |
Definition at line 152 of file symbol_lib_table.h.
|
staticinherited |
Definition at line 151 of file symbol_lib_table.h.
Referenced by SCH_IO_ALTIUM::doEnumerateSymbolLib(), SYMBOL_LIB_TABLE::EnumerateSymbolLib(), SCH_IO_DATABASE::EnumerateSymbolLib(), SCH_IO_HTTP_LIB::EnumerateSymbolLib(), SCH_IO_KICAD_LEGACY::EnumerateSymbolLib(), SCH_IO_KICAD_SEXPR::EnumerateSymbolLib(), and SYMBOL_LIB_TABLE::LoadSymbolLib().