From e22c80038cf0d59449daeaaf5abcecbd6f7704b9 Mon Sep 17 00:00:00 2001 From: Just van Rossum Date: Wed, 27 Nov 2024 08:17:36 +0100 Subject: [PATCH] Keep edit layer info with undo record --- src/fontra/views/editor/scene-controller.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/fontra/views/editor/scene-controller.js b/src/fontra/views/editor/scene-controller.js index b5d7a85d8..4ca64fd6e 100644 --- a/src/fontra/views/editor/scene-controller.js +++ b/src/fontra/views/editor/scene-controller.js @@ -1146,6 +1146,8 @@ export class SceneController { redoSelection: this.selection, fontLocation: this.sceneSettings.fontLocationSourceMapped, glyphLocation: this.sceneSettings.glyphLocation, + editingLayers: this.sceneSettings.editingLayers, + editLayerName: this.sceneSettings.editLayerName, }; if (!this._cancelGlyphEditing) { editContext.editFinal( @@ -1198,6 +1200,8 @@ export class SceneController { // the glyph data (eg. a source being there or not) this.sceneSettings.fontLocationSourceMapped = { ...undoInfo.fontLocation }; this.sceneSettings.glyphLocation = { ...undoInfo.glyphLocation }; + this.sceneSettings.editingLayers = undoInfo.editingLayers; + this.sceneSettings.editLayerName = undoInfo.editLayerName; } await this.sceneModel.updateScene(); this.canvasController.requestUpdate();