Commit Graph

450 Commits

Author SHA1 Message Date
Dick Hollenbeck 43ee7b1dc1 Teach cvpcb about new KIWAY based cross-probing, factor out MAIL_T into mail_type.h 2014-04-22 10:16:19 -05:00
Dick Hollenbeck 23d150e618 *) Switch kicad.exe to using KIFACE modules for all major top level windows.
Eeschema, Pcbnew, and Cvpcb all run under the same process now,
    FOR THE VERY FIRST TIME!

*)  Added KIWAY::PlayerCreate(), PlayerClose(), and PlayersClose().

*)  Factored FRAME_T into <frame_type.h> from ID_DRAWFRAME_TYPE.

*)  Found that the following command line is helpful for collecting all the *.kiface
    files into the <build>/kicad/ directory so that kicad can find them.

      $ cp `find . -name '*.kiface'` kicad/

    Maybe somebody will want to rework how the CMake files are organized so all
    the binaries can go into the same place.  See python-a-mingw-us.

*)  This might fix the problem on the Mac where child process windows were not
    coming to the front.  See ->Raise() in kicad/mainframe.cpp.

*)  You can set USE_KIFACE to 0 in kicad/mainframe.cpp to chain load child exes
    instead of using the KIFACE modules directly, i.e. revert.
2014-04-19 13:47:20 -05:00
Dick Hollenbeck ed25a1593e *) Add KIFACE_I::StartFlags() and IsSingle() so a KIFACE implementation can know
if it is running under single_top.cpp or under a project manager.

*)  Test Kiface().IsSingle() when adding menus, some operations are not permitted
    when running under a project manager and the KIWAY_PLAYER is pegged to a
    specific project.

*)  Implemented KIWAY::KiFACE() so it loads *.kiface files.  They still have to be
    in the same directory as the main *.exe launcher, so this presents some difficulty
    when the binaries are not yet installed but rather the *.kiface files are still
    in their original build directories.  For today, I simply copied _pcbnew.kiface
    to build/kicad/.

*)  Add a test case to kicad/mainframe.cpp just to get an early peek at loading
    _pcbnew.kiface under the C++ project manager.  Got that working for one
    specific invocation just for proof of concept.  Surprise, it works.
2014-04-17 21:05:40 -05:00
Dick Hollenbeck a340308dc1 improve help file finding after kiway breakage. 2014-04-14 13:49:52 -05:00
Dick Hollenbeck aa56df75bd catch some IO_ERRORs 2014-04-10 16:20:01 -05:00
Dick Hollenbeck 2249b3be12 Jettison FP_LIB_TABLE::ConvertFromLegacy() into a static function, where it
was used locally.  Then comment it out in favor of a newer strategy for
filling in nicknames in cvpcb. 

Add MODULE* FootprintLoadWithOptionalNickname( const FPID& aFootprintId )
        throw( IO_ERROR, PARSE_ERROR );
from code found elsewhere.
2014-04-09 08:33:04 -05:00
Dick Hollenbeck 289c4c2f9d More migration towards single process, extend PROJECT::Config*() in proper direction, cleanups. 2014-04-07 23:55:53 -05:00
jean-pierre charras c1804da8a2 Cmakefiles: do not create map file on Windows, because creating map file generates hundred of useless wranings.
In PATCH_COMMAND, use patch instead of bzr patch if patch or patch.exe is found (mandatory to use msys2 because bzr patch does not work when using msys2)
2014-04-03 13:55:02 +02:00
Wayne Stambaugh 603121f753 Fix OpenMP link error on MinGW. 2014-03-31 22:38:19 -04:00
Marco Serantoni 36ea1e0b0f [MacOSX] Support for kiface in bundles, workaround for some cairo issues 2014-03-22 12:35:33 +01:00
jean-pierre charras edb2b3008c Minor fixes for Windows: move resources from dso to .exe, to have the application icon in executable, and therefore shown in shortcuts.
pcb_calculator: minor coding style fix.
2014-03-22 09:28:39 +01:00
jean-pierre charras 8137358e8e CvPcb: Fix crashes when starting cvPcb (could be Windows Specific) and after closing the footprint viewer. 2014-03-21 12:50:04 +01:00
Dick Hollenbeck e454408772 simplify and fix the technique used to get the project fp-lib-table 2014-03-20 20:24:35 -05:00
Dick Hollenbeck ca969f0884 merge tip in, resolve. 2014-03-20 01:24:33 -05:00
Dick Hollenbeck 88489e4af6 * KIWAY Milestone A): Make major modules into DLL/DSOs.
!   The initial testing of this commit should be done using a Debug build so that
    all the wxASSERT()s are enabled.  Also, be sure and keep enabled the
    USE_KIWAY_DLLs option.  The tree won't likely build without it.  Turning it
    off is senseless anyways.  If you want stable code, go back to a prior version,
    the one tagged with "stable".

