Commit Graph

285 Commits

Author SHA1 Message Date
Jeff Young d5d07e64c9 Use IsShownOnScreen(), not IsShown(), if you really want to know if its visible. 2023-10-14 23:51:37 +01:00
Franck Jullien c010c7b0ea eeschema: add 'Already placed' category when choosing symbol 2023-10-04 10:29:22 -04:00
Jeff Young 06446bb80e Only expand lib tree when filtering. 2023-10-02 16:24:53 +01:00
Jeff Young cf02bb171f Expose exclusion flags in search pane.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15776
2023-10-01 22:46:34 +01:00
Marek Roszko 0fc3f20e4d Fix assert from IsPower in search_handlers.cpp
Fixes KICAD-2C6
2023-10-01 09:20:19 -04:00
Jeff Young fa11e9138d ADDED support for pin and fp filtering in FOOTPRINT_CHOOSER.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/7176
2023-09-29 17:03:50 +01:00
Jeff Young b592a6634e Cleanup. 2023-09-29 00:13:13 +01:00
Jeff Young 974da4ea7c Push most of DIALOG_CHOOSE_SYMBOL down into PANEL_SYMBOL_CHOOSER.
Includes a dialog wrapper (DIALOG_SYMBOL_CHOOSER) and a frame
wrapper (SYMBOL_CHOOSER_FRAME).
2023-09-29 00:13:12 +01:00
Marek Roszko 8c6899b0d3 Tear out the eeschema conditional compile of PROJECT 2023-09-27 23:05:30 -04:00
Marek Roszko f8e33be07f Break out the boundary violating parts of gal into common through subclassing 2023-09-23 09:37:47 -04: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 e6b0a6abca ADDED: lib tree previews.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/2418
2023-09-02 23:30:22 +01:00
jean-pierre charras b3aa8a0c49 Fix a few (minor) compil warnings. 2023-08-26 09:40:09 +02:00
Alex Shvartzkop f071dd1406 Fix a search pane crash when a row isn't in the hit list.
Fixes KICAD-Q7
Fixes KICAD-1A6
2023-08-25 23:24:32 +03: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
jean-pierre charras 52697c9962 Eeschema, search_handlers: fix a typo and a missing type name for Directive labels 2023-08-13 11:30:32 +02:00
jean-pierre charras f0d18adfb2 simulator, TUNER_SLIDER: fix incorrect wxWindow parent.
The TUNER_SLIDER were displayed in the wrong wxWindow.
2023-08-12 08:28:01 +02:00
Jeff Young da86593625 ADDED: Implement sorting for search panes.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/12614
2023-08-09 18:31:33 +01:00
Jeff Young 1b080ed02f Get rid of SIM_NOTEBOOK. It's completely unnecessary. 2023-08-09 12:09:29 +01:00
Jeff Young ff044cd0cf Mostly a terminology update...
... but also makes DIALOG_SIM_COMMAND and SIMULATOR_REPORTER a bit
more simulator-agnostic.
2023-07-14 17:46:06 +01:00
Jeff Young 8f9a67063a Straighten out some really confusing terminology in simulator GUI. 2023-07-09 23:07:54 +01:00
Jon Evans 59495971ee Properties: fixes to color swatches 2023-06-29 22:53:06 -04:00
Jon Evans 3487124a4a Properties: Improve color picker UX 2023-06-28 23:54:27 -04: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 3a0f8214fa ADDED: Properties panel for schematic editor
Initial infrastructure work; follow-ons will add more
properties for schematic items.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/6351
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14105
2023-06-22 22:32:24 -04:00
Ian McInerney 480223f67c More RunAction specialization 2023-06-20 21:52:50 +01:00
Jeff Young abc0c19d64 Separate SIMULATOR_PANEL from SIMULATOR_FRAME.
This is primarily to allow wxFormBuilder to create the panel without
the dangerous hack of passing a wxWindow ID into KIWAY_PLAYER's ctor.
2023-06-15 17:39:10 +01:00
Jeff Young 5c4ca9f092 Renaming to support potential future usage of SIMULATOR_PANEL as a panel within SIMULATOR_FRAME. 2023-06-15 17:39:10 +01:00
Jeff Young 20d2568f0c Move where we fire EDA_EVT_SCHEMATIC_CHANGED again.
The location in HARD_REDRAW got called everytime we change schematic
pages, which is not what we want.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/14945
2023-06-13 16:36:05 +01:00
Jeff Young 28075e6efe Don't crash on empty selection in search list.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14931
2023-06-12 23:07:27 +01:00
Jeff Young 61493b8489 Return all results with an empty search pane filter.
Also moves the EDA_EVT_SCHEMATIC_CHANGED event so it fires after the
schematic has been loaded.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/14871
2023-06-10 23:05:57 +01:00
Jeff Young f66b9f75a3 Allow EDA_COMBINED_MATCHER use in KiCad find architecture.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/12532
2023-06-10 14:50:06 +01:00
jean-pierre charras 92018f0066 Fix minor compil warnings 2023-06-04 16:24:28 +02:00
Wayne Stambaugh bdee545841 Coverity warning fixes. 2023-06-03 07:28:17 -04:00
Mike Williams 7f250870fe schematic: fix crash in search pane when hit list is empty
std::all_of also returns true for an empty set
2023-05-29 09:50:09 -04:00
Marek Roszko 1adcb86e0b Initial schematic search pane 2023-05-14 22:41:56 -04:00
Jeff Young b41d446f58 Fix a bunch more issues with sheetpaths and allowExtraText.
A sheetpath is required to correctly resolve text variables.
Depending on currentSheet is rife with bugs.

