PreviousNextTracker indexSee it online !

(58/212) 178 - Retain user changes to Buffer Options after saving

Currently, buffer-local-properties are reloaded each time the buffer is saved, overriding changes made by the user using the Buffer Options dialog. See an example use case at the bottom.
I think the right behavior during save is to prevent reloading of those buffer-local-properties that were changed by the user and whose buffer-local-properties haven't changed.

Example use case: The user guide of the Tags plugin (Tags/doc/users-guide.xml) is opened in 'rest' mode due to a buffer-local-property. This mode provides no syntax coloring for me, so I manually change it to XML using the Buffer Options dialog. As soon as I save the file after making changes to it, it automatically goes back again to 'rest' mode and again I lose the syntax coloring.

Submitted nobody - 2007-10-11 13:39:16 Assigned
Priority 5 Labels core
Status open Group None
Resolution None

Comments

2007-10-12 01:27:28
daleanson

- **assigned_to**: nobody --> daleanson
- **status**: open --> closed-fixed

2007-10-12 01:27:28
daleanson

Logged In: YES
user_id=187628
Originator: NO

fixed in BufferLocal plugin, svn revision 10879.

2007-10-12 04:41:24
*anonymous

- **status**: closed-fixed --> open

2007-10-12 04:41:24
*anonymous

Logged In: YES
user_id=1477607
Originator: YES

I'm sorry, this feature request is about the behavior of the jEdit core, it has nothing to do with plugins.
The jEdit core behavior is currently not consistent: The user can change the options specified as buffer local properties using the Buffer Options dialog, but the changes are lost when the buffer is saved (not closed). If the buffer local properties should not be changed by the user, the GUI for changing them in the Buffer Options dialog should be disabled. But if the buffer local properties should be change-able by the user, then changes should be retained after the buffer is saved. It's okay to lose them after the buffer is closed, and the BufferLocal plugin fixes this behavior if the user does not like it, but as long as the buffer is open, saving should not lose these changes.

2007-10-13 15:34:08
daleanson

- **assigned_to**: daleanson --> nobody

2007-10-30 06:19:28
*anonymous

Logged In: YES
user_id=1477607
Originator: YES

The following behavior is agreed upon by: Dale, Alan, Robert and myself.
1. Global options for disabling each buffer local property. So, for example, I can disable all buffer-local "folding mode" properties. The buffer local properties are always "recommendations", not "requirements", so it is logical to enable global overrides for them.
2. The "Buffer Options" dialog should have the options whose values are provided as buffer-local-properties disabled initially, with an "Ignore" check-box to let the user override the local properties and enable the option in the dialog.