OS X Leo loses track of focused .leo file and/or focused node tree

74 views
Skip to first unread message

TEK42

unread,
Apr 18, 2021, 5:53:58 PM4/18/21
to leo-editor
I finally got around to installing Leo on a Windows machine so that I can compare it against some behavior I have experienced in OS X.

The main troublesome but intermittent issue on OS X is that when I have multiple outlines open in Leo, it sometimes acts on the wrong Node tree. For instance, there are times when I am trying to insert a child node on the outline I am working on and it appears to be doing nothing at all, but inspecting another Outline (opened but not the active tab) I find that the "failed" child node inserts are all present there. What is worse, closing the "other" outline does not fix the focus problem and no Node operations succeed until I restart Leo - further many times after closing the "other" Outline, when I save the focused (still open) Outline, the log says, "saved: [closed-file].leo" 

The above has been very difficult to reproduce deliberately, but I have found a way to reproduce consistently a behavior that might be related. This is in no way a critique of the Viewrendered plugin, but I have found that when I have two Outlines open with content that I can use the viewrendered plugin on, in OS X it gets "sticky" and the viewrendered menu actions (e.g. "vr" or "vr-toggle") will only work on one of the Outlines regardless of which one currently has focus. And if I close he Outline that has the "sticky" viewrendered actions, they still will not work on the open Outline. On Windows this behavior is not present.

Perhaps this reproducible behavior may provide some clues to the source of the problem, I suspect it has much to do with the different way OS X and Windows consider Apps/Menus/Windows. 

Any suggestions on where to begin to look into the code to track down this issue with OSX would be much appreciated. Or perhaps this qualifies as a bug?

I may try a Linux (Ubuntu) install to see if I can reproduce the behavior there - I suspect Leo will behave more like Windows than OS X in that installation.

-TK

TEK42

unread,
Apr 18, 2021, 7:41:27 PM4/18/21
to leo-editor
Follow-up after installing Leo to Ubuntu.

Leo behaves as it does in Windows as far as I can tell. No “sticky” outlines/nodes and Viewrendered works as expected .

I am confident that the strange behaviors are with OS X only.

-TK

tbp1...@gmail.com

unread,
Apr 18, 2021, 7:55:19 PM4/18/21
to leo-editor
Would you check one thing about this?  When the VR pane is opened, it will probably capture the focus, but that would not be visible.  If the focus were to get placed back way from the VR pane, say the body or outline tree, the Close command might work again.  And would you be so good to try the same thing with the ViewRendered3 plugin?  They are similar but not identical.

TEK42

unread,
Apr 19, 2021, 9:38:45 AM4/19/21
to leo-editor
I tested both Viewrendered and Viewrendered3 (had a couple rendering issues w/ VR3 but I’ll save those for another thread), and the behavior is the same for both as far as the stickiness goes. 

Whichever Outline is the most recently opened gets the focus no matter what. I can click around to change focus to any other pane (body, outline, log) in any of the open outlines, but when I perform a VR plug-in action it always switches to the most recently opened outline and does the action there.

Worse even is that when I close the most recently opened outline, all actions “do nothing” (like they still want to occur on the closed outline - my speculation) and I have to close Leo to get back to normal.

None of the above happens on either Windows or Ubuntu installs.

tbp1...@gmail.com

unread,
Apr 19, 2021, 9:51:46 AM4/19/21
to leo-editor
It does sound like a QT-on-Mac problem, all right.  I don't have access to a Mac to look into it, though.

Edward K. Ream

unread,
Apr 19, 2021, 9:58:08 AM4/19/21
to leo-editor
On Mon, Apr 19, 2021 at 8:38 AM TEK42 <kizz...@gmail.com> wrote:
I tested both Viewrendered and Viewrendered3 (had a couple rendering issues w/ VR3 but I’ll save those for another thread), and the behavior is the same for both as far as the stickiness goes. 

Whichever Outline is the most recently opened gets the focus no matter what. I can click around to change focus to any other pane (body, outline, log) in any of the open outlines, but when I perform a VR plug-in action it always switches to the most recently opened outline and does the action there.

Worse even is that when I close the most recently opened outline, all actions “do nothing” (like they still want to occur on the closed outline - my speculation) and I have to close Leo to get back to normal.

None of the above happens on either Windows or Ubuntu installs.

Thanks for your investigations. Please file a Leo bug report.

Edward
Reply all
Reply to author
Forward
0 new messages