mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-12-27 06:19:36 +00:00
fix (properly) insertion of fonts/decorations around selection
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13280 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
d1ef036182
commit
786c079b89
@ -1,3 +1,8 @@
|
||||
2006-02-28 Martin Vermeer <martin.vermeer@hut.fi>
|
||||
|
||||
* cursor.C (niceInsert): fix (properly) insertion of
|
||||
fonts/decorations around selection
|
||||
|
||||
2006-02-25 Georg Baum <Georg.Baum@post.rwth-aachen.de>
|
||||
|
||||
* lyxfont.C (lyxWriteChanges): Don't write \lang latex
|
||||
|
@ -379,6 +379,8 @@ void LCursor::getPos(int & x, int & y) const
|
||||
}
|
||||
|
||||
|
||||
// Don't use this routine. It is erroneous: LFUN_PASTE should be called with
|
||||
// buffer number, not data to be inserted -- MV 26.02.2006
|
||||
void LCursor::paste(string const & data)
|
||||
{
|
||||
if (!data.empty())
|
||||
@ -712,7 +714,10 @@ void LCursor::niceInsert(MathAtom const & t)
|
||||
// be careful here: don't use 'pushLeft(t)' as this we need to
|
||||
// push the clone, not the original
|
||||
pushLeft(*nextInset());
|
||||
paste(safe);
|
||||
// We may not use niceInsert here (recursion)
|
||||
MathArray ar;
|
||||
asArray(safe, ar);
|
||||
insert(ar);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1,3 +1,8 @@
|
||||
2006-02-28 Martin Vermeer <martin.vermeer@hut.fi>
|
||||
|
||||
* math_nestinset.C (doDispatch): fix (properly) insertion of
|
||||
fonts/decorations around selection
|
||||
|
||||
2006-02-23 Jean-Marc Lasgouttes <lasgouttes@lyx.org>
|
||||
|
||||
* math_data.C (x2pos): Place cursor correctly in the case of
|
||||
|
@ -888,12 +888,6 @@ void MathNestInset::doDispatch(LCursor & cur, FuncRequest & cmd)
|
||||
int cell(0);
|
||||
if (cmd.argument == "\\root")
|
||||
cell = 1;
|
||||
// math macros are nest insets and may have 0 cells.
|
||||
// handleNest would crash in this case.
|
||||
if (ar.size() == 1 && (ar[0].nucleus()->asNestInset()) &&
|
||||
ar[0].nucleus()->nargs() > MathInset::idx_type(cell)) {
|
||||
cur.handleNest(ar[0], cell);
|
||||
} else
|
||||
cur.niceInsert(cmd.argument);
|
||||
break;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user