# Is it normal that kakoune expects me to use its default mapping while in the \`map\` command?

**URL:** <https://discuss.kakoune.com/t/is-it-normal-that-kakoune-expects-me-to-use-its-default-mapping-while-in-the-map-command/2305>\
**Category:** Help\
**Created:** [October 7, 2023, 6:21pm UTC](https://discuss.kakoune.com/t/is-it-normal-that-kakoune-expects-me-to-use-its-default-mapping-while-in-the-map-command/2305 "2023-10-07T18:21:56Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Nasmekva](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/nasmekva/32/1238_2.png) [@Nasmekva](https://discuss.kakoune.com/u/Nasmekva)\
**Post date:** [October 7, 2023, 6:21pm UTC](https://discuss.kakoune.com/t/is-it-normal-that-kakoune-expects-me-to-use-its-default-mapping-while-in-the-map-command/2305/1 "2023-10-07T18:21:56Z")

</div>

Hi !

I loved @kkga suggestion (which can be found [here](https://discuss.kakoune.com/t/you-probably-dont-need-x-and-x-altogether/1888/2)) of using :

- `v` → `<a-i>`
- `<s-v>` → `<a-a>`
- `<a-v>` → `v`
- `<a-V>` → `<s-v>`

So I added it to my configuration. Now, that works great and all, no issue.  
My problem arise when I tried to center the view after a `<c-d>/<c-u>`.

Using the following command, `map global normal <c-d> <c-d><a-v>v`, does not work and only result in the view info menu opening after I have gone a half page down/up.  
I have to use the kakoune’s defaults for it to work as expected `map global normal <c-d> <c-d>vv`.

Is that normal and how it’s supposed to work ? I couldn’t find any reference to this particularity in the [mapping documentation](https://github.com/mawww/kakoune/blob/master/doc/pages/mapping.asciidoc).

---

<div class="post-metadata">

**Author:** ![Screwtapello](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/screwtapello/32/12_2.png) [@Screwtapello](https://discuss.kakoune.com/u/Screwtapello)\
**Post date:** [October 8, 2023, 1:58am UTC](https://discuss.kakoune.com/t/is-it-normal-that-kakoune-expects-me-to-use-its-default-mapping-while-in-the-map-command/2305/2 "2023-10-08T01:58:18Z")

</div>

Yes, this is how it’s supposed to work. In the Kakoune “language”, `vv` means “scroll the buffer so the main cursor is vertically centred”, and it always means that even if there are custom mappings. That way, scripts and plugins can use `vv` to centre the cursor without worrying whether the user has remapped those keys to some other thing.

You’re right that this is not clearly mentioned in the mapping documentation. I expected there to be a switch to say “no, really, please call existing mappings” but I was actually thinking of `execute-keys -with-maps` which is related but nobody learning about mappings would look there.

---

<div class="post-metadata">

**Author:** ![Nasmekva](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/nasmekva/32/1238_2.png) [@Nasmekva](https://discuss.kakoune.com/u/Nasmekva)\
**Post date:** [October 9, 2023, 7:00am UTC](https://discuss.kakoune.com/t/is-it-normal-that-kakoune-expects-me-to-use-its-default-mapping-while-in-the-map-command/2305/3 "2023-10-09T07:00:23Z")

</div>

> That way, scripts and plugins can use `vv` to centre the cursor without worrying whether the user has remapped those keys to some other thing.

Yes, that makes sense. Thank you!

> You’re right that this is not clearly mentioned in the mapping documentation.

Might create a pull request to address the issue to be honest, will make newcomer’s life easier 😊

> `execute-keys -with-maps`

That’s neat!

---

<div class="post-metadata">

**Author:** ![Screwtapello](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/screwtapello/32/12_2.png) [@Screwtapello](https://discuss.kakoune.com/u/Screwtapello)\
**Post date:** [October 9, 2023, 7:24am UTC](https://discuss.kakoune.com/t/is-it-normal-that-kakoune-expects-me-to-use-its-default-mapping-while-in-the-map-command/2305/4 "2023-10-09T07:24:01Z")

</div>

> [@Nasmekva](#):
>
> Might create a pull request to address the issue to be honest, will make newcomer’s life easier 😊

I beat you to it! 🙂

> <https://github.com/mawww/kakoune/pull/4996>
>
> This came up in \[the Kakoune forums\](https://discuss.kakoune.com/t/is-it-normal-…that-kakoune-expects-me-to-use-its-default-mapping-while-in-the-map-command/2305/2).