There are many places where we do *not* want to be prepending
field names to the field values, such as netlisting,
building PDF hypertext menus, etc.

Also, Find/Replace needs to work on unresolved text, as
that's what we're going to display (and if replace nuked
your variable references you wouldn't be happy).
2023-05-05 17:23:52 +01:00
Jeff Young c9351dfd67 Drawing improvements for symbol & footprint diffs.
Moves forced-transparency setting down into VIEW_ITEM so that it can
be used to place forced-transparent objects in a different target.
This keeps EnableDepthTest() from equalizing the alpha values between
the two symbols (or two footprints).
2023-03-11 12:45:16 +00:00
Jeff Young 357427d803 Graphical diff for board vs library footprints.
Fixes https://gitlab.com/kicad/code/kicad/issues/13736
2023-03-10 17:16:40 +00:00
Jeff Young bc0d59801a Graphical diff for schematic vs library symbols.
Fixes https://gitlab.com/kicad/code/kicad/issues/13736
2023-03-09 18:04:52 +00:00
Jeff Young b6d0b65261 Naming conventions and commenting. No functional changes. 2023-03-04 00:10:01 +00:00
Jeff Young be18413a90 Fix typo.
Fixes https://gitlab.com/kicad/code/kicad/issues/14073
2023-03-03 17:05:07 +00:00
Jeff Young 5849458476 The screen for undo is the screen that *owns* the SCH_SHEET...
... not the screen the SCH_SHEET owns.

Fixes https://gitlab.com/kicad/code/kicad/issues/14099
2023-03-03 00:23:06 +00:00
Jeff Young 68fe146861 Remove most of SIM_VALUE in favour of good old wxString.
This allows us to save the user's intent, including units, formatting,
and crucially variable references.
2023-02-22 10:45:27 +00:00
Marek Roszko aacc9746e3 Yeet the last of wxSize/wxPoint to stop leaking gdicmn everywhere 2023-02-18 22:57:18 -05:00
Jeff Young 9d3a3d705d ADDED simulation measurements. 2023-02-11 21:11:07 +00:00
Jeff Young 946e0a4b98 ADDED support for e-series based tuning. 2023-02-11 21:11:07 +00:00
Jeff Young b070ecf0c7 Don't run simulation while dragging tuning slider.
It has all manner of issues with wxWidgets event processing.  The
primary one that Kicad stumbles over is that there is no kill-focus
when the mouse leaves the thumb if the sim is running, so subsequent
mouse-up events (even if in another window) generate thumb scrolls.
Another one that gets us is scroll events being generated when the
window is fronted, but this may be debugger-specific.

Fixes https://gitlab.com/kicad/code/kicad/issues/11366
2022-12-26 10:51:30 +00:00
Jeff Young 90edcc8c42 Clarity and Clang-tidy warnings. 2022-12-26 10:51:30 +00:00
Jeff Young 6f44468385 Fix more lifetime issues in simulator tuning.
Fixes https://gitlab.com/kicad/code/kicad/issues/13257
2022-12-23 22:03:24 +00:00
Jeff Young 00fe8f0f70 Minor tuner panel layout fixes. 2022-12-23 20:04:26 +00:00
Jeff Young bfd3b40672 Bug fixes for tuning.
1) Don't save SCH_ITEM pointers in long-lived structures.  Use KIIDs
   instead.

