Add 'Create alias' option to right-click context menu of Sequences dialog
Currently the Sequence dialog's right-click context menu has two entries:
- Copy to clipboard
- Add to favorites
Can we get a third entry:
- Create alias
This entry could simply bring up the user-defined .XCompose file in an editor, but with the last line of the file automatically filled in with a template for the new sequence.
For instance, say I wanted to make an alias for "grinning face with smiling eyes". The default sequence is <Multi_key> <Multi_key> <g> <r> <i> <n> <n> <i> <n> <g>. Suppose I want to alias this to <Multi_key> <colon> <D> instead?
I propose being able to bring up the Sequences dialog, type "face" or "grinning" or whatever into the filter, find the correct face, right-click it, choose this awesome new Create alias entry and WinCompose will bring up the .XCompose file editor with the last line auto-filled in with a template for the selected sequence, perhaps something like:
<Multi_key> <XXX> : "😄" # New alias, fill in keys for XXX
Then I edit this entry and replace the <XXX> with <colon> <D> and edit the "# New alias" comment to "grinning face" or whatever, and then click Reload in the Sequences dialog.
Hopefully this is simple enough to implement quickly. A more polished solution would be to create a new dialog window specifically for inputting keystrokes for aliases, which would be nice to have.
edit: The more polished solution (new dialog window specifically for inputting new aliases) would ideally also check for conflicts and warn if <Multi_key> <colon> <D> was already being used. On the other hand, the .XCompose editor solution should be quicker to implement. I ask for this because a lot of the smiley emoji have very long sequences and I'm hoping to be able to make aliases for them much more easily.
Update: on the other hand, editing the .XCompose file proved to be trivial once I found a few repositories hosting their own custom .XCompose files containing sequences for just about absolutely everything one could ask for. Many of these repositories are MIT or otherwise openly licensed. It may be useful to add their contents to WinCompose's .XCompose file or as additional checkboxes in the Settings dialog.