#ifndef CUTANDPASTE_H
#define CUTANDPASTE_H
-#include "TextClassPtr.h"
-
-#include "support/types.h"
#include "support/docstring.h"
#include "frontends/Clipboard.h"
namespace lyx {
-class Buffer;
+class DocumentClass;
class ErrorList;
class InsetText;
class Cursor;
namespace cap {
/// Get all elements of the cut buffer in plain text format.
-std::vector<docstring> const availableSelections(Buffer const & buffer);
+std::vector<docstring> availableSelections();
/// Get the number of available elements in the cut buffer.
size_type numberOfSelections();
/// Get the sel_index-th element of the cut buffer in plain text format.
-docstring getSelection(Buffer const & buffer, size_t sel_index);
+docstring selection(size_t sel_index);
/**
* Replace using the font of the first selected character and select
/// Paste the paragraph list \p parlist at the position given by \p cur.
/// Does not handle undo. Does only work in text, not mathed.
void pasteParagraphList(Cursor & cur, ParagraphList const & parlist,
- TextClassPtr textclass, ErrorList & errorList);
+ DocumentClass const * const textclass, ErrorList & errorList);
/** Needed to switch between different classes. This works
* for a list of paragraphs beginning with the specified par.
* It changes layouts and character styles.
*/
-void switchBetweenClasses(TextClassPtr const & c1,
- TextClassPtr const & c2, InsetText & in, ErrorList &);
+void switchBetweenClasses(DocumentClass const * const c1,
+ DocumentClass const * const c2, InsetText & in, ErrorList &);
/// Get the current selection as a string. Does not change the selection.
/// Does only work if the whole selection is in mathed.