Commit Graph

108 Commits

Author SHA1 Message Date
Seth Hillbrand 5ca23e3e5c Fix missing quote in git_libngspice 2020-06-30 05:46:11 -07:00
Andrew D'Addesio b48a6274e6 Fetch ngspice over https 2020-06-25 02:07:31 +00:00
Dimitris Tassopoulos 9b4b85bb7d Added an option to use a configurable number of cores for make
Signed-off-by: Dimitris Tassopoulos <dimtass@gmail.com>
2020-04-06 12:51:16 +00:00
Jon Evans e59a3d981e Implement a new settings framework across all of KiCad
CHANGED: Settings are now stored in versioned sub-directories
ADDED: First-run dialog for migrating settings from a previous version
CHANGED: Settings are now stored as JSON files instead of wxConfig-style INI files
CHANGED: Color settings are now all stored in a separate settings file
CHANGED: The symbol editor and footprint editor now have their own settings files
CHANGED: Color settings are no longer exposed through BOARD object
CHANGED: Page layout editor now uses Eeschema's color scheme

Settings are now managed through a central SETTINGS_MANAGER held by PGM_BASE.
Existing settings will be migrated from the wxConfig format on first run of each application.
Per-application settings are now stored in one class for each application.
2020-02-19 23:44:56 -05:00
Ian McInerney 57253b7a3c Update ngspice build script to new version 2019-12-21 23:34:38 +00:00
Ian McInerney 6186dd5c51 Update ngspice build tool script to ngspice-30 2019-07-10 09:17:34 -04:00
Ian McInerney 59b729c731 pcbnew: Fix reload of python plugins in python 3
Update the reload function call to be python3 compatible along with
simplifying the load function to unify the loading of simple and
complex plugins.

Fixes: lp:1828595
* https://bugs.launchpad.net/kicad/+bug/1828595
2019-05-28 17:14:34 -07:00
Mark 5685174808 Fix for SWIG 4.0.0 2019-05-10 13:22:28 -04:00
Seth Hillbrand b6565079ee Updating icon build paths
Icon build scripts required relative paths. Updating to account for new
depth.
2019-02-14 14:58:04 -08:00
Seth Hillbrand ad77863668 Cleanup build script locations
Some developer scripts ended up in the demonstration scripts directory
that was bundled with builds.  This moves them to the build_tools
directory and updates the associated Documentation

Fixes: lp:1815891
* https://bugs.launchpad.net/kicad/+bug/1815891
2019-02-14 14:44:55 -08:00
Thomas Pointhuber 310e3f5eb9 Add Python3 compability to scripting/build_tools/extract_docstrings.py
Fixes: lp:1815737
* https://bugs.launchpad.net/kicad/+bug/1815737
2019-02-13 09:16:43 -08:00
Thomas Pointhuber 7365cb8e52 Get Exception handling working with Python 3
The old way to get the full stacktrace was incorrect, and does not work
with Python 3:
https://stackoverflow.com/questions/3702675/how-to-print-the-full-traceback-without-halting-the-program#comment84297600_33723119
2018-10-19 09:59:06 +02:00
Thomas Pointhuber 88d04f3bcb Get Action Plugins working with Python 3, fix some unicode string errors 2018-10-19 09:59:06 +02:00
Thomas Pointhuber de7b362695 Rewrite some code to work on Python 2.7 and 3+ 2018-10-19 09:59:03 +02:00
qu1ck 72f87861bb pcbnew: Add toolbar buttons for action plugins
Allows optional toolbar buttons for action plugins.
2018-08-26 19:39:27 -07:00
Wayne Stambaugh ade3c2b129 Minor Python scripting documentation fixes.
Change the Doxyfile project name from KiCAD to KiCad.  It doesn't look
very good when we don't get the project name capitalization correct.

Clean up trailing whitespace in some of the helper scripts and Doxyfile.
2018-06-12 10:24:59 -04:00
jean-pierre charras ccce376e33 Refinements for commit 986b904
(Add comments and a minor fix)
2018-04-27 16:01:59 +02:00
jean-pierre charras 986b90424b Fix an issue in LoadPlugins(bundlepath=None) python method (Windows specific).
For some obscure (for me) reason, the path separators in bundlepath are seen as escape seq, and the path can be incorrectly handled
(when \n or \r are found in this string).
it happens only for this path, not for other paths in LoadPlugins.
For bundlepath parameter, unix separator is now used.

