4 * This file is part of LyX, the document processor.
5 * Licence details can be found in the file COPYING.
7 * \author Juergen Vigna
8 * \author Lars Gullik Bjønnes
9 * \author Alfredo Braunstein
11 * Full author contact details are available in file CREDITS.
17 #include "support/types.h"
18 #include "ParagraphList.h"
28 namespace CutAndPaste {
32 CutAndPaste::availableSelections(Buffer const & buffer);
35 PitPosPair cutSelection(BufferParams const & params,
37 ParagraphList::iterator startpit,
38 ParagraphList::iterator endpit,
39 int start, int end, lyx::textclass_type tc,
40 bool doclear = false);
42 PitPosPair eraseSelection(BufferParams const & params,
44 ParagraphList::iterator startpit,
45 ParagraphList::iterator endpit,
46 int start, int end, bool doclear = false);
48 bool copySelection(ParagraphList::iterator startpit,
49 ParagraphList::iterator endpit,
50 int start, int end, lyx::textclass_type tc);
52 std::pair<PitPosPair, ParagraphList::iterator>
53 pasteSelection(Buffer const & buffer,
55 ParagraphList::iterator pit, int pos,
56 lyx::textclass_type tc, ErrorList &);
59 std::pair<PitPosPair, ParagraphList::iterator>
60 pasteSelection(Buffer const & buffer,
62 ParagraphList::iterator pit, int pos,
63 lyx::textclass_type tc,
64 size_t cuts_indexm, ErrorList &);
69 /** Needed to switch between different classes this works
70 for a list of paragraphs beginning with the specified par
71 return value is the number of wrong conversions.
73 int SwitchLayoutsBetweenClasses(lyx::textclass_type c1,
74 lyx::textclass_type c2,
78 bool checkPastePossible();
80 } // end of CutAndPaste