Commit Graph

281 Commits

Author SHA1 Message Date
afkiwers dc8a5865d5 Symbol Editor: SCH_HTTP special treatment
Added SCH_HTTP to receive special treatment, same like with database libraries!
2023-10-22 19:37:43 +00:00
Marek Roszko bee6e6be01 AddMenuLanguageList should live in EDA_BASE_FRAME, its only user 2023-10-16 19:49:52 -04:00
Wayne Stambaugh b5eee9dd7e Coverity warning fixes. 2023-10-16 17:04:14 -04:00
Alex Shvartzkop c7daf511bc Fix importing a symbol in Symbol editor. 2023-10-15 05:48:17 +03:00
Jeff Young d5d07e64c9 Use IsShownOnScreen(), not IsShown(), if you really want to know if its visible. 2023-10-14 23:51:37 +01:00
Alex Shvartzkop 60d069757a ADDED: Import vector graphics into Symbol editor (SVG, DXF). 2023-10-09 07:04:50 +03:00
Marek Roszko 8c6899b0d3 Tear out the eeschema conditional compile of PROJECT 2023-09-27 23:05:30 -04:00
Jeff Young bf493f32f5 Nullptr safety for various panels.
Also moves preference saving out to parent as different parents
save different settings.
2023-09-25 12:35:54 +01:00
Jeff Young 1fd3f4e375 Handle read-only libraries when saving symbol from canvas.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15519
2023-09-23 14:34:54 +01:00
Marek Roszko 22b733209d Fail GAL on its header leaking audit
Maybe we should rethink directly accessing GAL so much, but at least 600 files didn't need GAL leaked into them due to view_overlay.h
2023-09-18 19:52:27 -04:00
Jeff Young 849a4656c8 Check value-follows-name case in symbol Save As.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15647
2023-09-14 23:56:05 +01:00
Alex Shvartzkop ff49d5ada9 Fix ambiguous overloads on wx 3.3 2023-09-14 19:05:46 +03:00
Jeff Young 7d1dbb77c3 Update symbol editor's title bar when renaming the canvas symbol. 2023-09-12 16:52:47 +01:00
Josue Huaroto cef0f176d3
Add Unselect all in menu 2023-09-06 23:44:39 +00:00
Jeff Young c07e9c834f Validate new footprint / save as footprint info before exiting dialog.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/13923
2023-09-06 12:49:37 +01:00
Jeff Young 634524dde5 Validate new symbol / save as symbol info before exiting dialog. 2023-09-05 22:07:58 +01:00
Alex Shvartzkop e128896ba6 Schematic plugins refactoring, fixes for PCB plugins.
- Move PLUGIN_FILE_DESC to common.
- SCH_PLUGIN: rename Load -> LoadSchematicFile, Save -> SaveSchematicFile.
- Use PLUGIN_FILE_DESC and CanRead* in schematic plugins.
- Return none/unknown types from Find/GuessPluginType functions.
- Iterate over file types for file wildcards.
- Clean-up header checking in IO plugins.
- Use PCB plugin list in IO_MGR::GuessPluginTypeFromLibPath.
2023-08-31 05:08:03 +03:00
Jeff Young d7a3c35f56 Repair over-zealous application of grid origin dialog.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15537
2023-08-29 12:21:21 +01:00
Jeff Young 4fefd95e0c Move grid definitions to Prefs and grid origin to a separate dlg.
Grid origin is document-wide, while grid definitions are app-wide.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/2262
2023-08-26 13:32:24 +01:00
Wayne Stambaugh 1026596964 Allow symbols to be derived from other derived symbols.
[CHANGED] Symbols can now be derived from other derived symbols removing
          the requirement to derive from root symbols.
