Bug 209194

Summary: KMail composer does not pass temp file name to external editor
Product: [Applications] kmail Reporter: Christoph Lange <langec>
Component: generalAssignee: kdepim bugs <kdepim-bugs>
Status: RESOLVED DUPLICATE    
Severity: normal    
Priority: NOR    
Version: 1.12.1   
Target Milestone: ---   
Platform: unspecified   
OS: Linux   
Latest Commit: Version Fixed In:
Attachments: Workaround that opens the most recent temp file in an editor

Description Christoph Lange 2009-10-02 11:47:59 UTC
Version:           1.12.1 (using 4.3.1 (KDE 4.3.1), Gentoo)
Compiler:          x86_64-pc-linux-gnu-gcc
OS:                Linux (x86_64) release 2.6.28-thinkpad-r2

I have an external editor set up for the KMail composer.  It is no longer invoked properly, so effectively I'm no longer able to use it.  I think this is not related to the 4.3.0 -> 4.3.1 update, but it only occurred later.

When I press some key in the composer window, a temp file /tmp/kde-USERNAME/kmail*.tmp is created, but its name is no longer passed to the external editor application.  I did give the %f in the command line, but it is not replaced by the name of the file.

I will attach a workaround -- a script that opens my favorite editor with the file obtained as an argument, or otherwise, the most recent /tmp/kde-USERNAME/kmail*.tmp.
Comment 1 Christoph Lange 2009-10-02 11:53:06 UTC
Created attachment 37323 [details]
Workaround that opens the most recent temp file in an editor
Comment 2 Christoph Lange 2009-10-02 12:07:17 UTC
I found out that actually KMail replaces %f by the empty string, i.e. the external editor is called with one argument, which is empty.
Comment 3 Christoph Lange 2009-10-02 15:34:50 UTC
I realized that the "workaround" is useless, because something is broken inside KMail.  The "workaround" opens the right temp file in the external editor, but when closing the external editor, KMail doesn't reload the composer window from the temp file.  So this is actually a duplicate of bug 206491.

*** This bug has been marked as a duplicate of bug 206491 ***