Using BBEdit as an external editor for Mail

441 views
Skip to first unread message

Matt Martini

unread,
Apr 29, 2010, 11:54:34 PM4/29/10
to bbe...@googlegroups.com
HI,

Does anyone know a way to use BBEdit as an external editor for Mail.app?

I recently found that MacVIM has a preference to "add an external editor menu item for Mail and Safari,"
however this did not work for me in Snow Leopard.

I was hoping someone here knew a trick to get BBEdit to be the editor when composing new mail messages.

Matt

--
You received this message because you are subscribed to the
"BBEdit Talk" discussion group on Google Groups.
To post to this group, send email to bbe...@googlegroups.com
To unsubscribe from this group, send email to
bbedit+un...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/bbedit?hl=en
If you have a feature request or would like to report a problem,
please email "sup...@barebones.com" rather than posting to the group.

Tim Gray

unread,
Apr 29, 2010, 11:58:01 PM4/29/10
to bbe...@googlegroups.com
On Apr 29, 2010 at 11:54 PM -0400, Matt Martini wrote:
> Does anyone know a way to use BBEdit as an external editor for Mail.app?

I use it as an external editor for mutt. The editor in Mail is the primary
reason I don't use Mail. I used to use Mailsmith, which is almost perfect,
but the lack of IMAP finally became a show stopper for me.

I don't know if there is a no-hassle method for Mail. I'm interested to
hear what people have to say.

Charlie Garrison

unread,
Apr 30, 2010, 4:47:56 AM4/30/10
to bbe...@googlegroups.com
Good evening,

On 29/04/10 at 11:54 PM -0400, Matt Martini
<matt.m...@gmail.com> wrote:

>Does anyone know a way to use BBEdit as an external editor for Mail.app?
>
>I recently found that MacVIM has a preference to "add an
>external editor menu item for Mail and Safari,"
>however this did not work for me in Snow Leopard.
>
>I was hoping someone here knew a trick to get BBEdit to be the
>editor when composing new mail messages.

The short answer would be AppleScript. The long answer I'll have
to leave to someone else.

If vim (or macvim) can be used as an external editor then you
should be able to swap in 'bbedit' command line tool in place of
'vim'. (I'm not sure what macvim is, or how it's different from
standard vim.)


Charlie

--
Ꮚ Charlie Garrison ♊ <garr...@zeta.org.au>

O< ascii ribbon campaign - stop html mail - www.asciiribbon.org
http://www.ietf.org/rfc/rfc1855.txt

Matt Martini

unread,
Apr 30, 2010, 11:14:34 AM4/30/10
to bbe...@googlegroups.com
MacVim is sort of gVIM with a mac osx interface. It has a feature that adds a hack to your system that puts
an "edit in BBEdit" menu item under edit in Mail. On set up you can choose BBEdit or macvim or textmate...
This works on an old Tiger system, but not under Snow Leopard.

What it does is take selected text, open it in BBEdit, lets you edit the content, and then on doc close brings the
modified text back into Mail. Not really as integrated as I would like, but much better than doing the above steps by hand
which is what I usually do to edit a new message.

I'm not sure how this hack works (probably applescript) but I'd really like to see it working in Snow Leopard. Anyone
want to give it a shot?

Any chance or real integration happening? (yes, mailsmith is cool, but no IMAP is a killer for me too).


On Apr 30, 2010, at 4:47 AM, Charlie Garrison wrote:

>
> On 29/04/10 at 11:54 PM -0400, Matt Martini <matt.m...@gmail.com> wrote:
>
>> Does anyone know a way to use BBEdit as an external editor for Mail.app?
>>
>> I recently found that MacVIM has a preference to "add an external editor menu item for Mail and Safari,"
>> however this did not work for me in Snow Leopard.
>>
>> I was hoping someone here knew a trick to get BBEdit to be the editor when composing new mail messages.
>
> The short answer would be AppleScript. The long answer I'll have to leave to someone else.
>
> If vim (or macvim) can be used as an external editor then you should be able to swap in 'bbedit' command line tool in place of 'vim'. (I'm not sure what macvim is, or how it's different from standard vim.)
>

