In LyX, is it possible to create a keyboard shortcut for inserting a LaTeX environment with some desired LaTeX code in it?

Specifically, I want to insert the TeX code: \smallskip.

What I want my shortcut to do is to open a LaTeX environment and write inside of it \smallskip.

1 Answer 1


Bind the shortcut to the following:

command-sequence ert-insert; self-insert \smallskip

To see how to find that on your own, see this answer.

  • Great, thanks a lot! That did what I wanted, and thanks for the link! Commented Apr 11, 2017 at 0:24

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .