244 Commits

Author SHA1 Message Date
Jon Evans e468788aa8 Fix up kicad-cli DRC project and library handling
Fixes https://gitlab.com/kicad/code/kicad/-/issues/23379
2026-03-09 20:42:29 -04:00
Seth Hillbrand 9c0e406e94 Fix race conditions in symbol library preloading
Two race conditions may have caused intermittent false "Library not found in
library table" errors when "remember open files" was enabled.  First,
PreloadLibraries had a gap between checking and setting the in-progress flag and
second, SYMBOL_LIBRARY_ADAPTER::AsyncLoad didn't have a mutex

Fixes https://gitlab.com/kicad/code/kicad/-/issues/22764
2026-01-19 07:55:58 -08:00
Seth Hillbrand 9b9899979b Stop showing popup for library load errors
Errors are stored to a vector for display after clicking the warning
icon in the toolbar.
2025-12-31 13:15:06 -08:00
Jeff Young ba3e35b13e Protect toolbar controls from improper contexts. 2025-12-30 13:26:20 +00:00
Seth Hillbrand 3800c82ffa Remove SetRoot()
Gets rid of the SetRoot() because we don't have roots anymore so this
was confusing.  We now use SetTopLevelSheets() to add sheets to the
virtual root.  Ensure that the hierarchy is maintained on each
transition
2025-12-22 17:41:59 -08:00
Jon Evans a9bd653253 Avoid crash when switching projects during background load 2025-12-22 11:42:36 -05:00
Jeff Young ec8547ad2c Re-enable library table saving in project Save As...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/22482
2025-12-08 20:54:07 +00:00
jean-pierre charras 548ac5d36b eeschema.cpp: fix a compil warning. pcb_painter.cpp: minor change in debug code. 2025-12-07 17:31:43 +01:00
Jeff Young 666e7f5bc5 More flexible (and correct) version of CopySexprFile(),
Fixes https://gitlab.com/kicad/code/kicad/-/issues/21738
2025-12-04 14:22:09 +00:00
Jeff Young da1a3a944e Update sheetfiles and instance projects in Save As.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/21738
2025-12-04 10:59:11 +00:00
Seth Hillbrand 2d538d3d69 ADDED: Remote symbol placement
Allows activating a display panel that shows a webpage designed to
provide instances of symbols, footprints, 3d models and spice models to
the designer.

The webpage can be installed via PCM or directly in the panel.  Webpages
should be registered with the KiCad project in order to avoid a warning
when showing content.
2025-11-29 17:58:32 -08:00
Jon Evans 2a503806fe Move library UI update notification to after job completion 2025-10-30 18:43:31 -04:00
Jon Evans 84d8b7889d Remove legacy symbol lib table code 2025-10-15 22:18:55 -04:00
Jon Evans d85fb038ba Port design blocks to new library table system
Generalize library adapter code to be shared
2025-10-15 22:18:54 -04:00
Jon Evans e1ea6a1302 Shorten class name for legibility 2025-10-15 22:18:54 -04:00
Jon Evans 5692323c7f Correctly handle loading zero libraries 2025-10-15 22:18:53 -04:00
Jon Evans f7acb98750 Remove no longer needed global load method 2025-10-15 22:18:53 -04:00
Jon Evans 266c8c8754 Refactor and consolidate startup wizard
- Add welcome page
- Add settings migration
- Add library table configuration
- Combine sentry and updates into a privacy step
- Support in single-top mode
2025-10-15 22:18:52 -04:00
Marek Roszko d2f927dd7e ADDED: Central startup wizard to prompt for initial settings 2025-10-15 22:18:52 -04:00
Jon Evans 38f21a215e Move background load of libraries to kiface 2025-10-15 22:18:52 -04:00
Seth Hillbrand 8eed37ec63 Fix missing headers 2025-10-14 16:37:49 -07:00
Seth Hillbrand ac8914e46e ADDED: Ability to create flat-type schematics
Allows multiple, top-level schematic sheets.  Records of the sheets are
stored in the project file.  All top-level sheets live under a virtual
root sheet in the hierarchy.  This virtual root is suppressed for export
and general visibility

