39#include <wx/filedlg.h>
49#include <lib_table_lexer.h>
102 return m_rows.insert( aIterator, aRow );
109 return m_rows.erase( aFirst, aLast );
119 void SetValue(
int aRow,
int aCol,
const wxString &aValue )
override
121 wxCHECK( aRow < (
int)
size(), );
152 std::function<
void( wxCommandEvent& )> aAddHandler ) :
168 wxString
result = options;
169 std::map<std::string, UTF8> choices;
173 pi->GetLibraryOptions( &choices );
191 size_t ndx = cb_text.find(
"(fp_lib_table" );
193 if( ndx != std::string::npos )
199 LIB_TABLE_LEXER lexer( &slr );
205 tmp_tbl.
Parse( &lexer );
219 for(
unsigned i = 0; i < tmp_tbl.
GetCount(); ++i )
223 m_grid->AutoSizeColumns(
false );
227 wxString
text = cb_text;
229 if( !
text.Contains(
'\t' ) &&
text.Contains(
',' ) )
230 text.Replace(
',',
'\t' );
232 if(
text.Contains(
'\t' ) )
234 int row =
m_grid->GetGridCursorRow();
237 m_grid->SetGridCursor( row, 0 );
243 m_grid->AutoSizeColumns(
false );
248 bool toggleCell(
int aRow,
int aCol,
bool aPreserveSelection )
override
252 m_dialog->ShowInfoBarError(
_(
"Hidden footprint libraries are not yet supported." ) );
264 [&](
WX_GRID* aLocGrid,
int aCol )
266 int prevWidth = aLocGrid->GetColSize( aCol );
268 aLocGrid->AutoSizeColumn( aCol,
false );
269 aLocGrid->SetColSize( aCol, std::max( prevWidth, aLocGrid->GetColSize( aCol ) ) );
273 for(
int ii = 0; ii < aGrid->GetNumberRows(); ++ii )
274 aGrid->SetRowSize( ii, aGrid->GetDefaultRowSize() + 4 );
280 aGrid->SetSelectionMode( wxGrid::wxGridSelectRows );
282 wxGridCellAttr* attr;
284 attr =
new wxGridCellAttr;
292 auto* libTable = static_cast<FP_LIB_TABLE_GRID*>( grid->GetTable() );
293 auto* tableRow = static_cast<FP_LIB_TABLE_ROW*>( libTable->at( row ) );
294 PCB_IO_MGR::PCB_FILE_T fileType = tableRow->GetFileType();
295 const IO_BASE::IO_FILE_DESC& pluginDesc = m_supportedFpFiles.at( fileType );
297 if( pluginDesc.m_IsFile )
298 return pluginDesc.FileFilter();
300 return wxEmptyString;
304 aGrid->SetColAttr(
COL_URI, attr );
306 attr =
new wxGridCellAttr;
308 aGrid->SetColAttr(
COL_TYPE, attr );
310 attr =
new wxGridCellAttr;
311 attr->SetRenderer(
new wxGridCellBoolRenderer() );
315 attr =
new wxGridCellAttr;
316 attr->SetRenderer(
new wxGridCellBoolRenderer() );
332 if( aGrid->GetNumberRows() > 0 )
333 aGrid->SelectRow( 0 );
338 FP_LIB_TABLE* aGlobalTable,
const wxString& aGlobalTblPath,
339 FP_LIB_TABLE* aProjectTable,
const wxString& aProjectTblPath,
340 const wxString& aProjectBasePath ) :
360 if( cfg->m_LastFootprintLibDir.IsEmpty() )
411 auto joinExts = [](
const std::vector<std::string>& aExts )
414 for(
const std::string& ext : aExts )
416 if( !joined.empty() )
417 joined << wxS(
", " );
419 joined << wxS(
"*." ) << ext;
429 if( desc.m_IsFile && !desc.m_FileExtensions.empty() )
431 entryStr << wxString::Format( wxS(
" (%s)" ), joinExts( desc.m_FileExtensions ) );
433 else if( !desc.m_IsFile && !desc.m_ExtensionsInDir.empty() )
435 wxString midPart = wxString::Format(
_(
"folder with %s files" ),
436 joinExts( desc.m_ExtensionsInDir ) );
438 entryStr << wxString::Format( wxS(
" (%s)" ), midPart );
441 browseMenu->Append( type, entryStr );
497 for(
int r = 0; r < model->GetNumberRows(); )
499 wxString nick = model->GetValue( r,
COL_NICKNAME ).Trim(
false ).Trim();
500 wxString uri = model->GetValue( r,
COL_URI ).Trim(
false ).Trim();
501 unsigned illegalCh = 0;
506 msg =
_(
"A library table row nickname and path cells are empty." );
508 msg =
_(
"A library table row nickname cell is empty." );
510 msg =
_(
"A library table row path cell is empty." );
512 wxWindow* topLevelParent = wxGetTopLevelParent(
this );
514 wxMessageDialog badCellDlg( topLevelParent, msg,
_(
"Invalid Row Definition" ),
515 wxYES_NO | wxCENTER | wxICON_QUESTION | wxYES_DEFAULT );
516 badCellDlg.SetExtendedMessage(
_(
"Empty cells will result in all rows that are "
517 "invalid to be removed from the table." ) );
518 badCellDlg.SetYesNoLabels( wxMessageDialog::ButtonLabel(
_(
"Remove Invalid Cells" ) ),
519 wxMessageDialog::ButtonLabel(
_(
"Cancel Table Update" ) ) );
521 if( badCellDlg.ShowModal() == wxID_NO )
528 model->DeleteRows( r, 1 );
532 msg = wxString::Format(
_(
"Illegal character '%c' in nickname '%s'." ),
543 wxWindow* topLevelParent = wxGetTopLevelParent(
this );
545 wxMessageDialog errdlg( topLevelParent, msg,
_(
"Library Nickname Error" ) );
553 model->SetValue( r,
COL_URI, uri );
569 for(
int r1 = 0; r1 < model->GetNumberRows() - 1; ++r1 )
573 for(
int r2 = r1 + 1; r2 < model->GetNumberRows(); ++r2 )
579 msg = wxString::Format(
_(
"Multiple libraries cannot share the same nickname ('%s')." ),
590 wxWindow* topLevelParent = wxGetTopLevelParent(
this );
592 wxMessageDialog errdlg( topLevelParent, msg,
_(
"Library Nickname Error" ) );
612 [&]() -> std::pair<int, int>
635 wxArrayInt selectedRows =
m_cur_grid->GetSelectedRows();
636 wxGridCellCoordsArray cells =
m_cur_grid->GetSelectedCells();
637 wxGridCellCoordsArray blockTopLeft =
m_cur_grid->GetSelectionBlockTopLeft();
638 wxGridCellCoordsArray blockBotRight =
m_cur_grid->GetSelectionBlockBottomRight();
641 for(
unsigned ii = 0; ii < cells.GetCount(); ii++ )
642 selectedRows.Add( cells[ii].GetRow() );
645 if( !blockTopLeft.IsEmpty() && !blockBotRight.IsEmpty() )
647 for(
int i = blockTopLeft[0].GetRow(); i <= blockBotRight[0].GetRow(); ++i )
648 selectedRows.Add( i );
652 if( selectedRows.size() == 0 &&
m_cur_grid->GetGridCursorRow() >= 0 )
653 selectedRows.Add(
m_cur_grid->GetGridCursorRow() );
655 if( selectedRows.size() == 0 )
661 std::sort( selectedRows.begin(), selectedRows.end() );
670 for(
int ii = selectedRows.GetCount()-1; ii >= 0; ii-- )
672 int row = selectedRows[ii];
674 if( row != last_row )
681 if(
m_cur_grid->GetNumberRows() > 0 && curRow >= 0 )
692 boost::ptr_vector<LIB_TABLE_ROW>::auto_type move_me = tbl->
m_rows.release( tbl->
m_rows.begin() + row );
694 tbl->
m_rows.insert( tbl->
m_rows.begin() + row - 1, move_me.release() );
697 wxGridTableMessage msg( tbl, wxGRIDTABLE_NOTIFY_ROWS_INSERTED, row - 1, 0 );
698 tbl->GetView()->ProcessTableMessage( msg );
709 boost::ptr_vector<LIB_TABLE_ROW>::auto_type move_me = tbl->
m_rows.release( tbl->
m_rows.begin() + row );
711 tbl->
m_rows.insert( tbl->
m_rows.begin() + row + 1, move_me.release() );
714 wxGridTableMessage msg( tbl, wxGRIDTABLE_NOTIFY_ROWS_INSERTED, row, 0 );
715 tbl->GetView()->ProcessTableMessage( msg );
726 wxArrayInt selectedRows =
m_cur_grid->GetSelectedRows();
728 if( selectedRows.empty() &&
m_cur_grid->GetGridCursorRow() >= 0 )
729 selectedRows.push_back(
m_cur_grid->GetGridCursorRow() );
731 wxArrayInt rowsToMigrate;
736 for(
int row : selectedRows )
739 rowsToMigrate.push_back( row );
742 if( rowsToMigrate.size() <= 0 )
744 wxMessageBox( wxString::Format(
_(
"Select one or more rows containing libraries "
745 "to save as current KiCad format." ) ) );
750 if( rowsToMigrate.size() == 1 )
752 msg.Printf(
_(
"Save '%s' as current KiCad format and replace entry in table?" ),
757 msg.Printf(
_(
"Save %d libraries as current KiCad format and replace entries in table?" ),
758 (
int) rowsToMigrate.size() );
765 for(
int row : rowsToMigrate )
769 wxFileName legacyLib( resolvedPath );
771 if( !legacyLib.Exists() )
773 msg.Printf(
_(
"Library '%s' not found." ), relPath );
778 wxFileName newLib( resolvedPath );
780 newLib.SetName(
"" );
783 if( newLib.DirExists() )
785 msg.Printf(
_(
"Folder '%s' already exists. Do you want overwrite any existing footprints?" ),
786 newLib.GetFullPath() );
788 switch( wxMessageBox( msg,
_(
"Migrate Library" ), wxYES_NO|wxCANCEL|wxICON_QUESTION,
m_parent ) )
792 case wxCANCEL:
return;
807 relPath = newLib.GetFullPath();
814 msg.Printf(
_(
"Failed to save footprint library file '%s'." ), newLib.GetFullPath() );
836 if( event.GetEventType() == wxEVT_BUTTON )
848 wxLogWarning( wxT(
"File type selection event received but could not find the file type in the table" ) );
866 wxWindow* topLevelParent = wxGetTopLevelParent(
this );
870 wxFileDialog dlg( topLevelParent, title, *lastDir, wxEmptyString, fileDesc.
FileFilter(),
871 wxFD_OPEN | wxFD_FILE_MUST_EXIST | wxFD_MULTIPLE );
873 if( dlg.ShowModal() == wxID_CANCEL )
876 dlg.GetPaths( files );
877 *lastDir = dlg.GetDirectory();
881 wxDirDialog dlg( topLevelParent, title, *lastDir,
882 wxDD_DEFAULT_STYLE | wxDD_DIR_MUST_EXIST | wxDD_MULTIPLE );
884 if( dlg.ShowModal() == wxID_CANCEL )
887 dlg.GetPaths( files );
889 if( !files.IsEmpty() )
891 wxFileName first( files.front() );
892 *lastDir = first.GetPath();
901 bool addDuplicates =
false;
902 bool applyToAll =
false;
903 wxString warning =
_(
"Warning: Duplicate Nicknames" );
904 wxString msg =
_(
"A library nicknamed '%s' already exists." );
905 wxString detailedMsg =
_(
"One of the nicknames will need to be changed after "
906 "adding this library." );
908 for(
const wxString& filePath : files )
910 wxFileName fn( filePath );
920 if(
cur_model()->ContainsNickname( nickname ) )
926 wxString::Format( msg, nickname ),
927 detailedMsg,
_(
"Skip" ),
_(
"Add Anyway" ),
928 &applyToAll ) == wxID_CANCEL;
931 doAdd = addDuplicates;
936 int last_row =
m_cur_grid->GetNumberRows() - 1;
947 if(
m_pageNdx == 0 &&
path.Contains( wxT(
"${KIPRJMOD}" ) ) )
948 path = fn.GetFullPath();
954 if( !files.IsEmpty() )
956 int new_row =
m_cur_grid->GetNumberRows() - 1;
989 !
IsOK(
this, wxString::Format(
_(
"This action will reset your global library table on "
990 "disk and cannot be undone." ) ) ) )
1007 m_parent->m_GlobalTableChanged =
true;
1040 m_parent->m_GlobalTableChanged =
true;
1046 m_parent->m_ProjectTableChanged =
true;
1061 wxRegEx re(
".*?(\\$\\{(.+?)\\})|(\\$\\((.+?)\\)).*?", wxRE_ADVANCED );
1062 wxASSERT( re.IsValid() );
1064 std::set< wxString > unique;
1074 for(
int row = 0; row < tbl->GetNumberRows(); ++row )
1076 wxString uri = tbl->GetValue( row,
COL_URI );
1078 while( re.Matches( uri ) )
1080 wxString envvar = re.GetMatch( uri, 2 );
1083 if( envvar.IsEmpty() )
1084 envvar = re.GetMatch( uri, 4 );
1087 unique.insert( envvar );
1090 uri.Replace( re.GetMatch( uri, 0 ), wxEmptyString );
1104 for(
const wxString& evName : unique )
1109 m_path_subs_grid->SetCellValue( row, 0, wxT(
"${" ) + evName + wxT(
"}" ) );
1113 wxGetEnv( evName, &evValue );
1141 projectTable =
nullptr;
1144 projectTable, projectTablePath,
1154 globalTable->
Save( globalTablePath );
1158 msg.Printf(
_(
"Error saving global library table:\n\n%s" ), ioe.
What() );
1159 wxMessageBox( msg,
_(
"File Save Error" ), wxOK | wxICON_ERROR );
1167 projectTable->
Save( projectTablePath );
1171 msg.Printf(
_(
"Error saving project-specific library table:\n\n%s" ), ioe.
What() );
1172 wxMessageBox( msg,
_(
"File Save Error" ), wxOK | wxICON_ERROR );
1176 std::string payload =
"";
wxBitmapBundle KiBitmapBundle(BITMAPS aBitmap, int aMinHeight)
bool m_ProjectTableChanged
void InstallPanel(wxPanel *aPanel)
bool m_GlobalTableChanged
Class DIALOG_HTML_REPORTER.
WX_HTML_REPORT_BOX * m_Reporter
An options editor in the form of a two column name/value spreadsheet like (table) UI.
void paste_text(const wxString &cb_text) override
handle specialized clipboard text, with leading "(fp_lib_table", OR spreadsheet formatted text.
DIALOG_EDIT_LIBRARY_TABLES * m_dialog
FP_GRID_TRICKS(DIALOG_EDIT_LIBRARY_TABLES *aParent, WX_GRID *aGrid)
void optionsEditor(int aRow) override
FP_GRID_TRICKS(DIALOG_EDIT_LIBRARY_TABLES *aParent, WX_GRID *aGrid, std::function< void(wxCommandEvent &)> aAddHandler)
bool toggleCell(int aRow, int aCol, bool aPreserveSelection) override
This class builds a wxGridTableBase by wrapping an FP_LIB_TABLE object.
size_t size() const override
FP_LIB_TABLE_GRID(const FP_LIB_TABLE &aTableToEdit)
void SetValue(int aRow, int aCol, const wxString &aValue) override
LIB_TABLE_ROWS_ITER begin() override
LIB_TABLE_ROWS_ITER erase(LIB_TABLE_ROWS_ITER aFirst, LIB_TABLE_ROWS_ITER aLast) override
LIB_TABLE_ROW * makeNewRow() override
LIB_TABLE_ROW * at(size_t aIndex) override
friend class FP_GRID_TRICKS
void push_back(LIB_TABLE_ROW *aRow) override
LIB_TABLE_ROWS_ITER insert(LIB_TABLE_ROWS_ITER aIterator, LIB_TABLE_ROW *aRow) override
friend class PANEL_FP_LIB_TABLE
Hold a record identifying a library accessed by the appropriate footprint library #PLUGIN object in t...
FP_LIB_TABLE(FP_LIB_TABLE *aFallBackTable=nullptr)
Build a footprint library table by pre-pending this table fragment in front of aFallBackTable.
static const wxString GlobalPathEnvVariableName()
Return the name of the environment variable used to hold the directory of locally installed "KiCad sp...
virtual void Parse(LIB_TABLE_LEXER *aLexer) override
Parse the #LIB_TABLE_LEXER s-expression library table format into the appropriate LIB_TABLE_ROW objec...
static wxString GetGlobalTableFileName()
Editor for wxGrid cells that adds a file/folder browser to the grid input field.
Add mouse and command handling (such as cut, copy, and paste) to a WX_GRID instance.
virtual void paste_text(const wxString &cb_text)
void getSelectedArea()
Puts the selected area into a sensible rectangle of m_sel_{row,col}_{start,count} above.
WX_GRID * m_grid
I don't own the grid, but he owns me.
virtual bool toggleCell(int aRow, int aCol, bool aPreserveSelection=false)
Hold an error message and may be used when throwing exceptions containing meaningful error messages.
virtual const wxString What() const
A composite of Problem() and Where()
void SetKiway(wxWindow *aDest, KIWAY *aKiway)
It is only used for debugging, since "this" is not a wxWindow*.
A minimalistic software bus for communications between various DLLs/DSOs (DSOs) within the same KiCad...
virtual void ExpressMail(FRAME_T aDestination, MAIL_T aCommand, std::string &aPayload, wxWindow *aSource=nullptr)
Send aPayload to aDestination from aSource.
virtual PROJECT & Prj() const
Return the PROJECT associated with this KIWAY.
static unsigned FindIllegalLibraryNameChar(const UTF8 &aLibraryName)
Looks for characters that are illegal in library nicknames.
static UTF8 FixIllegalChars(const UTF8 &aLibItemName, bool aLib)
Replace illegal LIB_ID item name characters with underscores '_'.
LIB_TABLE_GRID_TRICKS(WX_GRID *aGrid)
This abstract base class mixes any object derived from LIB_TABLE into wxGridTableBase so the result c...
void SetValue(int aRow, int aCol, const wxString &aValue) override
bool AppendRows(size_t aNumRows=1) override
int GetNumberRows() override
Hold a record identifying a library accessed by the appropriate plug in object in the LIB_TABLE.
const wxString & GetOptions() const
Return the options string, which may hold a password or anything else needed to instantiate the under...
virtual const wxString GetType() const =0
Return the type of library represented by this row.
const wxString & GetNickName() const
const wxString GetFullURI(bool aSubstituted=false) const
Return the full location specifying URI for the LIB, either in original UI form or in environment var...
LIB_TABLE_ROW * clone() const
void SetOptions(const wxString &aOptions)
Change the library options strings.
static std::map< std::string, UTF8 > * ParseOptions(const std::string &aOptionsList)
Parses aOptionsList and places the result into a #PROPERTIES object which is returned.
LIB_TABLE_ROW & At(unsigned aIndex)
Get the 'n'th LIB_TABLE_ROW object.
LIB_TABLE_ROWS m_rows
Owning set of rows.
unsigned GetCount() const
Get the number of rows contained in the table.
void Save(const wxString &aFileName) const
Write this library table to aFileName in s-expression form.
STD_BITMAP_BUTTON * m_move_up_button
WX_GRID * m_path_subs_grid
STD_BITMAP_BUTTON * m_append_button
STD_BITMAP_BUTTON * m_move_down_button
STD_BITMAP_BUTTON * m_delete_button
SPLIT_BUTTON * m_browseButton
PANEL_FP_LIB_TABLE_BASE(wxWindow *parent, wxWindowID id=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(-1,-1), long style=wxTAB_TRAVERSAL, const wxString &name=wxEmptyString)
Dialog to show and edit symbol library tables.
FP_LIB_TABLE * m_globalTable
bool verifyTables()
Trim important fields, removes blank row entries, and checks for duplicates.
std::map< PCB_IO_MGR::PCB_FILE_T, IO_BASE::IO_FILE_DESC > m_supportedFpFiles
void onSizeGrid(wxSizeEvent &event) override
void moveUpHandler(wxCommandEvent &event) override
void adjustPathSubsGridColumns(int aWidth)
FP_LIB_TABLE_GRID * cur_model() const
FP_LIB_TABLE_GRID * project_model() const
void moveDownHandler(wxCommandEvent &event) override
wxArrayString m_pluginChoices
void setupGrid(WX_GRID *aGrid)
FP_LIB_TABLE_GRID * global_model() const
wxString m_lastProjectLibDir
void populateEnvironReadOnlyTable()
Populate the readonly environment variable table with names and values by examining all the full_uri ...
~PANEL_FP_LIB_TABLE() override
FP_LIB_TABLE * m_projectTable
void deleteRowHandler(wxCommandEvent &event) override
void populatePluginList()
void onReset(wxCommandEvent &event) override
void onMigrateLibraries(wxCommandEvent &event) override
void browseLibrariesHandler(wxCommandEvent &event)
bool TransferDataFromWindow() override
PANEL_FP_LIB_TABLE(DIALOG_EDIT_LIBRARY_TABLES *aParent, PROJECT *aProject, FP_LIB_TABLE *aGlobalTable, const wxString &aGlobalTblPath, FP_LIB_TABLE *aProjectTable, const wxString &aProjectTblPath, const wxString &aProjectBasePath)
wxString m_projectBasePath
DIALOG_EDIT_LIBRARY_TABLES * m_parent
void OnUpdateUI(wxUpdateUIEvent &event) override
void onPageChange(wxBookCtrlEvent &event) override
void appendRowHandler(wxCommandEvent &event) override
static wxString GetDefaultUserFootprintsPath()
Gets the default path we point users to create projects.
wxString m_LastFootprintLibDir
static PLUGIN_REGISTRY * Instance()
static PCB_IO * PluginFind(PCB_FILE_T aFileType)
Return a #PLUGIN which the caller can use to import, export, save, or load design documents.
static PCB_FILE_T EnumFromStr(const wxString &aFileType)
Return the PCB_FILE_T from the corresponding plugin type name: "kicad", "legacy", etc.
PCB_FILE_T
The set of file types that the PCB_IO_MGR knows about, and for which there has been a plugin written,...
@ KICAD_SEXP
S-expression Pcbnew file format.
static bool ConvertLibrary(std::map< std::string, UTF8 > *aOldFileProps, const wxString &aOldFilePath, const wxString &aNewFilePath, REPORTER *aReporter)
Convert a schematic symbol library to the latest KiCad format.
static PCB_FILE_T GuessPluginTypeFromLibPath(const wxString &aLibPath, int aCtl=0)
Return a plugin type given a footprint library's libPath.
static const wxString ShowType(PCB_FILE_T aFileType)
Return a brief name for a plugin given aFileType enum.
virtual ENV_VAR_MAP & GetLocalEnvVariables() const
static FP_LIB_TABLE * PcbFootprintLibs(PROJECT *aProject)
Return the table of footprint libraries without Kiway.
Container for project specific data.
virtual const wxString GetProjectPath() const
Return the full path of the project.
virtual const wxString FootprintLibTblName() const
Returns the path and filename of this project's footprint library table.
virtual bool IsNullProject() const
Check if this project is a null project (i.e.
Is a LINE_READER that reads from a multiline 8 bit wide std::string.
void Flush()
Build the HTML messages page.
bool HasMessage() const override
Returns true if any messages were reported.
const wxString ExpandEnvVarSubstitutions(const wxString &aString, const PROJECT *aProject)
Replace any environment variable & text variable references with their values.
int OKOrCancelDialog(wxWindow *aParent, const wxString &aWarning, const wxString &aMessage, const wxString &aDetailedMessage, const wxString &aOKLabel, const wxString &aCancelLabel, bool *aApplyToAll)
Display a warning dialog with aMessage and returns the user response.
bool IsOK(wxWindow *aParent, const wxString &aMessage)
Display a yes/no dialog with aMessage and returns the user response.
void DisplayErrorMessage(wxWindow *aParent, const wxString &aText, const wxString &aExtraInfo)
Display an error message with aMessage.
void DisplayError(wxWindow *aParent, const wxString &aText)
Display an error or warning message box with aMessage.
This file is part of the common library.
FP_LIB_TABLE GFootprintTable
The global footprint library table.
Declaration of the eda_3d_viewer class.
wxString NormalizePath(const wxFileName &aFilePath, const ENV_VAR_MAP *aEnvVars, const wxString &aProjectPath)
Normalize a file path to an environmental variable, if possible.
Helper functions to substitute paths with environmental variables.
Functions related to environment variables, including help functions.
static const std::string KiCadFootprintLibPathExtension
std::map< wxString, ENV_VAR_ITEM > ENV_VAR_MAP
std::unique_ptr< T > IO_RELEASER
Helper to hold and release an IO_BASE object when exceptions are thrown.
LIB_TABLE_ROWS::iterator LIB_TABLE_ROWS_ITER
This file contains miscellaneous commonly used macros and functions.
KICOMMON_API wxString GetVersionedEnvVarName(const wxString &aBaseName)
Construct a versioned environment variable based on this KiCad major version.
void InvokePcbLibTableEditor(KIWAY *aKiway, wxWindow *aCaller)
Function InvokePcbLibTableEditor shows the modal DIALOG_FP_LIB_TABLE for purposes of editing the glob...
PGM_BASE & Pgm()
The global program "get" accessor.
#define PROJECT_VAR_NAME
A variable name whose value holds the current project directory.
T * GetAppSettings(const char *aFilename)
std::vector< FAB_LAYER_COLOR > dummy
MODEL3D_FORMAT_TYPE fileType(const char *aFileName)
#define TO_UTF8(wxstring)
Convert a wxString to a UTF8 encoded C string for all wxWidgets build modes.
Container that describes file type info.
bool m_IsFile
Whether the library is a folder or a file.
wxString FileFilter() const
A filename or source description, a problem input line, a line number, a byte offset,...
wxString result
Test unit parsing edge cases and error handling.
Definition of file extensions used in Kicad.