After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 168585 - Sending a photo by email starts new Thunderbird
Sending a photo by email starts new Thunderbird
Status: RESOLVED FIXED
Product: f-spot
Classification: Other
Component: General
CVS
Other Linux
: Normal minor
: ---
Assigned To: F-spot maintainers
F-spot maintainers
: 388594 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2005-02-26 14:39 UTC by Bengt Thuree
Modified: 2007-01-25 11:19 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
email support for thunderbird, seamonkey and kmail (3.76 KB, patch)
2007-01-07 18:37 UTC, Sascha Umlang
none Details | Review
committed version (3.69 KB, patch)
2007-01-25 11:17 UTC, Stephane Delcroix
none Details | Review

Description Bengt Thuree 2005-02-26 14:39:23 UTC
Version details: 0.0.9
Distribution/Version: Ubuntu, Hoary

1) Start Thunderbird as your mail client in Gnome (Ubuntu, Hoary)
2) Start f-spot (0.0.9)
3) Select picture
4) In F-Spot, choose to send this picture by e-mail.
5) A new instance of Thunderbird tries to start, but fails due to locking issues.

F-Spot should not start a new instance of the main e-mail client software, but
if one is running only start a new instance of compose mail.
Comment 1 Larry Ewing 2005-02-28 03:28:00 UTC
This is an ubuntu gnome configuration issue not an f-spot issue.  F-Spot just
calls the command that gnome uses to handle mailto: urls.
Comment 2 Bengt Thuree 2005-10-13 06:53:13 UTC
Some additional comments to this bug thread.

For Mozilla mail options, please check
http://www.mozilla.org/docs/command-line-args.html

In short:
"to='foo@nowhere.net,foo@foo.de',subject=cool page,attachment='a.jpg,b.jpg,c.jpg'"

Seems to be problems with 
1) attach (for evolution) and attachment (for thunderbird)
2) &attach=a.jpg&attach=b.jpg (for evolution) and
,attachment='file://a.jpg,file://b.jpg' (for thunderbird)
3) Thunderbird: Enclosing all parameters in one set of ""

Sample from command line for mozilla-thunderbird
 mozilla-thunderbird -mail -compose
"subject=Hejsan,attachment='file:///tmp/a.jpg,file:///tmp/b.jpg'"

Sameple from command line for evolution
evolution-2.4 mailto:?subject=Pictures\&attach=/tmp/a.jpg\&attach=/tmp/b.jpg


Comment 3 Bengt Thuree 2005-10-13 06:55:31 UTC
Forgot that if thunderbird is still running, then a new profile is asked for by
default. 
Comment 4 Martijn Vermaat 2005-12-02 13:54:55 UTC
It seems that Thunderbird does come up with a correct compose window (ie not
bringing up the profile selector) when one of the subject or attachment
parameters is present.

So 'mozilla-thunderbird -compose' brings up the profile selector, whereas
'mozilla-thunderbird -compose subject=test' correctly opens a compose window.

The difference in passing information to the mail clients is a problem I think.
Is there some standard fot this? If there is, Thunderbird and/or Evolution
should support it. If there isn't, I think the solution would be for F-Spot to
try very hard to support different mail clients.
Comment 5 Larry Ewing 2006-01-09 05:16:43 UTC
Ugh this is a mess, I'll ping the evolution developers about it.
Comment 6 Larry Ewing 2006-01-09 05:22:11 UTC
Looking over the discussion again I guess the easiest way to deal with this is a wrapper script for firebird that parses the mailto url and reformats it.  I don't thing the extra parameters are formally defined anywhere but regardless the gnome url stuff expects a url not a list of arguments.
Comment 7 Harish Krishnaswamy 2006-01-09 05:43:17 UTC
Evolution would start an instance if one was not running already. Else would just open a new instance of the composer window, which is what the reporter wants :-).
Comment 8 Bengt Thuree 2006-02-19 04:59:36 UTC
I think that the possibility to send a photo by email from inside F-Spot, together with the possibility to shrink it down in size (not sending 3 MB's photos if not neeeded) (bug #314559)

Would it be possible to this bug and #314559 fixed, if not perfect, then temporarily ? Unfortunately we missed the dapper train, but still...
Comment 9 Bengt Thuree 2006-02-19 05:10:03 UTC
:( Sorry, press the Save button a bit quick.
To clarify, I think the feature to be able to send a couple of photos to your friends quick and easy is a major feature for the normal user. 
Quick and Easy = F-Spot should accomodate the users email client
Couple of photos = F-Spot should offer to shrink them down, since other wise you are easily looking at mails in excess of 10MB in size.
Comment 10 Larry Ewing 2006-02-20 08:40:47 UTC
yeah but this particular problem is not something f-spot can do much about.  if thunderbird is configured by they distributor as the mailto: handler then it needs to handle the extended mailto syntax for things to work.  About the only other options I could offer are sending mail via sendmail (not something that would for for me personally) or sending mail directly via smtp through some well known server.  I went so far as to adapt the mono smtp code to support tls so that I could send mail directly to gmail, but it was slow and isn't a general solution.
Comment 11 Bengt Thuree 2006-02-20 09:48:42 UTC
Perhaps an preference option.
Using Evolution
Using Thunderbird
Using other mail client = customized string (or just use default)

I know, it is a hack until the mail clients starts to behave in a syncronized fashion.
Comment 12 Bengt Thuree 2006-05-18 02:08:44 UTC
Any news on this one?

I still think a slight hack in F-Spot to accomodate the more common mail clients.

Some preference options:
1) Use Gnome Default
2) Use Thunderbird
3) Use Evolution
4) Customized

