mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-09 18:31:04 +00:00
\n -> \\
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@5474 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
bb7c6adc28
commit
e2778d8628
@ -935,6 +935,11 @@ bool InsetFormulaBase::display() const
|
||||
}
|
||||
|
||||
|
||||
string InsetFormulaBase::selectionAsString() const
|
||||
{
|
||||
return mathcursor ? mathcursor->grabSelection() : string();
|
||||
}
|
||||
|
||||
/////////////////////////////////////////////////////////////////////
|
||||
|
||||
|
||||
|
@ -110,6 +110,8 @@ public:
|
||||
virtual EDITABLE editable() const { return HIGHLY_EDITABLE; }
|
||||
///
|
||||
bool display() const;
|
||||
// return the selection as string
|
||||
string selectionAsString() const;
|
||||
|
||||
private:
|
||||
/// unimplemented
|
||||
|
@ -1339,7 +1339,7 @@ string MathCursor::grabSelection() const
|
||||
string data;
|
||||
for (row_type row = r1; row <= r2; ++row) {
|
||||
if (row > r1)
|
||||
data += "\\n";
|
||||
data += "\\\\";
|
||||
for (col_type col = c1; col <= c2; ++col) {
|
||||
if (col > c1)
|
||||
data += "&";
|
||||
|
@ -227,6 +227,8 @@ public:
|
||||
void dump(char const * str) const;
|
||||
/// moves on
|
||||
void setSelection(MathIterator const & where, size_type n);
|
||||
/// grab selection marked by anchor and current cursor
|
||||
string grabSelection() const;
|
||||
///
|
||||
void insert(char c);
|
||||
///
|
||||
@ -239,10 +241,6 @@ public:
|
||||
void markErase();
|
||||
//void handleExtern(string const & arg);
|
||||
|
||||
///
|
||||
friend class Selection;
|
||||
|
||||
|
||||
private:
|
||||
/// injects content of a cell into parent
|
||||
void pullArg();
|
||||
@ -265,8 +263,6 @@ private:
|
||||
/// are we in a nucleus of a script inset?
|
||||
bool inNucleus() const;
|
||||
|
||||
/// grab selection marked by anchor and current cursor
|
||||
string grabSelection() const;
|
||||
/// erase the selected part and re-sets the cursor
|
||||
void eraseSelection();
|
||||
/// guess what
|
||||
|
Loading…
Reference in New Issue
Block a user