2) Use the correct sheet for the referenced item, not the current sheet.
2022-12-23 17:40:36 +00:00
Jeff Young e2f2f3518b Minor improvements to tuner panel look & feel. 2022-12-23 17:40:36 +00:00
Ian McInerney 2f8cc194c1 Initialize variables inside file dialog customizer classes 2022-12-17 23:37:24 +00:00
Ian McInerney 0bd39516c4 Cleanup eeschema save as extra control creation to match pcbnew 2022-12-17 23:37:24 +00:00
Jeff Young c7603372b5 Use consistent naming. 2022-12-12 12:54:34 +00:00
Jeff Young 69448afb47 Don't run simulation twice when the sim command is overridden.
Fixes https://gitlab.com/kicad/code/kicad/issues/12731
2022-12-07 01:34:56 +00:00
Mikolaj Wielgus 6969362813 Sim Model Editor: Don't provide library-only models as builtins 2022-11-20 22:07:39 +01:00
jean-pierre charras 7e3964e5cb Missing fix in previous commit 2022-11-12 20:01:47 +01:00
Mikolaj Wielgus d10fd7bb09 Sim: Remove tuner (log) scale choice button
We probably won't be using it for now.
2022-10-25 04:38:09 +02:00
Mikolaj Wielgus 0399d08aaa Sim: Fix potentiometers 2022-10-24 11:04:47 +02:00
Mikolaj Wielgus 9b6cc6c505 Sim: Fix tuners 2022-10-24 11:04:47 +02:00
Jon Evans 2089374f53 ADDED: Export symbols from schematic to library
Fixes https://gitlab.com/kicad/code/kicad/-/issues/11433
2022-09-23 21:23:01 -04:00
Jeff Young a21d24a4c8 Experiment with loading recent searches into the search menu.
Fixes https://gitlab.com/kicad/code/kicad/issues/11743
2022-09-15 14:44:02 +01:00
Jon Evans da9be1a812 ADDED: Multi-selection cut/copy/paste in symbol editor library tree
Fixes https://gitlab.com/kicad/code/kicad/-/issues/11505
2022-09-14 22:20:38 -04:00
Jeff Young b874aaac5e Add display options to Symbol Browser toolbar.
Particularly important on Mac where the menubar is disabled when the
frame is used in modal mode.

Also adds a display control to override the symbol's show pin numbers
setting.

Fixes https://gitlab.com/kicad/code/kicad/issues/7789
2022-09-08 00:28:30 +01:00
Jon Evans ae6a2a6443 ADDED: Database libraries MVP
Allows placing parts from an external database that reference symbols from another loaded library.

Includes:
- nanodbc wrapper
- database schematic library plugin
- basic tests

Fixes https://gitlab.com/kicad/code/kicad/-/issues/7436
2022-08-26 10:51:13 -04:00
Mikolaj Wielgus 6450ec6b85 Sim: Spice netlist exporter rewrite
Rewrite the spice exporter to work with the new simulation model
architecture and data model, with many bugfixes related to the latter
two along the way.
2022-07-30 02:25:34 +00:00
Seth Hillbrand a852286eb5 Cleanup compile warnings 2022-06-21 17:04:56 -07:00
Marek Roszko 08dbc3a53c Move the symbol editor to the new filedlg customize 2022-06-11 22:59:59 -04:00
Marek Roszko ff94d289c7 Move the eeschema standalone to the new save dialog 2022-06-11 22:06:42 -04:00
Roberto Fernandez Bautista 9049c907a1 Fix wxWidgets assert in symbol preview widgets 2022-05-15 15:26:53 +01:00
Sylwester Kocjan f5dedd77c6 eeschema,sim: add SIMULATOR and SIM_MODEL interface
SIMULATOR has now an Attach() method, which should be called
with proper SIMULATION_MODEL that should be simulated, before calling Run()

Concrete class of SIMULATION_MODEL for ngspice is NGSPICE_CIRCUIT_MODEL,
renamed from NETLIST_EXPORTER_PSPICE_SIM. DIALOG_SIM_SETTINGS relies
on above mentioned object, so it was added as an argument of the constructor.
2022-04-01 19:28:31 +00:00
Ian McInerney 0f2e649b18 Cleanup formatting and warnings in tuner_slider 2021-12-30 23:03:13 +00:00
Mikolaj Wielgus 906eee68a5 Another small cleanup after !490 2021-12-29 17:41:21 +01:00
Mikolaj Wielgus a0c4f05c17 Small cleanup after !490 2021-12-28 23:07:30 +01:00
Frank Zeeman 8167c69508 Add transformation function for characteristic curves of tuners 2021-12-28 02:53:39 +01:00
Frank Zeeman f004665df8 Add tuner support for potentiometer code model 2021-12-28 02:53:39 +01:00
Mikolaj Wielgus 2dbc6ef6ca If present, tune Spice_Model instead of Value
Fixes https://gitlab.com/kicad/code/kicad/issues/9880
2021-12-14 14:02:25 +01:00
Seth Hillbrand 9e760512ac Update schematic when saving tuned value
Also avoids a known(!) crash when the existing item has been deleted
while tuning.