Fixes: lp:1766879
https://bugs.launchpad.net/kicad/+bug/1766879
2018-04-27 14:04:24 +02:00
Alessandro Gatti f1cf95b8dd scripting: Fix invalid error message syntax.
Fixes: lp:1754758
https://bugs.launchpad.net/kicad/+bug/1754758
2018-03-11 15:09:27 +01:00
jean-pierre charras b11b9b9d0d Fix forgotten change in kicadplugins.i, after changing he class name PYTHON_FOOTPRINT_WIZARDS to PYTHON_FOOTPRINT_WIZARD_LIST
This bug prevent loading Python wizards.
2018-02-04 18:27:32 +01:00
jean-pierre charras 5d8dd7c20f Loading python plugins: make subdir import more tolerant to broken python scripts,
and compatible to subdirs that contains other scripts (like .xsl scripts)
2017-06-24 10:15:51 +02:00
Jean-Samuel Reynaud e40de096bc Fix broken directory names building for python plugins 2017-06-24 07:55:27 +02:00
Jean-Samuel Reynaud 5ef3e5a15d Pcbnew: Add ACTION_PLUGINS class. It allows loading python scripts in footprint editor and run them from the Tools/External Plugins menu
This plugin mechanism is enabled only if option -DKICAD_SCRIPTING_ACTION_MENU=ON (it is off by default)
It imply -DKICAD_SCRIPTING=0N
This is currently for testing purposes only for developers, not yet for users.
2017-01-23 13:27:49 +01:00
jean-pierre charras 4f46f79cf0 dialog_footprint_wizard_list.cpp: allows updating (on request) python modules from this dialog.
This option reloads modules which are more recent than already loaded modules, and load new modules.
2017-01-09 14:44:24 +01:00
jean-pierre charras e6a8294c56 dialog_footprint_wizard_list: add button to show the trace of errors when python scripts wizards failed to load. 2017-01-07 20:43:39 +01:00
jean-pierre charras 76a82dcd3b Dialog footprint wizard selector: better dialog (displays the wizard search path list) and allows double click to select a wizard 2017-01-07 13:39:47 +01:00
jean-pierre charras 56f8e10eb4 Footprint wizards management: Now display the list of not loadable footprint wizards in footprint wizard dialog.
Not loadable wizards are Python scripts having a syntax error or are not compatible scripts due to changes in API.
2017-01-06 20:15:23 +01:00
jean-pierre charras 8e11d9b628 very minor change. 2017-01-04 09:42:32 +01:00
Oliver Walters 66ee44cb1f Footprint Wizards Update 2017-01-03 16:01:47 +01:00
Oliver 636e060c99 A few enhancements from a larger patch, not yet committed, for footprint wizards 2016-12-28 10:26:01 +01:00
Dick Hollenbeck 7311f07eaf SWIG Improvements
*) Extend SWIG support deeper into the BOARD class.
*) Move swig *.i files into a directory identified for SWIG, in preparation
   for a parallel universe involving Phoenix's SIP.
*) Move swig files which will be common to both eeschema and pcbnew into
   common/swig.
*) Sketch out a "common" python module, and plan on dovetailing that into a
   libkicad_shared.{dll,so}
*) Add common/swig/ki_exceptions.i and define a macro HANDLE_EXCEPTIONS()
   which is to be applied to any function which needs C++ to python
   exception translation.
*) Move the test for SWIG tool into top level CMakeLists.txt file for use
   in all python modules beyond pcbnew, i.e. eeschema and common.
*) Add SWIG_MODULE_pcbnew_EXTRA_DEPS which generates a better Makefile, one
   which rebuilds the swig generated *.cxx file when one of its dependencies
   change.
*) Re-architect the board.i file so that it can be split into multiple *.i
   files easily.
*) Make some KIWAY from python progress, in preparation for Modular KiCad
   phase III.
2016-09-20 11:59:43 -04:00
Wayne Stambaugh cbcb3b896b Fix incorrect string translation macros.
* Replace _T() with _() for translatable strings.

* Don't translate debug messages.

* Don't translate copyright symbol.
2016-09-03 12:10:49 -04:00
Dick Hollenbeck e24990146d Pcbnew: major swig fix.
* Switched hashtables.h over to std::undordered_map from boost version.

* Added new macros DECL_VEC_FOR_SWIG() and DECL_MAP_FOR_SWIG() in macros.h.
  These along with future DECL_HASH_FOR_SWIG() unify the declaration to swig
  and C++ so that the resultant type name is common in both languages, and
  the types AGREE.

* Fixed swigging of NETINFO_ITEM and NETINFO_LIST via magic.

* Newly exposed (python wrapped) are: D_PADS, TRACKS (was TRACK_PTRS),
  NETNAME_MAP, NETCODE_MAP, wxString (without constructor purposely, read
  comment in wx.i), MARKERS, ZONE_CONTAINERS, NETCLASSPTR, KICAD_T types.

* std::vector<SOMETHING*> tends to end up named SOMETHINGS in C++ and python.
  Having the name consistent between like types is helpful, and between
  languages.  std::map<> ends up as SOMETHING_MAP.

* NETINFO_LIST::m_netNames and NETINFO_LIST::m_netCodes are now std::map
  instead of hashtables, because swig does not yet support std::unordered_map.

