[racket] what kind of Racket editor operations would you like to see?

From: John Clements (clements at brinckerhoff.org)
Date: Mon Jul 18 11:41:31 EDT 2011

On Jul 15, 2011, at 2:36 PM, Richard Lawrence wrote:

> Hi Neil,
> 
> I am an Emacs user, but have so far stuck with DrRacket as I learn
> Racket; apologies if my suggestions are features that are already
> available in Quack/Meow.
> 
> 1. An operation that I always find myself wanting is something like
> ``wrap next sexp'' that would put parentheses around the next sexp and
> position point inside the new open-parenthesis, like so (point marked
> with `.'):
> 
> Before:
> . (some sexp goes in here)
> 
> After M-x wrap-next-sexp (or whatever key):
> (. (some sexp goes in here))
> 
> This would be extra useful with a prefix argument to wrap the next n
> sexps, like:
> 
> Before:
> . (sexp one) 'two 3
> 
> After C-u 3 M-x wrap-next-sexp:
> 
> (. (sexp one) 'two 3)

DrRacket provides this, more or less. Rather than using the C-u 4 paradigm, though, it uses the "wrap-highlighted-text" paradigm.  So, in order to wrap the next three s-expressions with parens, I'd type shift-option-right right right, then type meta-(. On my keyboard, I have automatically paired parentheses enabled, so this last keystroke is just '('.  

(Insert obligatory RSI comments regarding shift-option here).

John Clements

-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 4624 bytes
Desc: not available
URL: <http://lists.racket-lang.org/users/archive/attachments/20110718/617ced27/attachment.p7s>

Posted on the users mailing list.