Kephra: goto (last) edit

Welcome to my musings: how editing should be (aimed to all users of an editor as food for thought). After select all I will today choose as feature of the day: goto edit (Strg+E) by which I mean jump to the location where you did the last change to the document. In latest version 0.404 I even extended the feature to make it more productive.

This feature can be implemented in 2 minutes so why even talk about it except bragging about it? If you think about editing strategically (first principles - step one - making requirements less dumb), you see that its not really about moving the caret to some position somewhere or selecting some text. Editing is ultimately an information game. How to get and organize information and apply them in the most effective way.

One little question in that game is for instance: how to get an overview which methods are in this file? Do I want an outline box on the margin, that shows me all the names with signatures or do I want a key command that folds all subroutines so I have an overview inside the edit field? I prefer the second. Even aesthetically I dislike everything that shrinks the space for the main thing (edit field) but also practically. An outline forces me to use the mouse if i want to do anything else than looking at it. Why not stay in the edit field and use all the powerful key combinations for search and and change in place. And when I'm at the wanted method why not plop - unfold all methods again and off I go? I think this style of work makes Vi(m) so powerful. But in TIMTOWTDI manner I may provide an outline anyway.

The preferred way to edit also includes going on tangents, look for information in many ways, which will include moving through the document. Already you can for instance search without the search bar - just mark the term and skip with (Shift+) F3. And it's good to be able to continue your current work after that search just by one key stroke.

But sometimes its actually more than one position you want to jump between. That is why now Strg+E now jumps to the second last edit, in case you are already at the position of the last edit. This saves you in many cases from using position marker or memorize the line number. But also makes sure Strg+E does always something potentially useful instead of nothing.

1 Comment

But in TIMTOWTDI manner I may provide an outline anyway.

I’m glad you’re considering that. The corollary of TIMTOWTDI is NEWLID: Not Everyone Works Like I Do. Also known as empathy, a too-rare trait in software development.

Leave a comment

About lichtkind

user-pic Kephra, Articles, Books, Perl, Programming