* You can now get to any netclass or net info.   NETNAMES_MAP and NETCODES_MAP
  are traversable basically the same as a python dictionary using a python
  string (not wsString) as the key!  The wxString typemap converts python
  string to wxString before the lookup happens.  Iteration also works.
2016-07-18 13:23:09 -04:00
Dan Cross f5fa6a2148 Fix broken swig import script when using swig >= 3.0.10. 2016-06-20 09:32:59 -04:00
jean-pierre charras 1e7b0f83d9 Fix script fix_swig_imports.py to work with swig version 3.09 2016-06-13 19:50:29 +02:00
jean-pierre charras 6d1e904334 Code cleanup: Remove outdated decimils to/from iu defines and conversion functions (decimils are no more in use since a long time).
Remove convert_from_iu.h file, only used for one define, and containing brokenand duplicate defines. Only convert_to_biu.h is now used.
2016-06-05 13:49:25 +02:00
Strontium c3d3a7a4c8 Scripting: replace PyCrust shell with enhanced PyAlaMode shell. 2015-12-21 09:55:31 -05:00
jean-pierre charras c94a5dd46f Footprint wizard: fixes and enhancements in python scripts. 2015-10-31 12:54:48 +01:00
Bernhard Stegmaier 3f807bdc78 OSX Python scripting plugin path fixes. 2015-10-02 16:07:29 -04:00
Wayne Stambaugh 053458b81a Minor scripting improvements and code cleaning.
* Coding policy fixes in the scripting initialization code missed in my previous commit.
* Remove redundant checks for valid Python library paths in kicadplugins.i.
2015-10-01 20:15:01 -04:00
Wayne Stambaugh 8f99fc0496 Minor Python scripting fixes.
* Actually install the contents of the pcbnew/scripting/plugins directory on
  Windows and Linux
* Move the test for existence of a directory before adding it to the Python
  system library paths when loading the Python plugins.
2015-09-30 16:14:59 -04:00
jean-pierre charras 7808b2e240 Fix in KIWAY_PLAYER::ShowModal: the top level windows children of the KIWAY_PLAYER Modal frame are now enabled (previously were disabled). It fix some issues for instance with the aui toolbar when moved, and the dialog open when starting the footprint wizard frame. Perhaps explain a few other bugs.
footprint wizard frame: now shows messages from footprints python scripts. Especially usefull when a parameter is incorrect. Fix also an other issue (IO error) with some scripts which were usint the print command to output messages (now they use the nes message window.
2015-09-05 14:10:54 +02:00
jean-pierre charras 4a56ee42c5 Footprint wizard: Fix IO exception error in python scripts which happens sometimes, due to the fact these scripts printed messages to a console, but when Pcbnew is not run from a console, there is no IO channel to read these messages.
The fix is not perfect (still no IO channel to read these messages) ,  but it works better.
Also, fix erroneous comments in code, and cleanup code.
2015-09-02 15:55:36 +02:00
jean-pierre charras 204eb49ce5 Minor enhancement in python console: remove margins around the client area. simplify code. 2015-08-24 20:32:56 +02:00
jean-pierre charras 718053376d forgotten python_scripting.cpp fix. 2015-07-09 18:51:08 +02:00
jean-pierre charras 01ae08a9a9 Remove the call to wxversion.py on winbuilder, because it does not work (not found, even when exists), ans it is not useful. Avoid crashes when wxPython scripting layer is not loaded, on kicad exit, and when trying to open the py console. 2015-07-09 18:44:23 +02:00
Wayne Stambaugh c288d200fb Minor wxPython scripting improvements.
* Wrap Pgm().OnPgmExit() changes in APP_SINGLE_TOP to build conditionally
  when KICAD_SCRIPTING_WXPYTHON is enabled.
* Check the result of loading the correct wxPython version during
  initialization.
2015-06-27 15:05:26 -04:00
jean-pierre charras 4daf9039db Eeschema: Fix a very old bug relative to the tool to load power parts:
Previously, only the lib named "power" was used (and therefore power parts defined in other libs not shown).
Now, all power parts can be loaded from any library.
Also, when loading power parts from the chose component dialog or the lib viewer, libs and parts are filtered:  only power parts and libs containing power parts are listed.
Hotkeys: move a few global strings in the files where ther are actually used (and make them local.) and code cleaning.
Fix a few other minor issues.
2015-04-16 17:26:51 +02:00
jean-pierre charras 4bab8dde65 Fix some minor coverity warnings. Fix a bug in pcad2kicad plugin. Scripting: map BASE_SET. Rename some python bom scripts with better names. Fix erroneous comments and add comments 2015-03-02 09:28:49 +01:00
Mark Roszko 3c42764563 Fix snprintf usage. 2015-02-22 18:56:38 -05:00