mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-05 13:26:21 +00:00
2003-05-01 Lars Gullik Bj�nnes <larsbj@gullik.net>
* CutAndPaste.C (pasteSelection): remove some unneeded code. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@6908 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
717121eba6
commit
107c91ace9
@ -1,8 +1,13 @@
|
||||
2003-05-01 Lars Gullik Bjønnes <larsbj@gullik.net>
|
||||
|
||||
* CutAndPaste.C (pasteSelection): remove some unneeded code.
|
||||
|
||||
2003-05-01 Lars Gullik Bjønnes <larsbj@gullik.net>
|
||||
|
||||
* CutAndPaste.C (resetOwnerAndChanges): new helper functor
|
||||
(copySelection): clean up a bit.
|
||||
(pasteSelection): use make_pair
|
||||
(pasteSelection): remove some unneeded code.
|
||||
|
||||
* ParagraphList.C (ParagraphList): implement copy constructor
|
||||
(operator=): implement, base on copy constructor.
|
||||
|
@ -218,9 +218,6 @@ CutAndPaste::pasteSelection(ParagraphList & pars,
|
||||
// new environment and set also another font if that is required
|
||||
ParagraphList::iterator tmpbuf = paragraphs.begin();
|
||||
int depth_delta = pit->params().depth() - tmpbuf->params().depth();
|
||||
// Temporary set *par as previous of tmpbuf as we might have
|
||||
// to realize the font.
|
||||
tmpbuf->previous(&*pit);
|
||||
|
||||
// make sure there is no class difference
|
||||
#warning current_view used here
|
||||
@ -253,7 +250,11 @@ CutAndPaste::pasteSelection(ParagraphList & pars,
|
||||
tmpbuf->erase(i--);
|
||||
}
|
||||
} else {
|
||||
#if 0
|
||||
LyXFont f1 = tmpbuf->getFont(current_view->buffer()->params, i, outerFont(tmpbuf, pars));
|
||||
#else
|
||||
LyXFont f1 = tmpbuf->getFont(current_view->buffer()->params, i, outerFont(pit, pars));
|
||||
#endif
|
||||
LyXFont f2 = f1;
|
||||
if (!pit->checkInsertChar(f1)) {
|
||||
tmpbuf->erase(i--);
|
||||
@ -264,9 +265,6 @@ CutAndPaste::pasteSelection(ParagraphList & pars,
|
||||
}
|
||||
}
|
||||
|
||||
// now reset it to 0
|
||||
paragraphs.begin()->previous(0);
|
||||
|
||||
// make the buf exactly the same layout than
|
||||
// the cursor paragraph
|
||||
paragraphs.begin()->makeSameLayout(*pit);
|
||||
@ -283,7 +281,7 @@ CutAndPaste::pasteSelection(ParagraphList & pars,
|
||||
// if necessary
|
||||
if (pit->size() > pos || !pit->next()) {
|
||||
breakParagraphConservative(current_view->buffer()->params,
|
||||
pars, &*pit, pos);
|
||||
pars, pit, pos);
|
||||
paste_the_end = true;
|
||||
}
|
||||
// set the end for redoing later
|
||||
|
Loading…
Reference in New Issue
Block a user