@mm-john said in Alt+X is an undocumented/unreported keyboard shotcut for main menu file - close:
Speculating, the &X would make it a npp shortcut and just “X” makes it a windows shortcut.
Nope. When the developer prefixes a letter in the menu entry with the &, the developer is saying “Windows should use this letter as the accelerator key (if it can)”. It’s still Windows that is defining the behavior that Alt+Letter will open/activate that menu entry.
&X would have it underlined all the time?
In any situation in which case the F of File, E of Edit, … t of Settings, o of Tool, … are underlined, the X of X would be, too. If they had defined it as &X
e9ad83a2-750d-4635-9f1d-37e479d5539b-image.png
And, I’m guessing, &X would also make it appear in the Shortcut Mapper?
Nope. Again, it’s not a “shortcut” from Notepad++'s perspective. It’s the Windows OS accelerator key for the menu entry. Notice for Windows that it doesn’t matter whether you type Alt+F to open the File menu or Alt then let go and pause, then hit F: it still opens the File menu in that sequence; and Alt, Pause, X will still close the active – that’s because it’s Windows OS handling the accelerator; it just tells Notepad++ “do whatever you’d do if someone clicked the File (or X) menu entry”. The Notepad++ Shortcut Mapper cannot define a keyboard shortcut that works that way; all Notepad++ keyboard shortcuts all must be simultaneously pressed, even if they have Alt in the shortcut.
I am guessing there’s no way to have windows (os-level) shortcuts appear in the Shortcut Mapper.
You’re right, because it’s not a shortcut; it is a menu accelerator, implemented by the OS, not by the application.
Perhaps a note at the bottom of the Shortcut Mapper that says “additional shortcuts from the (windows) OS are active even tho they are not represented here. A shortcut here will override the OS.”
Please, no. Way too much clutter. The windows accelerators are not shortcuts; they are accelerators, and they work that way in every single windows win32 api-based application that I have used since Windows 3.11, from what I remember. At this point in the windows history, if a user doesn’t know that Alt+letter activates a menu with that accelerator letter, no amount of clutter in a user interface will help with that. The next version of the user manual will attempt to clarify this, but it’s really a Windows default behavior that has worked that way for decades.
Because of this discussion, I have added the paragraph listed above to the user manual repository, so on the next release of the manual, it will be easily accessible in the same place that the shortcut mapper itself is documented.
I have portable, so the path to the shortcuts.xml is wherever the notepad++.exe is stored
That’s well documented in the User Manual. I got tired years ago of typing in every response in this forum “shortcuts.xml in %AppData%\Notepad++ or wherever you happen to have placed your portable version, or in your cloud directory, or in the -settingsDir location”. If you are going to use something other than the standard installation, the onus is on you to understand how to translate the generic instructions into your specific configuration. If you had included the ?-menu’s Debug Info in your post, which would have told me that you had a non-standard installation, I would have customized my reply to your exact portable location. But barring that information being already transmitted to me, I will assume you have a standard installation. (And this despite the fact that for my entire workday every weekday, I am working out of a portable, and thus it’s more natural for me.)