*   Relocate all functionality out of the wxApp derivative into more finely
    targeted purposes:
    a) DLL/DSO specific
    b) PROJECT specific
    c) EXE or process specific
    d) configuration file specific data
    e) configuration file manipulations functions.

    All of this functionality was blended into an extremely large wxApp derivative
    and that was incompatible with the desire to support multiple concurrently
    loaded DLL/DSO's ("KIFACE")s and multiple concurrently open projects.
    An amazing amount of organization come from simply sorting each bit of
    functionality into the proper box.

*   Switch to wxConfigBase from wxConfig everywhere except instantiation.
*   Add classes KIWAY, KIFACE, KIFACE_I, SEARCH_STACK, PGM_BASE, PGM_KICAD,
    PGM_SINGLE_TOP,
*   Remove "Return" prefix on many function names.
*   Remove obvious comments from CMakeLists.txt files, and from else() and endif()s.
*   Fix building boost for use in a DSO on linux.
*   Remove some of the assumptions in the CMakeLists.txt files that windows had
    to be the host platform when building windows binaries.
*   Reduce the number of wxStrings being constructed at program load time via
    static construction.
*   Pass wxConfigBase* to all SaveSettings() and LoadSettings() functions so that
    these functions are useful even when the wxConfigBase comes from another
    source, as is the case in the KICAD_MANAGER_FRAME.
*   Move the setting of the KIPRJMOD environment variable into class PROJECT,
    so that it can be moved into a project variable soon, and out of FP_LIB_TABLE.
*   Add the KIWAY_PLAYER which is associated with a particular PROJECT, and all
    its child wxFrames and wxDialogs now have a Kiway() member function which
    returns a KIWAY& that that window tree branch is in support of.  This is like
    wxWindows DNA in that child windows get this member with proper value at time
    of construction.
*   Anticipate some of the needs for milestones B) and C) and make code
    adjustments now in an effort to reduce work in those milestones.
*   No testing has been done for python scripting, since milestone C) has that
    being largely reworked and re-thought-out.
2014-03-19 19:42:08 -05:00
Maciej Suminski 4419ef42bb Merged upstream. 2014-03-06 09:42:16 +01:00
Fabrizio Tappero ccc11c8ed8 Commit patch about cvpcb, pcbnew and layout editor menu items, with 3 menu labels modified in Eeschema. 2014-02-28 18:31:00 +01:00
Marco Serantoni d39cc2d65f [MacOSX] Fixing some refresh issues when changing component on cvpcb 2014-02-27 01:57:18 +01:00
Maciej Suminski 81b610df16 Upstream merge. 2014-02-21 11:05:28 +01:00
Marco Serantoni 0d68df1d93 [MacOSX] Fix for bugs #1258081 and #1267772 2014-02-18 21:30:17 +01:00
jean-pierre charras 0c615f78a1 Add the environment variable KYSYS3DMOD to define a default path for 3D models. 2014-02-08 11:44:55 +01:00
Brian Sidebotham da0e9c5299 * Add Henner's patch (with minimal changes) to ensure CVpcb footprint view window is always brought into view, even after being hidden by another window 2014-02-07 18:36:12 +00:00
Maciej Suminski 5959e7c2ef Upstream merged. 2014-02-07 09:52:47 +01:00
Dick Hollenbeck 5d4eab87f8 Initial KIWAY (modular-kicad) work. Various tweeks. 2014-02-03 09:10:37 -06:00
Dick Hollenbeck 0ec0b63ad2 Another attempt at wxFrame::SaveSettings() standard infrastructure. 2014-02-02 14:18:10 -06:00
jean-pierre charras e8ef3c14d4 Add specific bitmaps in export IDF and export DSN menus.
Add missing calls to Show( false ) to some main frames (Kicad, eeschema, gerbview), to force config saving when closing these windows.
Code cleanup and minor coding style fixes  in footprint_wizard_frame
2014-01-29 18:01:42 +01:00
Maciej Suminski ea943ce605 Merged the netnames branch. 2014-01-28 11:59:04 +01:00
Dick Hollenbeck c389c2f6e4 Add EDA_BASE_FRAME::Show() and call SaveSettings() only from there for all derived wxFrames. Remove calls to SaveSettings() elsewhere. 2014-01-27 19:29:26 -06:00
Dick Hollenbeck 6ac1bae539 fix 2014-01-21 09:25:43 -06:00
Wayne Stambaugh 53b6c1f39a CvPcb: fix no footprints shown in list when no legacy libraries are defined in project file. 2014-01-17 15:26:27 -05:00
Maciej Suminski e2e68aea74 Upstream merge. 2014-01-06 10:29:31 +01:00
Marco Serantoni 2fc8a05aec [MacOSX] Adding better support for Retina Display (NSHighResolutionCapable) 2013-12-31 12:03:02 +01:00
Marco Serantoni e0eb666f6c [MacOSX]/All purpose - Support for static linking 2013-12-30 01:27:03 +01:00
Maciej Suminski 2027222074 Upstream merge 2013-12-19 11:15:27 +01:00
Wayne Stambaugh 9abad0063e CvPcb: reload footprint list when footprint library table is changed. (fixes lp:1261911) 2013-12-18 11:36:07 -05:00
Maciej Suminski ce1541e915 Added const modifiers where applicable (PICKED_ITEMS_LIST).
Added PICKED_ITEMS_LIST::FindItem().
2013-12-18 13:27:18 +01:00
Dick Hollenbeck 39abd88a54 remove USE_FP_LIB_TABLE code, make it the norm. Add lazy loading support to FOOTPRINT_INFO. 2013-12-12 10:01:03 -06:00
Dick Hollenbeck 92e0d7bab2 molding mercury. 2013-12-09 13:06:47 -06:00
Dick Hollenbeck d9174a110b move ${Boost_LIBRARIES} into cvpcb, pcbnew, _pcbnew and out of github, because worker threads used regardless of github 2013-12-09 12:48:42 -06:00
Dick Hollenbeck f9c92b7c78 *) Change FOOTPRINT_LIST::ReadFootprintFiles( FP_LIB_TABLE*, const wxString*)
To use multiple working threads.  This entailed adding KiCad typedefs:
*) Add typedefs for MUTEX and MUTLOCK which mask the actual choices for the project.
*) Add FOOTPRINT_LIST::DisplayErrors( wxWindow* ) which is a single strategy for
   showing aggregated load errors.  Although what's there is only scaffolding
   and needs a volunteer who knows HTML pretty well.
