On 5/05/2024 9:52 am, Richard Kimberly Heck wrote:
On 5/4/24 15:03, matan guedj wrote:
I want to add a shortcut that will open a preview environment and inside it opens an ert environment and "insert-preview insert-ert" and "\insert-preview \insert-ert" aren't working, so I don't know if it's a syntax error or something more fundamental here.

You need to use the command-sequence LFUN to do this. It just tells LyX that you are going to give a series of commands. Otehrwise, it interprets everything as one command. So something like:

command-sequence insert-preview; insert-ert

Riki

Riki, I believe this is called a "thinko". It should be:

 command-sequence preview-insert; ert-insert

I've considered a shortcut for this sequence but prefer to insert the insets separately using  Ctrl+P to insert the preview inset and the LyX supplied Ctrl+L to  insert an ert inset. That way I can select text or a table and simply tap Ctrl+P to wrap it in a preview inset and see (after a pause) the result. If I want an ert inset inside a preview inset then I hold down the Ctrl key and tap P then L (which are diagonally adjacent on my keyboard).

Andrew

--
lyx-users mailing list
lyx-users@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-users

Reply via email to