Commit Graph

147 Commits

Author SHA1 Message Date
Ian McInerney 6692935808 Consolidate common viewer actions across cvpcb and pcbnew frames
* Consolidate the measure tool into one tool (this gives cvpcb
  unit changing and snapping capabilities in its measure tool)
* Transition cvpcb to use actions for the sketch modes
* Replumb how magnetic items settings are stored and used
2020-05-24 11:58:33 +01:00
Ian McInerney fca7ade81f Move to the AUI version of the infobar
The sizer-based version had issues with the event processing
inside the GAL panel on Windows systems.

Fixes https://gitlab.com/kicad/code/kicad/issues/4501
2020-05-21 18:22:56 +01:00
Ian McInerney 73a1ce3e84 Move eeschema find notification to the infobar and improve the infobar widget
* Move it to a panel along with the canvas to have a better UI
* Allow the infobar to automatically close after a set time

CHANGED: The eeschema find notifications now use the infobar instead of
a popup window
2020-05-20 02:31:47 +01:00
Jon Evans f2e003147e ADDED: Enable color themes for PcbNew printing 2020-05-16 13:19:43 -04:00
Jeff Young dea05336fc Don't zoom all the way in on a new footprint.
Fixes https://gitlab.com/kicad/code/kicad/issues/2220
2020-05-11 00:19:26 +01:00
Jeff Young 3c3984a6fc Generalize default footprint fields.
Fixes https://gitlab.com/kicad/code/kicad/issues/2289
2020-05-08 23:30:33 +01:00
Jon Evans 9916f24fab Split out footprint editor color settings
Migrate COLOR_SETTINGS 0->1 to remove fpedit section
Migrate FOOTPRINT_EDITOR_SETTINGS 0->1 to use new theme if created
Remove COLOR_CONTEXT that is no longer needed
2020-05-05 21:46:00 -04:00
Jeff Young 889b6cb1b1 Clean up some commenting and rename MODULE_EDITOR_TOOLs to match filename. 2020-05-03 20:56:32 +01:00
Ian McInerney d006acecf4 More window sizing fixes
* Push all sizing operations into EDA_BASE_FRAME
* Save the unmaximized window size when maximizing
  so that we can then save it in the config if the
  window is maximized. Otherwise the config ends up
  with the maximized size saved, and weird behavior
  occurs when unmaximizing on the next opening.
2020-04-27 00:14:12 +01:00
Ian McInerney 3b67e3d0a4 Rewrite window positioning logic
Now only reposition a window if it is completely on a
disconnected display or if only one corner is on screen
and it is within a region close to the screen border.

CHANGED: Window position on startup should be preserved more
2020-04-18 00:47:38 +01:00
jean-pierre charras 74957bc7e3 Footprint editor: re-enable a internal copper layer to add/edit keep-out zones
on internal layers in footprints.

Fixes #4096
https://gitlab.com/kicad/code/kicad/issues/4096
2020-03-26 16:53:46 +01:00
jean-pierre charras 1e40753d33 FOOTPRINT_EDIT_FRAME: fix missing saving/loading a few config params. 2020-03-15 19:51:41 +01:00
Seth Hillbrand 842d680b5e Set Module Editor flag for tools
The commit takes the module edit flag when resetting the tool.  All
tools should reset this flag when we setup the Module editor.

Fixes #3973 | https://gitlab.com/kicad/code/kicad/issues/3973
2020-03-02 12:45:34 -08:00
Jeff Young 129042f8a6 Convert timestamps to UUIDs. 2020-02-20 21:29:52 +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
Jeff Young 2017389f2d Pinning for library trees in FPEditor and SymbolEditor.
Fixes https://gitlab.com/kicad/code/kicad/issues/2288
2020-02-14 00:10:40 +00:00
Ian McInerney b1240b5b1e Gracefully shutdown tools when frames are closed
If the tools are not gracefully exited, then the stack variables are
never destroyed, so variable lifetime issues can occur.

Fixes https://gitlab.com/kicad/code/kicad/issues/1753
2020-02-05 22:23:24 +00:00
Mark Roszko 11ff16be4e Switch to scoped enums 2019-12-20 14:11:39 +00:00
Ian McInerney b9d8849b28 Unify unsaved changes detection logic in all frames
Create an IsContentModified() function in each frame
that provides if the content has been modified, and
use that instead of always copying the checks.
2019-12-19 15:34:01 +00:00
Mark Roszko 686b768a3d Add shutdown blocking on Windows for pcbnew, eeschema and pleditor
ADDED: Block shutdown/logoff on Windows when contents have been modified
2019-12-19 14:11:11 +00:00
Jeff Young 102b530162 Fix library tree updating bug present at least on OSX. 2019-11-29 17:55:01 +00:00
Ian McInerney e82795ba58 Fix grid settings in pcbnew/modedit/cvpcb
* Make the grid display settings separate from the board object
* Ensure that the grid is initialized on creation in all the frames

Fixes: lp:1843169
* https://bugs.launchpad.net/kicad/+bug/1843169
2019-11-23 23:35:21 +00:00
Ian McInerney 69e20c73ad fpeditor: Fix initial grid display setting
The footprint editor didn't respect the display setting showing/hiding
the grid on startup.