2023-08-24 07:59:32 -04:00
Seth Hillbrand db8e15ce88 Require wxWidgets 3.2
Removes old defines and work arounds for earlier wx versions and adds a
CMake requirement to use at least 3.2 (or the minimum matching wxPython
version)
2023-08-23 22:02:56 +00:00
Mike Williams a44dd4d88f Symbol Editor: support grid overrides 2023-08-23 10:12:21 -04:00
Ian McInerney a3a701a95e Move preferences to an action instead of a wx event 2023-08-08 00:51:22 +01:00
jean-pierre charras 1b0dea069b Symbol editor: minor fix do not allow the lib tree to be docked on bottom or top
of the editor frame: it cannot be displayed.
2023-07-31 18:30:13 +02:00
jean-pierre charras d1caadeb4f symbol editor: fix small issues:
* save visibility of the properties panel
* fix correct size of the properties panel after hide/show it.
2023-07-30 11:04:49 +02:00
Jon Evans 000fa28ffc Properties: initial infrastructure for symbol editor 2023-07-26 18:32:14 -04:00
Jeff Young 03fd9c2086 Fix refresh bug after a symbol reload from the file watcher.
Also moves EE_POINT_EDITOR to SCH_COMMIT.  (There was another refresh
bug in RollbackSymbolFromUndo() -- whose only caller was the
EE_POINT_EDITOR's old undo code).

Fixes https://gitlab.com/kicad/code/kicad/-/issues/14274
2023-07-02 10:37:50 +01:00
Ian McInerney 2fb6f19a84 Separate immediate and delayed action dispatch
Using a boolean argument just leads to a lot of trailing booleans in the
function calls and is not user friendly. Instead, introduce PostAction()
to send an action that runs after the coroutine (equivalent to passing
false or the default argument), and leave RunAction as the immediate
execution function.
2023-06-27 00:57:59 +01:00
Jon Evans d4b7144448 Properties: expose symbol attributes
Flip polarity of exclude-from-BOM and -board for symbols
to match that of footprints and match the GUI display.
2023-06-24 22:03:06 -04:00
jean-pierre charras 9447c3d455 symbol editor: fix issue after loading a symbol from a library.
Selected items become invisible.
(similar to the issue fixed by commit b622e3a3f7)
Fixes #14151
https://gitlab.com/kicad/code/kicad/issues/14151
2023-06-18 17:17:16 +02:00
Jeff Young cf4f0723f8 Select first unassigned symbol when running CvPCB.
Also cleans up some dead code, and makes more use of sharing.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/9938
2023-06-17 12:44:59 +01:00
Ian McInerney d96580c651 Properly handle improper symbols when pasting in symbol editor
Before, an improper symbol (one without the starting toekn) weren't
detected and reported to the user properly and would instead assert. Now
properly detect these and pass the error up the stack to the tool.

(Sentry issue KICAD-21J).
2023-06-12 23:14:56 +01:00
Jeff Young b7f0aae006 Nullptr safety for UI Conditions.
We don't really control when these are called, so best not to assume
we've finished initialization of the frame/screen/document/whatever.

Possible fix for KICAD-KY.
2023-06-12 12:38:50 +01:00
Jeff Young 8f1b9119bf Upgrade some symbol editor stuff to SCHEMATIC_COMMIT.
Also renames SCHEMATIC_COMMIT to SCH_COMMIT since it's not schematic-specifc.
2023-06-09 22:41:47 +01:00
Jeff Young 30cbfc794f Cross-probing from Pin Table to Symbol Editor canvas.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/8301
2023-06-07 14:37:34 +01:00
Seth Hillbrand 14f6e32c74 ADDED: Change watcher for libraries
When editing or viewing library symbols, the files are watched for
underlying changes.  If any occur, the user is either prompted to reload
(if reloading would overwrite their current edits) or the file is
silently updated to the current version on disk.

This also sets a custom assertion handler to avoid unneeded crashes when
recieving invalid SAMBA packets and turns off assertions entirely when
running in release (non-debug) mode
2023-05-31 13:46:00 -07:00
jean-pierre charras f2f014a27c Symbol editor: ensure a new derived symbol has the correct DeMorgan option displayed.
Derived symbols use the same graphics as their parent, so ensure the parent is
used to enable/disable the DeMorgan option and tool in toolbar
Fixes #13739
https://gitlab.com/kicad/code/kicad/-/issues/13739
2023-05-27 10:13:43 +02:00
Jeff Young 4a62cc6edd Separate symbol editor polyline and polygon tools.
Fixes https://gitlab.com/kicad/code/kicad/issues/14695
2023-05-07 14:58:44 +01:00
Wayne Stambaugh 51fd7ca5ed Verify parent symbol shared pointer is still valid in symbol editor. 2023-05-05 12:32:00 -04:00
Jeff Young 384f65c45e Be careful of infobar outliving symbol.
Fixes https://gitlab.com/kicad/code/kicad/issues/14680
2023-05-04 11:51:47 +01:00
Jeff Young df7d62fdd3 Added a sort-order dropdown to lib-tree filters.
Also simplifies the scoring algorithm so that it only
differentiates between exact-match, match-at-start and
any-match.  The rest of the position-based matching
stuff is gone, as is the knowledge of the name vs the
keywords vs the description.  All that is left to the
provider of the weighted search terms array.
2023-05-01 21:26:43 +01:00
Seth Hillbrand f4b43617e7 Add COMMIT structure to Schematic and Symbol editors
Provides a single-point access for modifying the schematic and symbol
elements that allows chaining updates and reverting partial changes.
Standardizes the undo hierarchy between pcb and schematic editors

As this is another layer on the existing undo/redo structure, the
initial commit does not replace all undo/redo calls currently existing.
These will be handled in a series of follow-on commits
2023-04-28 17:05:47 -07:00
Jeff Young 05185ec81a Save library when it's selected in lib tree.
Fixes https://gitlab.com/kicad/code/kicad/issues/14220
2023-04-14 17:35:37 +01:00
Jeff Young eef3492fc0 Make symbol/footprint trees sensitive to language change. 2023-04-11 23:51:58 +01:00
Jeff Young bd60f38569 Possible protection from acessing deleted window data.
(Long shot for Sentry KICAD-MM.)
2023-04-03 23:44:40 +01:00
jean-pierre charras b622e3a3f7 SYMBOL_EDIT_FRAME: fix issue after loading a symbol from schematic editor.
Selected items become invisible.
Fixes #14151
https://gitlab.com/kicad/code/kicad/issues/14151
2023-03-23 18:36:59 +01:00
jean-pierre charras d62d775115 Remove non existing OnSize event in SYMBOL_EDIT_FRAME EVENT_TABLE 2023-03-18 07:30:05 +01:00
jean-pierre charras 5bd491bd74 Avoid schematic editor frame to go on top when selecting a symbol.
It was s side effect of a CrossProbe called on a symbol selection.
This also replace commit e51594cdf5.
Fixes #14316
https://gitlab.com/kicad/code/kicad/issues/14316
2023-03-17 16:37:49 +01:00
Roberto Fernandez Bautista e8ead30baf WIP: CADSTAR Parts now shows up in library tables and is handled correctly (todo: read cadstar header) 2023-03-16 21:07:05 +01:00
Wayne Stambaugh e51594cdf5 Fix broken window Z order when editing a symbol from the schematic. 2023-03-16 15:18:41 -04:00