With the implementation of the legacy schematic plugin, any I/O error
when parsing the schematics would prevent the entire schematic from
being loaded. This change restores (somewhat) the previous behavior
where as long as the root schematic is loaded properly, then all of
the remaining sub-sheet will attempt to load.
Add GetError() method the SCH_PLUGIN object to allow for partial
schematic loading.
Check the error message contents when no exception was caught to warn
the user of any accumulated errors.
Fixes lp:1690644
https://bugs.launchpad.net/kicad/+bug/1690644
Add SCH_PLUGIN object to PART_LIB object.
Convert all PART_LIB I/O to use SCH_PLUGIN.
Remove library caching from PART_LIB and use caching provided by SCH_PLUGIN.
Add support to use PROPERTIES for buffering and document file write control
instead of adding code the SCH_PLUGIN object in the SCH_LEGACY_PLUGIN that
will not be required when the new file formats are implemented.
Add buffering to SCH_LEGACY_PLUGIN to prevent cache from writing file on
every change to library. This is to prevent the cache library from being
written every time a new symbol is added.
Add option to not save library document file when saving library. This is
primarily used by the cache library write code.
Move symbol library write code out of LIB_PART and into SCH_LEGACY_PLUGIN.
Add exception handling where LIB_PART caught the exception and returned
an error status.
Remove KICAD_SCH_IO_MANAGER build option as it is no longer optional.
Make LIB_PART copy constructor take a const LIB_PART reference.
Add SaveSymbol to legacy symbol library plugin.
Add removeAlias to legacy symbol library cache.
Add AddSymbol to legacy symbol library cache.
* Write SCH_LEGACY_PLUGIN_CACHE object for handling the legacy symbol library
file format.
* Write legacy symbol library file parser.
* Write code to transfer cache to PART_LIB object so existing library save
code can be used for round trip testing. This is temporary until Eeschema
is updated to use the plugin for library management rather than PART_LIB.
* Add LIB_XXXX object helper functions where there was no way to set the member
variables of an object.
* Give the cache object friend status to some object where there are incredibly
byzantine ways of setting text in LIB_XXXX objects.
* Add SCH_PLUGIN::Save() for current file format and code for saving all
SCH_XXX objects.
* Add function to SCH_FIELD to get the position of the field in the component
not the position added to the component position which is what GetPosition()
does. This was required because saving the component field expects position
of the field sans the position of the component.
* Remove public members from BITMAP_BASE object and fix all associated
code.
* Fix the never ending coding policy violations found making these changes.
* Factor out PROPERTIES object from the PCB plugin code and move it into
common so it can be used by both the Pcbnew and Eeschema plugins.
* Add schematic I/O plugin manager for loading and saving schematic and
component library files.
* Add initial attempt at a parser for current schematic file format. This
parser will be infinitely more strict than the current parser which is very
forgiving in what it parses.
* Make minor changes to the base bitmap class to support the new parser.
* Add find root sheet support to sheet object to allow fetching the root
sheet from any sheet in the stack.