I am having trouble figuring out how to use the text objects with the vimtex plugin. The mappings with leaders and the commands in normal and insert mode are fine. But to get environments, sections, etc. there are some bindings which i cannot figure out how to use. Specifically, the ones like

ac |(vimtex-ac)| xo

ic |(vimtex-ic)| xo

Mostly I think it is because I have no idea what modes x and o could be, (I assume n is normal, i insert) - I have not been able to find any explanatation of this elsewhere. I assume its something obvious that is just escaping me.


1 Answer 1


I think you do not really understand what a text object is. I therefore recommend that you read :h text-objects. When you have read and understood this, you should be able to understand the vimtex text object mappings.

The vimtex documentation does list all the default mappings with a mode indicator. The ac and ic mappings are indicated with xo, which implies visual mode (x) and operator pending mode (o). This means the mapping is available in visual mode and in operator pending mode. An example: vac will select the entire command under the cursor and dac will delete it. In the first example, v first starts visual mode, and in the latter example, d is an operator and "starts" the operator pending mode.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.