Bob Alvarez wrote:
I am trying to add a command to not indent a paragraph in Lyx 1.4.4. I do
this now by inserting ERT \noindent at the start of the paragraph
This works fine but it is tedious since I use this after (almost) every
equation in my paper. So, I am trying to do this with a keyboard
shortcut.
I modified cua.bind to use one of the 'Free bindings', by inserting the
following line in the file
\bind "C-y" "command-sequence ert-insert; self-insert
\noindent;"
Now when I type control-y this mostly works but it leaves me in
ert-insert
mode. What commands can I use to:
1. get out of ert-insert mode to regular text insert mode
char-forward
2. insert a space in the text after the ERT.
This seems tricky, as I can't see how just to insert a space. But this
will do:
self-insert a b; delete-backward; char-backward; delete-backward;
char-forward
So the whole thing would be:
\bind "C-y" "command-sequence ert-insert; self-insert
\noindent; char-forward; self-insert a b; delete-backward;
char-backward; delete-backward; char-forward"
Or perhaps better yet:
"command-sequence ert-insert; self-insert \noindent a;
delete-backward; next-inset-toggle"
Then you get the space inside ERT, and the inset is collapsed for you.
I'm going to finish some stuff someone else started to add alignment
LFUNs after 1.5.0 is out. If you file an enhancement request for a
paragraph-params-noalign LFUN and cc me on it, I'll make sure to add it,
too. Should be pretty trivial.
rh
TIA
Bob