From c22c2482f3a3731f2b0b126661421cac44da0a62 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20P=C3=B6nitz?= Date: Wed, 6 Nov 2002 11:13:56 +0000 Subject: [PATCH] whitespace, unused code, unused convenience function for debugging git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@5589 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/mathed/math_iterator.C | 14 ++------------ src/mathed/math_iterator.h | 2 ++ src/mathed/math_nestinset.C | 1 + 3 files changed, 5 insertions(+), 12 deletions(-) diff --git a/src/mathed/math_iterator.C b/src/mathed/math_iterator.C index ddfbc620aa..cda774c47a 100644 --- a/src/mathed/math_iterator.C +++ b/src/mathed/math_iterator.C @@ -123,22 +123,12 @@ void MathIterator::jump(difference_type i) } -/* -void MathIterator::shrink(size_type i) +bool MathIterator::normal() const { - if (i < size()) - erase(begin() + i, end()); + return back().pos_ < cell().size(); } -void MathIterator::shrink(size_type i) -{ - if (i < size()) - erase(begin() + i, end()); -} -*/ - - void MathIterator::shrink(size_type i) { if (i < size()) diff --git a/src/mathed/math_iterator.h b/src/mathed/math_iterator.h index 8d71416a66..53a9727f5d 100644 --- a/src/mathed/math_iterator.h +++ b/src/mathed/math_iterator.h @@ -50,6 +50,8 @@ public: void goEnd(); /// read access to top most item MathArray const & cell() const; + /// is this a non-end position + bool normal() const; /// shrinks to at most i levels void shrink(size_type i); diff --git a/src/mathed/math_nestinset.C b/src/mathed/math_nestinset.C index 85c41832da..5308cfc807 100644 --- a/src/mathed/math_nestinset.C +++ b/src/mathed/math_nestinset.C @@ -45,6 +45,7 @@ void MathNestInset::getPos(idx_type idx, pos_type pos, int & x, int & y) const x += 2; } + void MathNestInset::substitute(MathMacro const & m) { for (idx_type i = 0; i < nargs(); ++i)