Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the '10.3: Use Command-N to create new folders' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
10.3: Use Command-N to create new folders
Authored by: connell on Mar 08, '04 10:25:41AM

I would like to add a shortcut to the 'Secure Empty Trash' item in Panther Finder's File menu, but the Keyboard Prefs won't allow me to include the delete key. Does anyone know what the code is that I can use for the delete key if I manually edit the .plist file, and for future reference, where to go to find this info out? Thanks.



[ Reply to This | # ]
10.3: Use Command-N to create new folders
Authored by: fy on Aug 06, '04 08:54:26AM
I don't know where/whether this info is, but making tests shows now that - none, one, or some of modifier keys:

@ for cmd key
~ for option key
$ for shift key
^ but how it works?

plus - one of normal keys:

a,...,z,A,...,Z but case-insensitive
\b for delete key
\t for tab key
\n or \r for return key

makes a shortcut.

For example, the default for "Empty Trash" is '$@\b'. And, use '~\b' if you want to assign option+delete.

------

Finder.app's Menus.nib/objects.xib shows the modifier of UpArrow, used by default for "Enclosing Folder", is a hex string "ef9c800a" ("ef9c810a" / "ef9c820a" / "ef9c830a" for Down Arrow / Left Arrow / Right Arrow)

To put it into .plist, you can use a binary editor or type on a terminal defaults write com.apple.finder NSUserKeyEquivalents... in the form as I mentioned before for this hint. In the latter method, use:

'@$'`perl -e 'print pack("H8","ef9c800a")'` for (cmd+shift+) UpArrow
'@$'`perl -e 'print pack("H8","ef9c810a")'` for (cmd+shift+) DownArrow
'@$'`perl -e 'print pack("H8","ef9c820a")'` for (cmd+shift+) LeftArrow
'@$'`perl -e 'print pack("H8","ef9c830a")'` for (cmd+shift+) RightArrow

[ Reply to This | # ]