Fixes https://gitlab.com/kicad/code/kicad/-/issues/2063
2025-10-14 16:07:44 -07:00
Jeff Young 8c3026cf1a Naming conventions. 2025-08-25 12:13:38 +01:00
Seth Hillbrand 87ccb2abc0 Move Annotation preferences (most) to schematic setup
The scope, recursion, reset options and message filters remain in the
user preferences.  Others including numbering, sort order and reuse are
schematic preferences.

Also, the oddball subunit display remains here but it doesn't really
belong in annotation.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/17942
2025-08-12 16:15:17 -07:00
Jeff Young 0464cc18b1 Progress reporting for Run Jobs.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/19629
2025-06-28 16:23:34 -06:00
Jeff Young 0a59ca7590 Can't use EndModal() to cancel a modal dialog that hasn't been shown yet (KICAD-6YE).
(This particular case happens when the user cancels
the progress dialog while loading symbols before the
symbol picker has been displayed.  3.5K people have
done this 13K times on MSW.)
2025-06-24 11:52:29 -06:00
Jeff Young 18e107529a Don't force callers of GetAppSettings to implement exception processing. 2025-06-14 20:25:59 +01:00
jean-pierre charras 5f17a7b024 Fix a compil warning. 2025-05-25 11:20:39 +02:00
Mark Roszko f3d445efc9 Prevent crash on failure to load ngspice's dll
Fixes https://gitlab.com/kicad/code/kicad/-/issues/20695


(cherry picked from commit f35078cb29)

Co-authored-by: Marek Roszko <mark.roszko@gmail.com>
2025-05-24 04:17:28 +00:00
Jeff Young f951497a4f Code brevity. 2025-03-01 21:58:31 +00:00
Ian McInerney 85810510f4 Tweak toolbar settings a bit
* Manage the settings using the settings manager for better lifetimes
* Better architect the internals and JSON to make it easier to identify
  the various tool types
2025-02-28 01:57:37 +00:00
Ian McInerney ab114c4159 Put preferences panes for toolbars, but hide behind an advanced config
There is still more work to do to make this feature actually
user-friendly and make it so people can't break their UI config too
easily.
2025-02-28 01:57:37 +00:00
Ian McInerney e53c155b8c Initial dialog work 2025-02-28 01:57:37 +00:00
Jeff Young e9ee5c2efe Comments. 2025-02-15 20:29:12 +00:00
Jon Evans 667bafc8bb Restore accidentally-removed schematic parity code from CLI
This will need a better fix later

