I am building a new QuPath extension and I want to add a new menu option to duplicate currently selected annotation. It would be easier for pathologist during annotation time to just quickly duplicate a selected annotation and modify it according to specifications. It can get cumbersome if one needs to always select it from the menu so I want to create a keyboard shortcut with the menu item and I don’t really know how to do it. Currently:
QuPathGUI.addMenuItems(binaryMaskMenu, QuPathGUI.createCommandAction( new DuplicateAnnotation(), "Duplicate selected annotation"));
How to do it to work on Windows, Mac and Linux as well? If I set Alt + D in the extension will it be the same for all platforms?
Thanks in advance.