Zim

Tools|Edit Source does not edit the current file, but a temporary file

Asked by Stefan Pantschitz

I am happily using zim 0.27 (Ubuntu 8.10) since about two weeks.
I don't understand the purpose of the menu item Tools|Edit Source.

A copy of the current file will be created in the /tmp directory.
The configured editor will open the newly created file.
Any changes made to this file will not be reflected in the original file.

If you switch to a different document in zim and use Select Menu|Tools|Edit Source again, the file in the /tmp directory will be overwritten.

I expected to edit the source of the original document by the configured text editor.
I expected to see the changes made to the file (after saving the file with the text editor) in zim (possibly after selecting View|Reload).

Question information

Language:
English Edit question
Status:
Solved
For:
Zim Edit question
Assignee:
No assignee Edit question
Solved by:
Jaap Karssenberg
Solved:
Last query:
Last reply:
Revision history for this message
Best Jaap Karssenberg (jaap.karssenberg) said :
#1

Which editor did you configure ?

Zim actually reloads the content of the tmp file after the editor process exits. However some editors (e.g. gvim) first fork the process before opening the tmp file. In this case zim thinks the editor is already finished. In case of gvim you need to pass the "--nofork" command line option.

Things are working correctly when the zim window "hangs" while the editor is open. This means zim is correctly waiting for the editor to finish. If zim is responsive it thinks the editor already finished.

Revision history for this message
Stefan Pantschitz (stefan-pantschitz) said :
#2

Thank you very much for helping me so quickly,
gvim and zim work nicely together now.

If you have loaded more than one document in your editor, you just have to close the entire application.