[TxMt] Re: Some text-navigation/selection questions or requests
Allan Odgaard
mailinglist at textmate.org
Mon Mar 12 13:14:51 UTC 2012
On 06/03/2012, at 04.02, Jacob Bandes-Storch wrote:
> […]
> - When I have a range selected, I'd like a way to create two carets: one at the beginning of the selected range and one at the end.
It might help to let us know what the end goal is, i.e. help either to suggest how it can be achieved differently or help understand why this feature is useful and how it could be implemented (just adding a bunch of new key equivalents for special actions tends to just increase complexity with no-one able to learn all the keys).
> (A more keyboard-centric way of managing multiple carets in general would be great, too, but I think this would be a good start.)
Have you read http://blog.macromates.com/2011/multiple-carets/? There are dozens of ways to obtaining multiple carets from the keyboard.
> - I'd like a more definitive way to select the next-higher code block, tag, etc.; ctrl-opt-B and shift-cmd-B are useful in some cases but the latter is limited in use and sometimes the former just selects the whole document because of the way things are scoped.
I partially extended this with the new control-[shift] up/down which uses the typing pairs which in 2.0 can be strings (and planned to be patterns) — it’s not ideal, but I haven’t found a good way to generalize this. I.e. I am aware of the desire, but not how to go about actually implementing it in a good flexible/configurable way.
> - With multiple selections or a selected range, pressing the up arrow key will put a single caret one line above the first selection/caret, and pressing down goes one line below the last one or the end. It would be nice to have a way to move up from the last line or down from the first line. (Perhaps a modifier to choose beginning/end and then the arrow key can dictate only which direction to move).
What you can do is something like ⌘⇠ + ⇠ to go to BOL and then left or same for EOL and then right. The few times I’ve needed to move the carets up/down, this gesture seems to be ideal because it anchors the carets at the begin/end of the lines.
If this does not fit your use-patterns, please elaborate with examples.
More information about the textmate
mailing list