Changing the generator will often modify the underlying children's properties. We should store these data in the stack. Also add the ability to change layers Fixes https://gitlab.com/kicad/code/kicad/-/issues/21476