25#include <wx/tokenzr.h>
32#include <wx/settings.h>
36wxObjectDataPtr<LIB_TREE_MODEL_ADAPTER>
40 return wxObjectDataPtr<LIB_TREE_MODEL_ADAPTER>( adapter );
80 std::vector<LIB_TREE_ITEM*> libList;
84 std::unique_ptr<FOOTPRINT_INFO>
dummy = std::make_unique<FOOTPRINT_INFO_IMPL>( aLibName, wxEmptyString );
87 auto libBounds = std::equal_range( fullListStart, fullListEnd,
dummy,
88 [](
const std::unique_ptr<FOOTPRINT_INFO>& a,
89 const std::unique_ptr<FOOTPRINT_INFO>& b )
91 return StrNumCmp( a->GetLibNickname(), b->GetLibNickname(),
false ) < 0;
94 for(
auto i = libBounds.first; i != libBounds.second; ++i )
95 libList.push_back( i->get() );
The base frame for deriving all KiCad main window classes.
Hold a record identifying a library accessed by the appropriate footprint library #PLUGIN object in t...
const FP_LIB_TABLE_ROW * FindRow(const wxString &aNickName, bool aCheckIfEnabled=false)
Return an FP_LIB_TABLE_ROW if aNickName is found in this table or in any chained fall back table frag...
FP_TREE_MODEL_ADAPTER(EDA_BASE_FRAME *aParent, LIB_TABLE *aLibs)
Constructor; takes a set of libraries to be included in the search.
wxString GenerateInfo(LIB_ID const &aLibId, int aUnit) override
static wxObjectDataPtr< LIB_TREE_MODEL_ADAPTER > Create(EDA_BASE_FRAME *aParent, LIB_TABLE *aLibs)
Factory function: create a model adapter in a reference-counting container.
void AddLibraries(EDA_BASE_FRAME *aParent)
std::vector< LIB_TREE_ITEM * > getFootprints(const wxString &aLibName)
PROJECT & Prj() const
Return a reference to the PROJECT associated with this KIWAY.
A logical library item identifier and consists of various portions much like a URI.
Manage LIB_TABLE_ROW records (rows), and can be searched based on library nickname.
std::vector< wxString > GetLogicalLibs()
Return the logical library names, all of them that are pertinent to a look up done on this LIB_TABLE.
LIB_TREE_NODE_ROOT m_tree
void DoAddLibrary(const wxString &aNodeName, const wxString &aDesc, const std::vector< LIB_TREE_ITEM * > &aItemList, bool pinned, bool presorted)
Add the given list of symbols by alias.
void AssignIntrinsicRanks(bool presorted=false)
Store intrinsic ranks on all children of this node.
virtual COMMON_SETTINGS * GetCommonSettings() const
The backing store for a PROJECT, in JSON format.
virtual PROJECT_FILE & GetProjectFile() const
Base window classes and related definitions.
Abstract pattern-matching tool and implementations.
bool contains(const _Container &__container, _Value __value)
Returns true if the container contains the given value.
PGM_BASE & Pgm()
The global Program "get" accessor.
std::vector< FAB_LAYER_COLOR > dummy
int StrNumCmp(const wxString &aString1, const wxString &aString2, bool aIgnoreCase)
Compare two strings with alphanumerical content.
std::vector< wxString > pinned_fp_libs