Home Download Buy Blog Forum Support

"Redo" does not scroll to change / Bad Scroll Jump on "Redo"

"Redo" does not scroll to change / Bad Scroll Jump on "Redo"

Postby CrabDude on Thu Oct 25, 2012 9:41 pm

"Redo" jumps to where your last scroll position was, not to where the change occurred.

Frequently while typing, I'll think of something and scroll to look at some code elsewhere in the file. When I'm done doing this, I'll use "Undo" to jump to what I was last doing ro remember what I was working on, and then "Redo" to redo the change and continue where I left off.

Unfortunately, b/c I had scrolled away, the "Redo" in the "Undo" => "Redo" combo, doesn't take me to where the "Redo" occurred (in this case, leaving me where I already am from the "Undo" jump), but instead to where I had scrolled away, which can be incredibly frustrating as I have no idea what the "Redo" (or the original "Undo") even does b/c either I'm not looking at it when I "Undo" or I jump away before the "Redo" is applied.
Posts: 7
Joined: Mon Feb 06, 2012 2:23 am

Re: "Redo" does not scroll to change / Bad Scroll Jump on "Redo"

Postby adzenith on Thu Oct 25, 2012 10:15 pm

Have you tried using cmd+u as a workaround? (soft undo)
Posts: 1217
Joined: Mon Oct 19, 2009 9:12 pm

Re: "Redo" does not scroll to change / Bad Scroll Jump on "Redo"

Postby CrabDude on Tue Dec 11, 2012 10:16 pm

@adzenith No dice. Does nothing different. See below. :-/

Cross-Post / Related to: viewtopic.php?f=2&t=641&p=40848#p40848

It is *maddening* to not be able to see what undo/redo are doing b/c page position / scroll is remembered, but apparently has since been updated. I think it's caused by undoing, scrolling (and clicking I think), then redo'ing. Now when you undo, it takes you to your scroll position, not the modify position and it is nearly impossible to figure out where the change is occurring...
Posts: 7
Joined: Mon Feb 06, 2012 2:23 am

Re: "Redo" does not scroll to change / Bad Scroll Jump on "Redo"

Postby slapnut on Wed Mar 13, 2013 10:30 am

This is really an important problem for me. I am glad to see someone else has this problem and I am not just crazy.

I am wondering if there is enough information available from the Python interface (which I have not looked at yet) and a enough capability to implement a custom undo/redo. Does anyone else know if this is possible?
Posts: 1
Joined: Wed Mar 13, 2013 10:21 am

Re: "Redo" does not scroll to change / Bad Scroll Jump on "Redo"

Postby unphased on Fri Apr 05, 2013 7:27 pm

I'll put in another vote on this issue as I've seen it occasionally as well, when I am traversing my undo path to get a handle on what modifications I was making on a view when I come back to it after a while. Usually git is able to help me out if I've committed recently enough but it's incredibly disorienting when the cursor is nowhere to be seen and you're left guessing and confused.

I haven't found myself in this situation enough (as I think it is a subconcious impulse to attempt not to repeat the actions that lead up to this sort of confusing and negative experience) but my guess is that a quick workaround may be to use the arrow keys after being in this state to identify and focus the cursor again, and that should also not affect the undo buffer state either.

It does not look like the undo function is exposed anywhere for us (it is not a Default package script). There is a chance that we can build a plugin which will define a command that *calls* undo and then scrolls the cursor or selection back into view. Then we can bind Super+Z/Super+Shift+Z to that instead. For some reason the scrolling being restored is incorrect and we can force it back to the position of the selection because that's what we really care about anyway, to have it scroll to wherever the cursor is (which should be following the changes).

Update: I think that this will totally not work either, because on the redo it tends to restore and scroll to the **incorrect cursor location** while the change itself is applied where it originally is (but we no longer know where the hell that is at this point). Very frustrating and I know of no hacky plugin way to achieve this short of somehow pulling out the actual change in the buffer and forcing our cursor over to that, overriding the redo functionality which is placing the cursor in the location that we had navigated to at that point in the history.
Posts: 28
Joined: Thu May 17, 2012 5:16 am

Return to Technical Support

Who is online

Users browsing this forum: No registered users and 22 guests