[TxMt] Select pasted text

Charilaos Skiadas skiadas at hanover.edu
Sat Feb 24 16:17:45 UTC 2007


On Feb 24, 2007, at 10:48 AM, Nigel Chapman wrote:
> I often find that I paste something into a document, then  
> immediately select it to do something to it, like wrapping it in  
> tags or converting characters to entities. Long ago I used an  
> editor (possibly alpha) that had a 'select pasted text' command,  
> that did the selection straight after a paste, without having to  
> drag over it or whatever. I can't find an equivalent command in  
> TextMate, nor any environment variables pointing to the start and  
> end of the latest pasting that would let me implement it myself.
>
> Have I missed something? Either a command in some bundle I don't  
> know about or some other way of achieving the same effect?
>
No you haven't missed anything. Once the text is pasted, that's it,  
it's now part of the document.
I suppose what I would do is probably open a new file and paste the  
thing there, then Select All and do what I want with it. Since I  
don't have the need for that too often, I guess the extra couple of  
keystrokes are not a big problem. I suppose if you find that you  
repeat the exact same command to the pasted text, then it might be  
worth it writing a command to do what you want and take into account  
the text in the pasteboard.

Of course for the "wrapping in tags" thing, I would first create the  
tags and then paste the text inside them ;). I convert characters to  
entities so rarely that I don't even know the shortcut for it ;)

> If not, here's a feature request. Any one of the following:
>
> Select Pasted Text command
> Paste and Select command (extra modifier key on cmd-V)
> Select after Pasting preference.
>
> Thanks for any help or pointers.

Haris Skiadas
Department of Mathematics and Computer Science
Hanover College







More information about the textmate mailing list