Matt Martini

unread,
Apr 30, 2010, 12:25:03 PM4/30/10
to bbe...@googlegroups.com
It seems that the mechanism used is an InputManager called the ODB Editor Suite. BBEdit, TextMate, ...
support this, but it seems like it no longer works in Snow Leopard (at least on the two machines I tried it on).
It does work inTiger.

Anyone in BBEdit land know if Apple pulled support for this, or do I have something wrong in my setup?

Christian Bogen

unread,
Apr 30, 2010, 5:11:44 PM4/30/10
to bbe...@googlegroups.com
Try QuickCursor [1]. I don’t know if it works with Mail, though.



Chris

John Delacour

unread,
Apr 30, 2010, 5:54:02 PM4/30/10
to bbe...@googlegroups.com
At 23:11 +0200 30/4/10, Christian Bogen wrote:

>Try QuickCursor [1]. I don’t know if it works with Mail, though.
>
>[1]Ê<http://www.hogbaysoftware.com/products/quickcursor/>http://www.hogbaysoftware.com/products/quickcursor/


... where you will read:


"It’s also incomplete. It works with some applications and
doesn’t with others. Technically it works with any application that
exposes its text to the Mac OS X Accessibility API through a single
string value. One popular case where it does not work is in Mail.app."

This is probably because Mail.app has never (at least as far a
10.4.11) allowed Apple events to get the selected text -- one of many
absurdities in Mail.

JD

Matt Martini

unread,
Apr 30, 2010, 7:37:55 PM4/30/10
to bbe...@googlegroups.com
Tech Support at TextMate confirmed that the ODB Editor Suite and InputManagers in general do not work in 64-bit mode.  :(

And as we see from John's post it is unlikely that we can do this via Applescript (or did I read that wrong?)

From: John Delacour <johnde...@gmail.com>

This is probably because Mail.app has never (at least as far a 10.4.11) allowed Apple events to get the selected text -- one of many absurdities in Mail.

On Apr 30, 2010, at 12:25 PM, Matt Martini wrote:

It seems that the mechanism used is an InputManager called the ODB Editor Suite.  BBEdit, TextMate, ...
support this, but it seems like it no longer works in Snow Leopard (at least on the two machines I tried it on).
It does work inTiger.

Anyone in BBEdit land know if Apple pulled support for this, or do I have something wrong in my setup?


LuKreme

unread,
Apr 30, 2010, 7:53:08 PM4/30/10
to bbe...@googlegroups.com
On 30-Apr-2010, at 17:37, Matt Martini wrote:
>
> InputManagers in general do not work in 64-bit mode. :(

I don't think Input Managers work at all in Snow Leoaprd, 64-bit or not.

--
I WILL NOT TRADE PANTS WITH OTHERS Bart chalkboard Ep. 7F05

Walter Ian Kaye

unread,
May 2, 2010, 1:56:54 AM5/2/10
to bbe...@googlegroups.com
At 07:37 p -0400 04/30/2010, Matt Martini didst inscribe upon an
electronic papyrus:

>And as we see from John's post it is unlikely that we can do this
>via Applescript (or did I read that wrong?)

Well there's always ye olde clipboard....

Kaush

unread,
Apr 6, 2012, 5:37:56 AM4/6/12
to bbe...@googlegroups.com
Just noticed that this topic has been discussed in quite a few places here in the groups. I've added my KM solution as a reply in those places as well. 

Hope you find the above useful. 


On Friday, April 30, 2010 6:54:34 AM UTC+3, Matt wrote:
HI,

Does anyone know a way to use BBEdit as an external editor for Mail.app?

I recently found that MacVIM has a preference to "add an external editor menu item for Mail and Safari,"
however this did not work for me in Snow Leopard.

I was hoping someone here knew a trick to get BBEdit to be the editor when composing new mail messages.

Matt

--
You received this message because you are subscribed to the
"BBEdit Talk" discussion group on Google Groups.
To post to this group, send email to bbe...@googlegroups.com
To unsubscribe from this group, send email to
Reply all
Reply to author
Forward
0 new messages