Fixes https://gitlab.com/kicad/code/kicad/-/issues/19929
2025-02-15 12:52:59 -05:00
Jeff Young d1411e2c69 Don't report filepath messages for jobs.
(They'll just point to temp files anyway.)

Also moves schematic netlist fetching to
MAIL_SCH_GET_NETLIST.
Eeschema's generateSchematicNetlist() hasn't
worked in some time.

Also suppresses parity error counts when parity
not run due to failure to find or load schematic.

Also writes out ERC/DRC reports even when they're
set to fail the job.
2025-01-16 13:12:25 +00:00
Ian McInerney 6be3401b92 Add more global extensions and switch archiver to use them 2025-01-05 21:59:53 +00:00
Seth Hillbrand 0b2d4d4879 Revise Copyright statement to align with TLF
Recommendation is to avoid using the year nomenclature as this
information is already encoded in the git repo.  Avoids needing to
repeatly update.

Also updates AUTHORS.txt from current repo with contributor names
2025-01-01 14:12:04 -08:00
Marek Roszko 62ec7e2d6d Add the ability to capture job reporting and display it in the result window 2024-12-23 23:05:37 -05:00
Jeff Young 753d385473 Reduce dependency on dynamic_cast.
Also switches to checking __clang__ instead of __WXMAC__.
2024-12-08 21:46:54 +00:00
Mike Williams 662e890703 design blocks: create empty global lib rather than prompting 2024-11-06 13:39:38 -05:00
Wayne Stambaugh a6923b3de3 Cache full schematic sheet list sorted by sheet page number.
The sheet list is returned as a copy of the cached list rather than a
reference to prevent external code from changing the list.  While not as
performant, it eliminates the risk of the sheet list being altered in
ways that could break the schematic.  The sheet list should only be
updated by calling SCHEMATIC::RefreshHierarchy() when any appropriate
sheet changes are made.

Note to developers: there is something inherently different about how the
QA tests are loading and handling schematics versus the schematic editor.
Using the cached sheet list for the SCHEMATIC object will cause some QA
test to fail.  This is why SCHEMATIC::Hierarchy() has not replaced
SCHEMATIC::BuildSheetListSortedByPageNumbers() everywhere.
2024-10-09 09:58:50 -04:00
Marek Roszko d74caace0a Initial jobset creation and running within the CLI and GUI.
Incomplete, just pushing this before feature freeze, much fixing left
2024-09-30 20:04:53 -04:00
Mike Williams 895c977dd3 design blocks: move all loading out the main kicad frame
This lets standalone eeschema at least use the global table if a project
is not loaded, similar to how symbols/footprints work.
2024-09-10 15:50:03 -04:00
Mike Williams b2dda11fae design blocks: move table manager to common dialogs
Also add to schematic editor preferences.
2024-09-10 15:50:03 -04:00
Jeff Young edc7603d2a Make it clear that GetSheets() is heavy.
Also removes the side-effect that SCH_SHEET_LIST's
c'tor would sort the list (and write virtual page
numbers) anytime the starting sheet was the root.

Also, definitely don't build a SHEET_LIST (sorted or
otherwise) if you're not even going to use it.

Also don't build SCH_SHEET_LISTs on idle events.  Better
to just always have the Next Sheet button enabled (we
already beep if you click it and there's no next sheet).

Also, use a SCREEN_LIST when you can.  It's much cheaper
to create.
2024-06-06 18:00:59 +01:00
Marek Roszko 83ef5fd7d6 Move PGM_BASE to kicommon 2024-03-20 23:29:42 -04:00
ecorm 16de0a666c Horizontal/vertical zoom for Simulator plots
ADDED: Horizontal/vertical zoom for simulator plots, via mouse wheel,
toolbar buttons, menu commands, and hotkeys.

ADDED: Simulator preferences panel, populated with mouse wheel
and trackpad settings that control pan and zoom of simulator plots.

ADDED: Zoom In/Out Horizontally/Vertically commands that can be bound
to hotkeys.

CHANGED: Simulator plot scroll wheel gestures are no longer hard-coded
and can now be configured via the new Simulator preferences panel.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/16597

Other unreported bugs that were fixed:

- Fixed wierd, jumpy simulator plot view limiting behavior.

- Fixed Zoom In Center and Zoom Out Center commands not preserving
  the simulator plot center point.

- Fixed simulator plot nudging when exported as PNGs.

- Fixed rectangular selection zoom being able to exceed simulator plot
  view limits.

Notes:

- Provided new SIM_PREFERENCES struct to be used for future
  simulator preferences set via the simulator preferences dialog.

- Bundled pre-existing EESCHEMA_SETTINGS::SIMULATOR settings into
  EESCHEMA_SETTINGS::SIMULATOR::VIEW.

- Replaced mpWindow::EnableMouseWheelPan with more general
  SetMouseWheelActions.

- Refactored and tidied up wxMathPlot's mpWindow code involved with
  fitting, zooming, and panning.

- Consolidated long lists of duplicated member variable initializers to
  a new mpWindow private delegated constructor.

- Provided provisional Zoom In/Out Horizontally/Vertically toolbar
  icons that need improvement by a graphics designer.

- Provided gitignore entries for the Qt Creator IDE
2024-03-10 12:43:18 +00:00
Marek Roszko 6a37f99e94 Fix crash if we exit lib table setup
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16917
2024-02-11 21:05:23 -05:00
Jeff Young 7cc663ad77 Schematic parity checking for CLI DRC. 2024-02-02 23:05:37 +00:00