There are default settings loaded when you first open prefs. After that, the prefs saved in the project are loaded. What the template functionality will do is allow you to import a set of prefs to avoid having to set them manually, as you initially mentioned. Once they're imported, they're saved in the project and loaded from there on subsequent occasions.
This needs to be thought out carefully. At the moment 3 different sets of prefs can be active at various points:
1 - The default prefs (active when no previously used project has been opened and no settings template loaded). All settings involved.
2 - The user prefs (active when the user has loaded a settings template or edited the defaults). All editable settings involved.
3 - A project prefs (active when the user has loaded a previously saved project). All except global settings involved.
Based on the current structure, this is how I imagine most users will expect the preferences to work in various cases:
** Case 1 - I have just installed CB, or just activated DoxyBlocks, no template has ever been saved:
- New project:
When I start a new project the default prefs (1) are active. They offer the most common choices and will work OK on most systems.
- Existing project:
When I load an existing project, the project DoxyBlocks settings (3) become active, overriding all except global settings.
** Case 2 - I have used DoxyBlocks for a while and saved my preferences into a template:
- New project:
When I start a new project the user prefs (2) from the template are active. They are my choices and I don't want to have to manually load them at each new project.
- Existing project:
When I load an existing project, the project DoxyBlocks settings (3) become active, overriding all except global settings.
With the "Load settings" option I can override the project settings with the template settings if I want.
** In all cases:
I can edit the preferences and save them to the user prefs template at any time. All current preferences except global preferences are saved to the project.
-------------------------------
In light of this:
- Load settings issue:
Note that in the above scenarios I have indeed found a usage for the "Load settings" option in Case 2, Existing project (if we keep the current structure with project prefs - see below.).
- No loading of user prefs on startup:
You seem to have a different scenario in mind for Case 2, new project, one that would force a user to manually load their chosen settings from template every time a new project is started.
Are you sure requiring this repetitive manual loading is needed? Is the automatic loading of user preferences on startup hard to do?
- Getting rid of project prefs:
Is the saving of DoxyBlocks project prefs in projects and loading of these preferences from projects really useful? What would be the cost of simply getting rid of project prefs? If the costs are not great, being able to simplify the prefs this way could be worth doing.
-------------------
For Later:
When we have discussed this, we will have to examine what happens when a new project is started after an existing one, or when several projects are concurrently in memory. These are issues that disappear if we get rid of project prefs.