enso/app/gui/controller
Ilya Bogdanov b49cc25d38
Copy-pasting nodes (#7618)
Closes #6261

- Adds support for copy-pasting nodes with `cmd + C` and `cmd + V` shortcuts.
- Only a single, currently selected node will be copied. Adding support for multiple node copies seems easy, though (but was out of the scope of the task).
- We use a custom data format for clipboard content. Node's metadata is also copied, so opened visualizations are preserved. However, the visualization's size is not preserved, as we do not store this info in metadata.
- For custom format to work, we use a pretty new feature called [Clipboard pickling](https://github.com/w3c/editing/blob/gh-pages/docs/clipboard-pickling/explainer.md), but it is available in Electron and in most browsers already.
- Pasting plain text from other applications (or from Enso, if the code is copied in edit mode) is supported and is currently enabled. There are some security concerns related to this, though. I will create a separate issue/discussion for that.
- Undo/redo works as you expect.
- New node is pasted at the cursor position.


https://github.com/enso-org/enso/assets/6566674/7a04d941-19f7-4a39-9bce-0e554af50ba3
2023-08-30 13:04:21 +00:00
..
double-representation Copy-pasting nodes (#7618) 2023-08-30 13:04:21 +00:00
engine-model Build script merge (#3743) 2022-10-10 23:38:48 +02:00
engine-protocol Notification about the project rename action (#7613) 2023-08-22 11:32:46 +00:00
src Build script merge (#3743) 2022-10-10 23:38:48 +02:00
Cargo.toml New IDE build script (#3466) 2022-05-23 04:16:04 +02:00