In order to avoid confusion when loading legacy schematics, updating time
stamp UUIDs is no longer performed. If users where not experiencing issues
with time stamp clashes with shared schematics then this was probably a
case of me being overly cautious.
The original conversion code has be moved to
SCH_EDIT_FRAME::ConvertTimeStampUuids() so the working functionality is
not lost. This function should not be used until a way is found to update
the board from the schematics with the appropriate settings.
This is a very large and potentially disruptive change so this will be an
unusually long and detailed commit message.
The new file formats are now the default in both the schematic and symbol
library editors. Existing symbol libraries will be saved in their current
format until new features are added to library symbols. Once this happens,
both the legacy schematic and symbol file formats will be no longer be
savable and existing libraries will have to be converted. Saving to the
legacy file formats is still available for round robin testing and should
not be used for normal editing.
When loading the legacy schematic file, it is imperative that the schematic
library symbols are rescued and/or remapped to valid library identifiers.
Otherwise, there will be no way to link to the original library symbol and
the user will be required manually set the library identifier. The cached
symbol will be saved in the schematic file so the last library symbol in
the cache will still be used but there will be no way to update it from the
original library.
The next save after loading a legacy schematic file will be converted to
the s-expression file format. Schematics with hierarchical sheets will
automatically have all sheet file name extensions changed to .kicad_sym
and saved to the new format as well.
Appending schematics requires that the schematic to append has already been
converted to the new file format. This is required to ensure that library
symbols are guaranteed to be valid for the appended schematic.
The schematic symbol library symbol link resolution has been moved out of
the SCH_COMPONENT object and move into the SCH_SCREEN object that owns the
symbol. This was done to ensure that there is a single place where the
library symbol links get resolved rather than the dozen or so different
code paths that previously existed. It also removes the necessity of the
SCH_COMPONENT object of requiring any knowledge of the symbol library table
and/or the cache library.
When opening an s-expression schematic, the legacy cache library is not
loaded so any library symbols not rescued cannot be loaded. Broken library
symbol links will have to be manually resolved by adding the cache library
to the symbol library table and changing the links in the schematic symbol.
Now that the library symbols are embedded in the schematic file, the
SCH_SCREEN object maintains the list of library symbols for the schematic
automatically. No external manipulation of this library cache should ever
occur.
ADDED: S-expression schematic and symbol library file formats.
* 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.
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
Please note that the symbol cache is not embedded in the schematic file
to allow for round robin testing with the existing file format. Once
the parser round robin testing is complete, the symbol cache will be
embedded in the schematic file.
Keeping a pointer to the actual file history inside a special
file history menu led to many cases of use after free crashes,
so instead rework the actual file history to add the menu
items.
Fixes https://gitlab.com/kicad/code/kicad/issues/3741
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.
If the point editor is active and a change is made, the tool was shut down after
deleting the board data, in the frame Dtor.
Therefore a crash happened because a call to GetScreen()->SetModify(); using a null pointer,
and after the test for modifications was done.
Now tools are stopped when closing the window, before any test for modifications.
This moves EESchema DLIST structures to rtree. These changes are more
fundamental than the pcbnew changes from 9163ac543888c01d11d1877d7c1
and 961b22d60 as eeschema operations were more dependent on passing
drawing list references around with SCH_ITEM* objects.
and switch to the paren sheet from the context menu.
Mainly, change the way the dialog is managed from the sch_edit_frame:
the pointer to find the created dialog is replaced by a call to wxWidows::FindWindowByName().
Using a pointer set and cleared by events is a recipe for crashes.
ADD: User can now decide to keep the hierarchy navigator open while working
on a schematic.
This behavior can be configured in eeschema->preferences->eeschema->Editing options.
Create an IsContentModified() function in each frame
that provides if the content has been modified, and
use that instead of always copying the checks.
ADDED: a config option to select (when clicking on a pin) the parent symbol
or only the pin.
Previously, when cliking on a pin, the parent symbol was selected.
Allowing the pin selection is mandatory in cross probing, and to display the pin
characteristics in some cases, for instance if a pin is flagged by the ERC tooL.
Add missing check for root sheet when searching sheet hierarchies for
already loaded schematics. This prevents the root sheet from being
omitted when adding new sheets using the root sheet file name.
CHANGED: Make file name tests case sensitive so that schematic sheet
file names on non-Windows systems can be uses as expected.
Warn users when attempting to use schematic file names that only vary
by case sensitivity that doing so will result in a project that is not
portable to Windows.
Fixes lp:1843415
https://bugs.launchpad.net/kicad/+bug/1843415
CHANGED: No longer call schematics noname.sch in standalone mode,
instead don't given them any name so the user can choose on save.
Fixes: lp:1852607
* https://bugs.launchpad.net/kicad/+bug/1852607
We have different requirements than sheet paths for netlists,
so going through that code and then doing a lot of conversions
just ends up with a mess.
We now generate the path directly from the SCH_SHEET_PATH.
Fixes: lp:1852353
* https://bugs.launchpad.net/kicad/+bug/1852353
The new connectivity algorithm had a tendency to cleanup
globally, but that could insert undo records from other sheets
into the current screen's undo stack. Needless to say, this
was a recipie for segfaults.
Fixes: lp:1846247
* https://bugs.launchpad.net/kicad/+bug/1846247
While it's tempting to look at the changed flag that TestDanglingEnds
returns, it's insuficient as the connectivity algorithm might have
already updated it (and ignored the changed flag).
Fixes: lp:1835107
* https://bugs.launchpad.net/kicad/+bug/1835107
Check for symbol libraries that somehow ended up in the project file
after remapping occurred and remove all of them to prevent potentially
broken symbol library links.
Add nagware dialog to warn the user and a checkbox to never show the
dialog again.
Fixes lp:1838185
https://bugs.launchpad.net/kicad/+bug/1838185
Also rewrites the PCBNew Find dialog to make use of the above, including:
1) searching in user-defined footprint fields
2) searching in pcb text
3) a history list in the search popup
4) case sensitive searching
5) word sensitive searching
6) the ability to turn wildcard searching on/off
7) better placement of the result when the dialog obscures part of the
window
Fixes: lp:1838006
* https://bugs.launchpad.net/kicad/+bug/1838006
Previously, for instance after modifying preferences or language,
they were rebuilt but the tools state was not set due to a missing call to SyncToolbars() after rebuilding.
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
EEschema optimizes wires by merging colinear segments. If a schematic opened without a valid
cache library or missing installed libraries and later saved, this optimization can cause connectivity
errors. In order to fix that we check each pin-wire connection and junctions if necessary.
Netlists do not accept any char in netnames (especially spice).
They must use only "/" as root sheet path name.
Especially _( "<root sheet>" ) breaks netlists because:
- there is a space in name, and special chars (< and >)
- it is a translatable name. so the actual name cannot be managed.
- most of netlist code in Kicad expects a "/" as root path.
Prefix the sheet name with "Sheet: " and the sheet file name with "File: "
when plotting so that it matches the display sheet rendering.
Improve the root sheet plot file name.
Fixes lp:1832081
https://bugs.launchpad.net/kicad/+bug/1832081
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.
These options were used to support the legacy canvas when drawing on
MacOS and GTK3. With the move to 100% GAL, they are extraneous. This
moves all DC over to "COPY" as we only use this for printing support in
Eeschema at the moment, so there is a single draw command (no erasing)
for the canvas.
This is a stop gap fix. It should be possible to use the wxFrame title
string for this but some of the frame windows have appropriated the title
string for configuration file naming purposes which is less than ideal.
Fixes lp:1825977
https://bugs.launchpad.net/kicad/+bug/1825977
It was confusing that the primary frames registered their tools
differently than the other frames. In addition, since the other
frames also added their own tools, foo_actions::RegisterAllTools()
didn't really register all tool but rather those used by the
principal frame (PCB_EDIT_FRAME, SCH_EDIT_FRAME, etc.)
Don't edit sheet during AddToScreenAndUndoList() call. If it's
cancelled and we delete the item, callers will still own pointers
to the freed memory. Do it in New and Paste instead.
OnModify() is called when staging the undo/redo modifications. This
requires that it not create changes that themselves need to be placed
in the undo/redo stack
This allows us to make the various netlist and pcb update routines
more atomic and less reliant on carefully sequenced asynchronous
messages.
This is also a prelude to adding support for footprint testing
without a netlist.
Save/restore default netclass.
Read layers back in with correct syntax ('.' between keyword and layer name).
Write layers to project file.
Read/write layer enablement bits.
Don't set solder paste margin min to 0 (most of them are negative).
Fixes: lp:1811990
* https://bugs.launchpad.net/kicad/+bug/1811990
Remove unnecessary calls to TestDanglingEnds()
Disable real-time connectivity updates for now
Revert "Remove unnecessary calls to TestDanglingEnds()"
This reverts commit d93e3894f2bcd6239862ac9eae0cb2f994b9d52a.
Remove debug code
Bus upgrades: core new connectivity code
Bus upgrades: eeschema integration and modifications
Bus upgrades: eeschema dialogs
Bus upgrades: netlist export
Bus upgrades: file format changes
Autosave was not working correctly, partly due to different
implementations in eeschema and pcbnew and partly due to a mistaken
refactor at some point during v5 development. This unifies the expected
autosave prefix to _autosave- for both pcbnew and eeschema. It also
unifies the expected suffix for the backup files to -bak.
Fixes: lp:1820433
* https://bugs.launchpad.net/kicad/+bug/1820433
For some reason, changing languages was causing the options (left) toolbar
to get redrawn with some of the main toolbar entries. Changing the window
size causes the toolbar to be redrawn correctly. The normal call to
function wxWindow::Refresh() does not.
Fixes lp:1816492
https://bugs.launchpad.net/kicad/+bug/1816492
This makes using Scrollbars more easy to use, especially for "small" page sizes like A or B.
Note also the working/drawing area size is bigger than the page size (3 times)
Split antialiasing options out from display options. Move
antialiasing to common. Duplicate the rest of display options
for Eeschema.
Implement OnSelectGrid and hookup GAL canvas refresh to
SetPresetGrid.
Add Grid Settings... to View menu and move Show Grid from
preferences to View Menu to match Pcbnew.
Previously, when creating a new instance of a sheet, the full set of references
was cleared.
Moreover, if this sheet has sub-sheets, the annotation was incorrectly handled
Now only (and all) new sheet path(s) created have a reference cleared, as expected.
(new sheet paths can be more than one, if the new instance of the sheet has sub-sheets)
Fixes: lp:1789048
https://bugs.launchpad.net/kicad/+bug/1789048
We have a dialog shim that raises the ERC dialog in front of the
schematic frame, which is useful for keeping the ERC dialog visible
during debugging. But mouse move events do not pass through to the
schematic, resulting in a captured mouse pointer but no drawing updates.
As a work-around we close the ERC dialog while placing new components.
Previous ERC data still exist when the window is launched again.
Fixes: lp:1779851
* https://bugs.launchpad.net/kicad/+bug/1779851
Also updates the file menu IDs so that we can actually handle
more than 9 items in the file history.
Also adds configurable file history length to the other gerber
files (zip, drill and job).
Fixes: lp:1745729
* https://bugs.launchpad.net/kicad/+bug/1745729
Primary change is to replace most control/window borders with
AUI pane borders. We implement our own AUI border drawing
routine which avoids the ugly one-pixel white frames around
dark canvasses.
Also increases the signal-to-noise ratio of all the pane
creation code in the various frames.
This also fixes a bunch of bugs where an error during save would
still close the window (rather than cancelling the close action).
Fixes: lp:1785034
* https://bugs.launchpad.net/kicad/+bug/1785034
Also fixes a bug where unannotated components would get references
of the form R-1 (because their reference number was -1).
Fixes: lp:1768814
* https://bugs.launchpad.net/kicad/+bug/1768814
This is due to the fact the same ID was used for menuitems in menubar,
and tools in toobars.
Especially, some items were not compatible due to different attributes.
Windows does not accept the same ID for 2 items inside the same frame.
It creates issues (items not shown, Asserts, ...)
This also makes the dialog modeless so that one switch between
sheets while annotating to choose the base numbers for each
sheet (assuming they don't like the base number we pick because
of the order of the sheets).
Fixes: lp:1154131
* https://bugs.launchpad.net/kicad/+bug/1154131
Also fixes:
- forcing the annotation scope to "full schematic" when run
as a prerequisite to Generate Netlist.
- a long-standing bug where displaying extra items in a dialog
would mess up the height of the HTML_REPORT_PANEL (becasue
we were setting the html window's height rather than its
parent flexgrid.
- initializing the annotation radio buttons to safe values
(full schematic and keep existing)
Fixes: lp:1750062
* https://bugs.launchpad.net/kicad/+bug/1750062
Board update KiWay request may now contain options in the message
payload:
- "no-annotate": do not enforce annotation
- "quiet-annotate": annotate without displaying a dialog
- "by-reference": update netlist by reference, no dialog displayed
- "by-timestamp": update netlist by timestamp, no dialog displayed
Fixes a bunch of errors:
- libedit and libbrowser would zoom to bounding box but centre on canvas
- libedit, libbrowser and gerbview didn’t take the scroll bars into account
- pcbnew didn’t take scroll bars into account or apply the 10% margin
- appending a board file would re-centre, but not re-zoom
Fixes: lp:1504302
* https://bugs.launchpad.net/kicad/+bug/1504302