Settings in file A propogate to file B when editing A and B is opened.

Bug #1286909 reported by SegundoBob
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
leo-editor
Fix Released
Undecided
Unassigned

Bug Description

When I'm editing Leo-Editor file A and I open Leo-Editor file B, it seems wrong that the settings in file A affect the editing of file B. My conclusion is based on the documentation:

http://leoeditor.com/customizing.html?highlight=settings#id3

But I understand that I've described a complex scenario not explicitly addressed by the documentation. That is, the same Leo-Editor session is used to edit both file A and file B.

I don't know how many settings are involved. I have only investigated custom menu settings.

The settings that caused me to notice this were menu definitions. I note that the menus are in the file tab. Hence, visually it appears that the problem is not that the whole session has only one set of menus. In fact, file A never has duplicated menu items even when file B has duplicated menu items.

Mystery: The duplicated menu items sometimes disppear leaving just one instance of each menu item. I have not discovered what causes this.

Attached to this bug report is a simple test case settingsCreep01.leo. I will be attaching this same test case to two additional bugs.

Please begin by copying settingsCreep01.leo twice to create settingsCreep02.leo and settingsCreep03.leo.

I suggest the following tests:

Test 1:

Open settingsCreep01.leo. Note that it defines menu "Bugs" which contains two items.

Ctrl-O (open) settingsCreep02.leo

Note the warning message:

menu already exists: B&ugs

Note that the "Bugs' menu has 4 items (2-items repeated twice).

Ctrl-O (open) settingsCreep03.leo

Note the 2 warning messages:

menu already exists: B&ugs
menu already exists: B&ugs

Note that the "Bugs' menu has 6 items (2-items repeated 3 times).

Test 2:

Open settingsCreep01.leo. Note that it defines menu "Bugs" which contains two items.

Ctrl-O (open) settingsCreep02.leo

Note the warning message:

menu already exists: B&ugs

Note that the "Bugs' menu has 4 items (2-items repeated twice).

Alt-F, c, carriage-return (close settingsCreep02.leo)

Ctrl-O (open) settingsCreep02.leo

Note the 2 warning messages:

menu already exists: B&ugs
menu already exists: B&ugs

Note that the "Bugs' menu has 6 items (2-items repeated 3 times).

This is bad. This means that some memory of the menus of the previous open of settingsCreep02.leo hangs around after settingsCreep02.leo is closed.

Test System:
Xubuntu64 13.10
Leo Log Window
Leo 4.11 final, build 128f96dcd70d (branch: master), 2014-03-02 13:11:09
Python 2.7.5, qt version 4.8.4
linux2
setting leoID from os.getenv('USER'): 'bob06'
load dir: /home/ldi/git/leo-editor/leo/core
global config dir: /home/ldi/git/leo-editor/leo/config
home dir: /home/bob06
reading settings in /home/ldi/git/leo-editor/leo/config/leoSettings.leo
docutils loaded
reading settings in /home/bob06/.leo/myLeoSettings.leo
Found /help
Abbreviations off
reading settings in /home/ldi/tmp/settingsCreep01.leo
Found /help
Abbreviations off
reading: /home/ldi/tmp/settingsCreep01.leo

Revision history for this message
SegundoBob (bhossley) wrote :
Revision history for this message
Edward K. Ream (edreamleo) wrote :
Changed in leo-editor:
status: New → Fix Released
Revision history for this message
Edward K. Ream (edreamleo) wrote :

> When I'm editing Leo-Editor file A and I open Leo-Editor file B, it seems wrong that the settings in file A affect the editing of file B.

It may seem wrong, but this is the way Leo works and it won't change.

When opening a file F, the settings for file F are *merged* with all previous settings. So if you want to be *sure* that F contains particular settings, you must define them in F.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.