Bug: Hiding sidebar changes scroll position
CompletedTo reproduce:
1. Open a long document and scroll to the middle of it
2. Choose "Toggle File List" (⌘⇧F)
Results: scroll position of document changes
-
Can you verify that this is resolved if you turn off animations? (General Preferences->Appearance->Animate layout changes)
Thanks!
0 -
Still occurs for me.
0 -
Long story short.... There seems to be some conflict between Auto Layout, NSSplitview, animation, and NSTextView/NSScrollview. Basically, I seem to be able to get it to work correctly with any 3 of these 4 elements.
And, at least in my case, the problem specifically occurs with nested splitviews, where the outer split changes size, causing the inner split to change size, causing the embedded Text/Scrollview to change size.
I dug around with a bunch of attempts to fix, and ultimately I don't think it's worth the effort. So I disabled animations when toggling the notes list, which *as best as I can tell* fixes the problem. Animations are still allowed when toggling the preview, because it seems that this does not cause the issue.
This fix is not in today's release, but will be in the next release after we test a couple of other new features.
0 -
❤️
0 -
See if you still have trouble with today's release.
0 -
Fletcher, thanks for all the effort. It is definitely better. Before it jumped around all over the place and seemed to get worse after multiple toggles.
Now it still jumps up and down a few lines with every toggle, but it is at least consistent. I can record a screencast if that would be helpful.
0 -
Send me a screencast so I can see exactly what you're describing.
Do remember that depending on your line lengths, the actual height of the textview is going to change. Depending on where you are, the lines are going to change and something has to give.
0 -
Here you go https://imgur.com/a/7MDo0x5
0 -
This is unrelated to the issue I was working on (and discussed in the other thread.) What you specifically are describing isn't really a bug per se, and will probably not be "fixed."
When the available width of the textview changes, everything changes resulting in lines moving up or down depending on line length, window width, etc.
Setting a fixed line length keeps the text width the same, but the textview still changes. Presumably, the calculations that the textview does to predict where to center the cursor are no longer valid, since the expectations about line breaks are different.
If this is important to you, you can use typewriter mode to force the cursor to be in the middle of the screen at all times, or disable the fixed line length functionality, or turn on Auto Zoom.
0 -
Got it. Thanks!
0
Please sign in to leave a comment.
Comments
10 comments