Customized Keystrokes

When the program starts, it looks in the specified or default account directory, then in the Mailer directory, for a file named Custom.Keystrokes (or CUSTOM.KYS if Polarbar is configured to use short file names). If it finds such a file, it will replace entries in the program's default keystroke table (for keys which activate various functions while the browser portion of the program's main window has the system focus) with any matching entries in that file. For example, you could change the keystroke for deleting a message from Ctrl+D, the program's default, to the Delete key for all of your accounts except one by having a Custom.Keystrokes file in your Mailer directory and having another Custom.Keystrokes file in that one account's directory to change his Delete keystroke to Alt+D instead.

The Custom.Keystrokes file needs to have one entry on each line. An entry is made of two pieces of data followed optionally by a comment. The first piece of data is either the keystroke name or NULL. Shift, Alt, and Ctrl keys, when used, are joined to the other piece of each keystroke's name by a plus (+) sign. Any space characters in a key name need to be replaced by underscore (_) characters. For example, the official Java name of the Page Down key is PAGE DOWN, so in the Custom.Keystrokes file the entry would be PAGE_DOWN instead. Using NULL instead of a keystroke name results in there being no keyboard shortcut key for the specified command (i.e., it can only be invoked from the menu).

Any number of space characters can come between the keystroke name and the second piece of data on each line. The second piece of data is the command that the program is to issue in response to the specified keystroke. Here, as a sample, is a Custom.Keystrokes file which would serve no purpose at all, because it specifies the exact keystroke/command combinations that the program uses by default if no Custom.Keystrokes file is found:

Ctrl+PAGE_DOWN NextMessage
Ctrl+PAGE_UP PrevMessage
Ctrl+A SaveAs
Ctrl+B PrevUnread
Ctrl+D Delete
Ctrl+E RevealHeaders
Ctrl+F Forward
Ctrl+G GetMail
Ctrl+H ToggleHeaders
Ctrl+I InternetBrowser
Ctrl+J FindNext
Ctrl+K ColorCode
Ctrl+L FindFirst
Ctrl+M FolderMove
Ctrl+N NextUnread
Ctrl+O Compose
Ctrl+P Print
Ctrl+Q QuickAddAddress
Ctrl+R Reply
Ctrl+S StickyNotes
Ctrl+T ToggleFont
Ctrl+U MarkUnread
Ctrl+V ViewMessage
Ctrl+W ToggleWordWrap
Ctrl+X ToggleBrowser
Ctrl+Y MailFilters
Ctrl+Z ViewPopFile
Ctrl+/ SelectAllMessages
Space NextPage
Null BayesianBad
Null BayesianCheck
Null BayesianGood
Null BayesianUnmark
Null CollapseAllFolders
Null DelNoTrash
Null ExpandAllFolders
Null Filter
Null MarkAsRead
Null SendMail
Null gotoFolder([foldername])
Null moveToFolder([foldername])
Null runExitProgram([program name],[parameters])




As you can see, the last three commands accept parameters. You should replace the bracketed information with actual data. Example: 'CTRL+I gotoFolder(inbox)' will assign the Ctrl I key combination to bring you to your inbox.
After those two pieces of data, any line may also contain any comments you want to put there, as long as you leave at least one space character between the command name and your comment.

Many keystrokes have different Java names in different operating systems, unfortunately. But at least the majority of those are keys to which people are rather unlikely to want to assign commands.

Here are the keys which have the same names under Windows and OS/2, at least, regardless of whether they're used by themselves or with Shift, Alt, or Ctrl: