How could I create a key shortcut in OS X Lion so when I am using Safari, I type these keys and inmediately a "New Message" window from Mail.app shows up?
|
You have several options how to do this without third party software. The easiest way is to create a Service in Automator: Open Automator, create a new Service that receives no input in any application and add a single New Mail Message action. Customize some field (e.g. recipient) you want to set default values for. Save as any name, and it's available in every application's Services menu. Assign a keyboard shortcut in System Preferences » Keyboard » Keyboard Shortcuts » Services.
Another options is AppleScript:
This uses Mail's API that behaves slightly differently than the UI in Lion with full-screen mode. You have most flexibility using AppleScript if you have additional requirements, but it's more difficult. Open Automator like described above, and create a Service with a single Run AppleScript action. Paste the code into its text box. The Services menu already has several services related to email by default, you just need to assign keyboard shortcuts:
If you use an application launcher such as Quicksilver, LaunchBar, or Alfred, they might have this functionality already. For example, in LaunchBar, it's called New Mail Message. |
||||
|
|
|
Alfred (with the Powerpack) provides an easy way to assign shortcuts to scripts as well:
|
|||
|
|

