Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

3
  • If the start and end text is the same, I wonder if something like multiple-cursors could be tweaked to insert text simultaneously at the beginning and end of the active region. Commented Nov 13, 2014 at 19:02
  • That sounds like the manual way that the users of lesser editors are forced to do anyway. Anyway I read the use of macros as a subtext from your answer, have to say. I like your style Commented Nov 13, 2014 at 20:26
  • 1
    @progo - Thanks :) It sounds like a more manual approach, but it actually uses fewer keystrokes than your alternative. With this approach, other than the wrapping text, you only need C-x C-x. With your answer, you need to call your function (C-c something), and you also need to hit return after each entry. So no matter what you do, you've got two more keystrokes. That said, it doesn't help if you want something to call from elisp. Commented Nov 13, 2014 at 21:06