The library manager update part function was orphaning the root symbol
of derived symbols when the root symbol was edited. Re-parent the
inherited symbols when updating a root symbol.
Update the mandatory field attributes whenever the parent is set for
derived parts. This will show the fields with the correct attributes
in the symbol editor and viewer.
Using std::unique_ptr to hold the current symbols was deleting the
pointer on symbol selection changes causing the pointer in the library
manager buffer to be stale in some cases. Revert back to using a
simple pointer and manual clean up as required.
Prevent derived symbols from being saved to a different library to
prevent orphaned symbols.
Fixes kicad/code/kicad#3649
This change completely removes the LIB_ALIAS design pattern an replaces
it by allowing LIB_PART objects to inherit from other LIB_PART objects.
The initial implementation only allows for single inheritance and only
supports the mandatory fields in the derived part because that is all
that the current symbol library file format will support. Once the new
file format is implemented and saving to the old file format is deprecated,
more complex inheritance will be added. The LIB_ALIAS information saved
in the document files was move into the LIB_PART object. This change
impacts virtually every part of the schematic and symbol library editor
code so this commit message is woefully incomplete.
REMOVE: Removed the symbol aliases concept from the schematic and symbol
editors and the symbol viewer.
NEW: Replace the symbol alias concept with simple inheritance that allows
a library symbol to be derived from another library symbol.