# How do I create cursors around a selection?

**URL:** <https://discuss.kakoune.com/t/how-do-i-create-cursors-around-a-selection/1440>\
**Category:** Help\
**Created:** [December 20, 2020, 4:05pm UTC](https://discuss.kakoune.com/t/how-do-i-create-cursors-around-a-selection/1440 "2020-12-20T16:05:55Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![todd](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/todd/32/746_2.png) [@todd](https://discuss.kakoune.com/u/todd)\
**Post date:** [December 20, 2020, 4:05pm UTC](https://discuss.kakoune.com/t/how-do-i-create-cursors-around-a-selection/1440/1 "2020-12-20T16:05:55Z")

</div>

Let’s say I have code that looks like this:

```
echo hello world

```

Lets say that I highlight/select the `hello world` part. How do I then put two cursors like this?

```
echo hello world
     ^ ^

```

That way all I have to do is `i"<esc>` and I’ll end up with:

```
echo "hello world"

```

If I use `<a-S>i"<esc>` then I’ll end up with _almost_ what I want:

```
echo "hello worl"d

```

Edit: fixing typo  
Edit: adding with `<a-S>` doesn’t work for this

---

<div class="post-metadata">

**Author:** ![eyepatchOwl](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/eyepatchowl/32/735_2.png) [@eyepatchOwl](https://discuss.kakoune.com/u/eyepatchOwl)\
**Post date:** [December 20, 2020, 4:46pm UTC](https://discuss.kakoune.com/t/how-do-i-create-cursors-around-a-selection/1440/2 "2020-12-20T16:46:29Z")

</div>

Did you know that you can use a to append to the end of a selection? This comes in handy with a comma separated list because you can split to select each item and quote them simultaneously. Or use different text for begin and end like braces.

---

<div class="post-metadata">

**Author:** ![todd](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/todd/32/746_2.png) [@todd](https://discuss.kakoune.com/u/todd)\
**Post date:** [December 20, 2020, 5:11pm UTC](https://discuss.kakoune.com/t/how-do-i-create-cursors-around-a-selection/1440/3 "2020-12-20T17:11:54Z")

</div>

> [@eyepatchOwl](#):
>
> Did you know that you can use a to append to the end of a selection?

Yep! This is pretty nifty for the reasons you mentioned. What I’m really curious is for a behavior almost like what `<a-S>` does. I’ll update my main post to explain why `<a-S>` doesn’t work.

---

<div class="post-metadata">

**Author:** ![tototest99](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/tototest99/32/629_2.png) [@tototest99](https://discuss.kakoune.com/u/tototest99)\
**Post date:** [December 20, 2020, 5:22pm UTC](https://discuss.kakoune.com/t/how-do-i-create-cursors-around-a-selection/1440/4 "2020-12-20T17:22:23Z")

</div>

You were almost there:  
`exec -draft L <a-S> i '"' <esc>`  
For surround-like plugins search `kak mirror` or `kak surround` on github.
