Key map, action map, delete
I'd like to hook up the action where the user presses DELETE key at the end of one child, which deletes its next-sibling. I can't seem to capture this event no matter what I try. Any ideas?
(The goal is that when I press DELETE at the end of the child, the child gets concatenated (say, the child is just a node with a string property) with the next-sibling instead of just deleting the next sibling. Similarly when I press BACKSPACE at the beginning of a child, it concatenates with the prev-sibling. I can do the BACKSPACE part by hooking up the DELETE action in the action map, but I can't do the DELETE part.)
(The goal is that when I press DELETE at the end of the child, the child gets concatenated (say, the child is just a node with a string property) with the next-sibling instead of just deleting the next sibling. Similarly when I press BACKSPACE at the beginning of a child, it concatenates with the prev-sibling. I can do the BACKSPACE part by hooking up the DELETE action in the action map, but I can't do the DELETE part.)
Please sign in to leave a comment.
going to correct it now ;-)
So, currently you can attach action map handling any common actions onto a cell editing child link declaration in parent node. In this case all specified actions should be applied to all top-level child cells created inside this collection (top-level cells for child nodes).
Are there plans to improve the editor key maps / action maps so that they can be easily used and customizable at a lower level? One example use case would be a multiline string that exist in some languages such as Python, and it's really difficult to mimic a text like editor in MPS, one reason of which is the difficulty of using action/key maps.