Fixes: lp:1843169
* https://bugs.launchpad.net/kicad/+bug/1843169
2019-11-11 22:56:06 +00:00
Jeff Young ddf887d24a Add layer selector to Footprint Editor for consistency.
Fixes: lp:1850858
* https://bugs.launchpad.net/kicad/+bug/1850858
2019-11-05 17:22:51 +00:00
jean-pierre charras 1c2891e6d4 Fp editor: allow internal layers in footprint keep-out zones Especially: Enable one internal layer to manage keep-out areas only on internal layers Allowing one internal layer is a trick to manage these keep-out areas (visibility and selection) In fact this internal layer groups all internal layers enabled is these keep-out areas. 2019-10-29 11:24:57 +01:00
jean-pierre charras 16f4958430 Pcbnew: avoid crash when closing pcbnew if the DRC dialog is open.
Cvpcb: change from commit 9ceca583:
the root class close event that save settings is now seeing the close event.
2019-09-19 09:16:12 +02:00
Jeff Young 2553dd2942 Bail on our custom dockart provider.
It appears that it was causing some crashes, and it was never clear
that it looked better anyway.
2019-09-06 23:38:20 +01:00
Jeff Young 10c25a2290 Update frame type enum to match current class names. 2019-09-06 23:38:20 +01:00
Jeff Young 3bd38ec245 Improve zoom-to-extents for footprints with long text.
Fixes: lp:1820540
* https://bugs.launchpad.net/kicad/+bug/1820540
2019-09-05 21:02:29 +01:00
Jeff Young 6688e80131 Update description in footprint tree when it's edited.
Also implements a more useful message panel for Footprint Editor.

Fixes: lp:1842660
* https://bugs.launchpad.net/kicad/+bug/1842660
2019-09-04 17:19:25 +01:00
Jeff Young ebbb12e978 Give empty preference pages the right parent.
Fixes: lp:1841665
* https://bugs.launchpad.net/kicad/+bug/1841665
2019-08-27 21:50:52 +01:00
Jeff Young 195fbbaf23 Reduce confusion by putting all dialog pages as leaf nodes. 2019-08-19 17:46:25 +01:00
jean-pierre charras 7bfbcef942 Make some strings more easily translatable
DIALOG_BOARD_STATISTICS: fix some minor issues.
2019-08-03 09:32:10 +02:00
Jeff Young 13d61e4b2b Cleanup. 2019-07-10 01:14:21 +01:00
Jeff Young 4eaba20cd3 Real-time highlighting for Pcbnew and ModEdit delete tools. 2019-06-25 21:10:21 +01:00
Jeff Young f088d4d762 Add env-var setting to CommonSettingsChanged().
Fixes: lp:1804925
* https://bugs.launchpad.net/kicad/+bug/1804925
2019-06-25 11:34:28 +01:00
Seth Hillbrand 98124e68c7 Update exit strategy to match UI guidelines
In singletop mode, all frames show the "Quit" option in the file menu
and will quit on Ctrl-Q.  When launched from the main KiCad interface,
sub-programs show the "Close" option instead and will close with Ctrl-W.
In this mode, Ctrl-Q will instruct the main program to exit.

Fixes: lp:1779938
* https://bugs.launchpad.net/kicad/+bug/1779938
2019-06-24 21:46:42 -07:00
Jeff Young 4eab89d9ef Fix OSX button order issue in Unsaved Changes dialog.
Also changes the presentation of the string when the checkbox appears
so that the "Changes will be lost" warning isn't hidden by the turndown.
This last part may require conditional compilation as it's undocumented.

Lastly, regularizes the Unsaved Changes strings between the apps.
2019-06-17 17:01:57 +01:00
Jeff Young 909aeba3d9 Transition some more stuff from the MVC view to the controller. 2019-06-16 19:53:30 +01:00
Jeff Young 8f84c3ec4f Grid rid of GetCanvas/GetGalCanvas distinction now that there's only gal. 2019-06-13 19:58:37 +01:00
Jeff Young ce1f35a1be Cleanup some left-over vestiages of the legacy canvas architecture. 2019-06-13 15:51:32 +01:00
Jeff Young 5e49517781 Move hotkeys to ACTION architecture. 2019-06-10 23:46:00 +01:00
Jeff Young e606587ff6 Move remaining Symbol Tree ctx menu cmds to ACTIONS.
Also moves the various Player instantiators down into COMMON_TOOLS
for better sharing.
2019-06-10 23:46:00 +01:00
Jeff Young 2d40425e4d Move footprint & symbol tree context menus to tool infrastructure.
Fixes: lp:1831692
* https://bugs.launchpad.net/kicad/+bug/1831692
2019-06-05 20:16:48 +01:00
Jeff Young 1ea5b04e22 More ACTIONS work. Nearly done now. 2019-06-04 22:31:42 +01:00
Jeff Young 1ea001d497 Go back to event-loop zooming for new frames.
The immediate mode appears to have made things worse not better.
2019-06-04 13:56:54 +01:00
Jeff Young 1bf04d1722 More ACTIONs work. 2019-06-04 00:51:16 +01:00
Jeff Young 3912c7407f Move global commands to ACTIONs.
Also fixes a crash bug opening Edit Tracks and Vias dialog.
2019-06-03 21:08:30 +01:00
Jeff Young e517199794 Move ConfigurePaths and LibTable management to common ACTIONs. 2019-06-03 21:08:30 +01:00
Jeff Young da4fe27447 More ACTIONS work. 2019-06-02 21:10:56 +01:00