Fixes https://gitlab.com/kicad/code/kicad/issues/9502
2021-11-01 17:05:22 -07:00
jean-pierre charras cf6acae791 TUNER_SLIDER: add missing skip event in wxFocusEvents. 2021-10-27 20:33:51 +02:00
Mikolaj Wielgus 28d7a2d7c9 Sim: Update tuner dialog values when focus is lost
Fixes https://gitlab.com/kicad/code/kicad/issues/7841
2021-10-21 13:34:27 +00:00
Wayne Stambaugh 37b200cb3e Pass wxString objects by reference instead of on the stack. 2021-07-27 08:41:27 -04:00
Mike Williams 924d4563b7 Symbol Editor: Don't unselect library based on non-existent symbol
FIXED: Previously, when the symbol editor frame gains focus it will
unselect the library tree selection unconditionally. This is annoying
when adding a new library and then new symbol to a freshly-opened symbol
editor with no other symbol being edited. Anything that gives the editor
focus will deselect your library before you can add a symbol to it.
2021-07-25 21:37:08 +00:00
Wayne Stambaugh cb72da294a More NULL expunging. 2021-07-16 16:13:41 -04:00
Jeff Young 0dfb5fcaf9 Error message cleanup.
wxString::Format is redundant in a wxLogXXX call.
Error messages should generally be translatable.
Error messages should use generally consistent sentence forms.
2021-06-26 22:53:24 +01:00
Jeff Young 5c21f93803 Consistency in progress and error messages. 2021-06-26 13:23:43 +01:00
Wayne Stambaugh fb46cd8bc5 Expunge the use of the word component from Eeschema code.
The only exception to this is the SPICE simulator's use of component
when referring to physical component (R, L, C, etc.) values.
2021-06-14 14:00:21 -04:00
Wayne Stambaugh 71c183d7bb Rename LIB_PART to LIB_SYMBOL. 2021-06-14 07:11:17 -04:00
Wayne Stambaugh fbc135e69f Rename SCH_COMPONENT to SCH_SYMBOL. 2021-06-10 10:34:49 -04:00
luz paz f968fc8719 Fix source comment / documentation typos 2021-06-09 19:32:58 +00:00
Marek Roszko 4df3cb912d Remove another leaky wx/log.h header 2021-06-03 08:11:15 -04:00
Marek Roszko 7faee5eda5 Stop salt the eart with wxhtml.h 2021-06-03 07:49:49 -04:00
Jeff Young 2e3860de6f Naming conventions. 2021-05-05 22:58:40 +01:00
Jeff Young 0c4184f1a4 Split lib tree initialization into a two-pass affair.
This is under the supposition that we can't set the column widths
on some Mac instances because the host controls haven't yet been
created.  This is primarily conjecture based on looking at things
that have the *possibility* of going wrong.  Why this only happens
in some installs is beyond me.

Fixes https://gitlab.com/kicad/code/kicad/issues/5479
2021-04-01 10:51:29 +01:00
Jon Evans 18037e2f65 Rework bitmap system to load from archived PNGs
Bitmaps are now identified by an enum class instead of by pointers.
Bitmap loading and caching is now handled by a class in common, and
we no longer compile most bitmaps into the binary, so there is no
longer a bitmaps static library.

Instead, bitmaps are archived to a .tar.gz file which is installed
in ${KICAD_DATA}/resources/images.tar.gz

The source PNGs are checked in to Git as the original CPP files were,
so that people can build without the required dependencies to convert
SVGs to PNGs.

Initial support is also added for dark theme icons, although this
is not yet exposed in the GUI.

Stubs are present for multi-resolution image resources, but this is
not fully-baked yet and could use some refinement.
2021-03-11 08:37:35 -05:00
Wayne Stambaugh 1786ae8773 Eeschema: use symbol nomenclature for object file naming. 2021-02-24 08:48:02 -05:00
Jeff Young ff7742c6b8 File naming and include cleanup. 2021-01-28 11:35:18 +00:00
Wayne Stambaugh 4619d5e112 Fix more broken Doxygen comment specifiers. 2021-01-26 12:17:52 -05:00
jean-pierre charras 8a278a0579 update tuner_slider_base.fbp to our current wxFormBuilder version. 2020-12-30 19:03:31 +01:00