Where the customized, you specify mail client and syntax for subject, attachments, and recipients.

This together with pushing Evolution and Thunderbird to standardise upon a nice protocol (which do not exist last I checked)
Comment 13 Stephane Delcroix 2006-07-03 14:45:20 UTC
This will *not* solve the entire discussion, but at least answer the original bug about starting multiple thunderbirds:
As I writed http://bugzilla.gnome.org/show_bug.cgi?id=314559#c23, you can create a new message inside the running thunderbird using thunderbird -remote


Comment 14 Bengt Thuree 2006-09-22 05:19:54 UTC
Is this one fixed with the wrapper script?
Comment 15 Dotan Cohen 2006-10-12 07:08:50 UTC
No, at least on KDE it opens Kmail with no attachments. For the interested, the command string for Kmail is:
kmail --body "Hi, you have pics from..." --attach /path/to/your/file.exe
Comment 16 Sascha Umlang 2007-01-07 18:37:41 UTC
Created attachment 79664 [details] [review]
email support for thunderbird, seamonkey and kmail

This is a first try to add support for thunderbird, seamonkey and kmail. Patch was written for 0.3.0. Please test/comment.
Comment 17 Stephane Delcroix 2007-01-09 12:23:41 UTC
Hi Sascha,

thanks for your patch, and the time you spend on trying the different mailers. 2 things missing in your code:
- a way to call the default mail handler as specified in gnome (mailto: urls)
- maybe a way to set it, for end users (or it could be descibed in a man page with gconftool...)

I'll look deeper at it and eventually commit to close that quite old bug
Comment 18 Sascha Umlang 2007-01-09 17:52:18 UTC
Hi Stephane,

> - a way to call the default mail handler as specified in gnome (mailto: urls)

That's the problem and as mentioned before in this discussion there is no way to call thunderbird with attachments by the mailto url. I spent hours to find some kind of hack but nothing works. So calling default mail handler will end up with a empty mail in all mailers except evolution.

> - maybe a way to set it, for end users (or it could be descibed in a man page
> with gconftool...)

I thought about that too but I don't think a end user will be capable to do this. Take a look at kmail for example. Each attachment is defined with --attach <file> and separated with a whitespace. But in thunderbird each attachment is defined with file=//<file> and separated by a comma. I don't see a way how those totally different arguments should be passed over to f-spot in a way every end user would understand. 
If you see a way to get use to it let me know and I'd be happy to code it. :)
Comment 19 Stephane Delcroix 2007-01-10 08:21:30 UTC
hi Sascha,

when I say 'a way to set it' for end users, it's a way (or a documented way) for the user to choose between the different preconfigured mailers.

just so you know, some kinds of hacks really works to start thunderbird, Ben M. wrote a script for that attached to another bug.

I'm sure the easiest solution for this issue looks like yours, but we should have one more choice, called 'default', where f-spot rely on the users settings for his gnome session.

Comment 20 Sascha Umlang 2007-01-10 18:46:03 UTC
Hi Stephane,

now I got you. How about a drop-down in the "Create Mail" window where the user can choose between the "hard coded" mailers and the gnome default mailer? I could add this to my patch.
Comment 21 Stephane Delcroix 2007-01-11 08:21:41 UTC
Sascha,

you can try in the mail dialog...
Comment 22 Stephane Delcroix 2007-01-16 13:29:11 UTC
*** Bug 388594 has been marked as a duplicate of this bug. ***
Comment 23 Stephane Delcroix 2007-01-25 09:49:07 UTC
woops, sorry.

as this honor the default gnome setting, no need for any gui in f-spot
Comment 24 Stephane Delcroix 2007-01-25 11:17:23 UTC
Created attachment 81168 [details] [review]
committed version

Here's the slightly modified version I will commit.

Even though this was not an F-Spot bug, now we have a workaround for some mailers. Tested with icedove, evolution and thunderbird.
Comment 25 Stephane Delcroix 2007-01-25 11:19:57 UTC
fixed in r2869