mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-09 18:31:04 +00:00
* src/text3.C (doInsertInset): reset first paragraph to default after selected content has been pasted (bug 2802)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14993 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
d6cc4b9f0b
commit
a7ed5b9486
@ -274,8 +274,15 @@ bool doInsertInset(LCursor & cur, LyXText * text,
|
|||||||
if (edit)
|
if (edit)
|
||||||
inset->edit(cur, true);
|
inset->edit(cur, true);
|
||||||
|
|
||||||
if (gotsel && pastesel)
|
if (gotsel && pastesel) {
|
||||||
cur.bv().owner()->dispatch(FuncRequest(LFUN_PASTE));
|
cur.bv().owner()->dispatch(FuncRequest(LFUN_PASTE));
|
||||||
|
// reset first par to default
|
||||||
|
if (cur.lastpit() != 0 || cur.lastpos() != 0) {
|
||||||
|
LyXLayout_ptr const layout =
|
||||||
|
cur.buffer().params().getLyXTextClass().defaultLayout();
|
||||||
|
cur.text()->paragraphs().begin()->layout(layout);
|
||||||
|
}
|
||||||
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user