Seriously, Visual Studio?
Last week Pat gave a workshop about using vim as your programming text editor. In it, he mentioned that vim has branching undo; that is (hold on now, this is complicated) if you undo and start typing again, if you undo back to the same point, you can get back what you originally undid. It’s a bit Back-to-the-Future-meet-your-mother-and-your-sister-disappears, isn’t it?
If you want an understanding of what that means, you should definitely watch this video: Undo branching and Gundo.vim
Anyway, the reason I mention this is that Visual Studio does almost the opposite. It seems intentionally set up to make sure you lose as much of your work as possible. For example, I just undid some typing, but realised I wanted that back. So I hit Ctrl+Y, which isn’t quite the de facto standard for ‘Redo’, but works in most Windows applications. This was my big mistake. Ctrl+Y in Visual Studio is actually the shortcut for Yank dating back to VB6 days. The great thing about that is it’s a forward-moving action. Now undo will just un-yank the line. And now I cannot redo what I originally wanted.
What a mess! Now if you undo and redo, it will just re-yank the line. I have lost that branch of my undo history by clicking the wrong keyboard shortcut.
Now my lesson here isn’t really that it would all be better if we used vim, as branching undo history is an extremely advanced and complicated feature. The real lesson is that Visual Studio is utterly bonkers for overloading a keyboard shortcut that many would use for controlling undo history (Ctrl+Y) with something that edits your code. Bad Microsoft!
Leave a Reply