On Wed, 19 May 2010 23:05:26 +0200% Enrico Tröger enrico.troeger@uvena.de wrote:
On Wed, 19 May 2010 22:13:40 +0400, Eugene wrote:
On Wed, 19 May 2010 14:09:57 +0300% Dimitar Zhekov hamster@mbox.contact.bg wrote:
On Wed, 19 May 2010 11:07:09 +0400 Eugene Arshinov earshinov@gmail.com wrote:
Now committed, together with "Tools > Save configuration" menu item.
I hope "Save configuration" works for all instances, and not for the "main" instance only, as someone suggested. With "main", the options can be saved by "Edit -> Preferences -> OK" anyway, and I would like to be able to save them from a secondary instance, and run a new Geany with them.
Preference -> OK is a good point… I did not know it saves configuration file immediately (yeah, again). Seems that it makes "Save configuration" unnecessary (at least, for main instance).
I am against enabling "Save configuration" for secondary instances because (in case of current behaviour when the main instance saves configuration automatically on exit) it may confuse users. Suppose you have main instance and secondary instance running. You change preferences in the secondary instance and use "Save configuration", then restart the main instance in order to make it apply new settings… and when the main instance is closing it silently overwrites them. So I thinks it's reasonable to force users to change their preferences in main instance only.
Or, as another option, we can remove automatic saving of preferences when closing. As preferences are saved immediately after Preferences dialog is closed, this option wouldn't do any harm. Or would it?
The historical reason for save on exit was to store window size and position and maybe other things (scribble content, maybe more). So, we still need to save on exit but maybe we can lower the amount of settings we want to save on exit, only those which are really necessary.
(this is also a reply to Dimitar)
Well, then it's not a big deal to only save_dialog_prefs() after the Preferences dialog is closed and save everything but dialog prefs (UI prefs, session etc.) on exit. That is logical and will solve the problem.
Also, it is safe and reasonable to save preferences (and only them) after the dialog is closed even in secondary instances. Then "Save Configuration" won't be needed, unless someone expects this menu item to also save UI prefs, opened files and other things (which is a bad idea).
Best regards, Eugene.