*) Ensure all callers of ReadFootprintFiles() use the new DisplayErrors() function.   
*) Push utf8.cpp and utf8.h into common library for open use.
2013-12-09 12:09:58 -06:00
Wayne Stambaugh 882a0bcb7d Footprint library table fixes.
* Pcbnew: catch exceptions when saving changes to footprint library table.
* Pcbnew: update footprint viewer library list if open when footprint library
  table changes.
* CvPcb: update library list when footprint library table changes.
* Minor coding policy fixes.
2013-11-11 20:05:23 -05:00
jean-pierre charras 621b92cd5e All: under mingw32+msys: fix an issue when using Cmake version >= 2.8.5 which uses by default a response file.
This response file is not expanded under mingw3 2 (mingw/gcc bug?), and the list of include paths, found in this file, is not taken in account.
Now, under mingw32+msys, when not cross-compiling, the response file is disabled.
Cvpcb, Pcbnew: fix a list of libs  which should be added only when cross-compiling:
Previously, they were always added, which creates an issue with mingw/msy/ gcc  2.8.
Now they are added only when cross-compiling (this issue was noticeable only with msys+mingw version  2.8)
2013-11-10 20:15:09 +01:00
Wayne Stambaugh 3a06962045 Set project footprint library table path environment variable before loading table. 2013-11-06 11:10:44 -05:00
Orson 1fa3ef37c3 Fix redraw issue in modedit a modview, with GAL 2013-11-01 13:56:20 +01:00
Dick Hollenbeck 0e69125217 cvpcb was not filtering on the current library when USE_FP_LIB_TABLE.
<%s> being replaced with '%s' because the former in invisible in html panels.
Cure some compiler warnings.
2013-10-31 16:30:57 -05:00
Maciej Suminski 25919e8393 Merged upstream. 2013-10-28 21:34:06 +01:00
jean-pierre charras fd1fc0f1d1 Fix typo 2013-10-26 20:17:44 +02:00
Wayne Stambaugh 55f69da613 Minor message box improvements
* Create a generic yes/no/cancel dialog from DIALOG_EXIT.
* Make DIALOG_EXIT return wxID_YES instead of wxID_OK so it is consistent
  with the standard message dialogs.
* Add missing license to confirm.h and confirm.cpp.
* Change Eeschema message dialog when loading a schematic if the current
  schematic is modified to be more consistent with the exit dialog.
* Change Pcbnew message dialog when loading a board if the current board
  is modified to be more consistent with the exit dialog.
* Remove some Eeschema block debug logging code left over from my last
  commit.
2013-10-18 09:32:22 -04:00
Maciej Suminski 68e3516075 Hides the GAL subwindow in cvpcb module view frame. 2013-10-15 15:15:29 +02:00
Dick Hollenbeck de90187eb0 *) Switch over to FP_LIB_TABLE::Footprint*() functions.
*) Set environment variable KISYSMOD before loading FP_LIB_TABLE so that
   FP_LIB_TABLE::ROW::SetFullURI() can do substitution up front.
*) De-emphasize the lib path in some of the footprint frames but keep it
   so the footprint editor can export a current library to another.
   You can even export a GITHUB library to a pretty library for local 
   installation.
*) Start the PLUGIN options editor.
*) Enhance cursor positioning in DIALOG_FP_LIB_TABLE.
2013-10-13 16:33:58 -05:00