]> git.lyx.org Git - lyx.git/blobdiff - src/text2.C
The "I want this in now" patch.
[lyx.git] / src / text2.C
index 92939fcae503430b8c712880bd288a5751bae442..b34bc99063387b290b7db708cca0ebeefd0ff9ba 100644 (file)
@@ -19,6 +19,7 @@
 #include "undo_funcs.h"
 #include "buffer.h"
 #include "bufferparams.h"
+#include "errorlist.h"
 #include "gettext.h"
 #include "BufferView.h"
 #include "CutAndPaste.h"
@@ -426,10 +427,10 @@ LyXText::setLayout(LyXCursor & cur, LyXCursor & sstart_cur,
 // set layout over selection and make a total rebreak of those paragraphs
 void LyXText::setLayout(string const & layout)
 {
-       LyXCursor tmpcursor = cursor;  // store the current cursor 
+       LyXCursor tmpcursor = cursor;  // store the current cursor
 
        // if there is no selection just set the layout
-       // of the current paragraph 
+       // of the current paragraph
        if (!selection.set()) {
                selection.start = cursor;  // dummy selection
                selection.end = cursor;
@@ -1406,10 +1407,15 @@ void LyXText::pasteSelection()
        ParagraphList::iterator endpit;
        PitPosPair ppp;
 
+       ErrorList el;
+
        boost::tie(ppp, endpit) =
                CutAndPaste::pasteSelection(ownerParagraphs(),
                                            cursor.par(), cursor.pos(),
-                                           bv()->buffer()->params.textclass);
+                                           bv()->buffer()->params.textclass,
+                                           el);
+       bv()->setErrorList(el);
+       bv()->showErrorList(_("Paste"));
 
        redoParagraphs(cursor, endpit);