case LFUN_NEWLINE_INSERT: {
InsetNewlineParams inp;
docstring arg = cmd.argument();
- // this avoids a double undo
- // FIXME: should not be needed, ideally
- if (!cur.selection())
- cur.recordUndo();
- cap::replaceSelection(cur);
if (arg == "linebreak")
inp.kind = InsetNewlineParams::LINEBREAK;
else
inp.kind = InsetNewlineParams::NEWLINE;
+ cap::replaceSelection(cur);
+ cur.recordUndo();
cur.insert(new InsetNewline(inp));
cur.posForward();
moveCursor(cur, false);
}
case LFUN_QUOTE_INSERT: {
- // this avoids a double undo
- // FIXME: should not be needed, ideally
- if (!cur.selection())
- cur.recordUndo();
cap::replaceSelection(cur);
+ cur.recordUndo();
Paragraph const & par = cur.paragraph();
pos_type pos = cur.pos();
+ // Ignore deleted text before cursor
+ while (pos > 0 && par.isDeleted(pos - 1))
+ --pos;
BufferParams const & bufparams = bv->buffer().params();
bool const hebrew =
- Allow arguments in PassThru environments (bug 7646).
+- Consider deleted text when inserting quote inset.
+
- Fix a few selection bugs in tabular (bugs 4981, 7988).
- Show the output of configure.py while the LaTeX packages are being checked