]> git.lyx.org Git - features.git/commitdiff
small patches from Angus
authorAndré Pönitz <poenitz@gmx.net>
Tue, 8 Jan 2002 15:13:31 +0000 (15:13 +0000)
committerAndré Pönitz <poenitz@gmx.net>
Tue, 8 Jan 2002 15:13:31 +0000 (15:13 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@3316 a592a061-630c-0410-9148-cb99ea01b6c8

src/mathed/math_cursor.C
src/mathed/math_cursor.h
src/mathed/math_macroarg.C

index 3a2f30501302b9117cf6159ce1e85cbae3269e38..e54922cae0898837ea7d06d86854bba7785278ca 100644 (file)
@@ -617,7 +617,7 @@ void MathCursor::macroModeClose()
 }
 
 
-int MathCursor::macroNamePos() const
+MathInset::difference_type MathCursor::macroNamePos() const
 {
        for (MathInset::difference_type i = pos() - 1; i >= 0; --i) { 
                MathAtom & p = array().at(i);
@@ -859,7 +859,7 @@ bool MathCursor::selection() const
 
 MathGridInset * MathCursor::enclosingGrid(MathCursor::idx_type & idx) const
 {
-       for (int i = Cursor_.size() - 1; i >= 0; --i) {
+       for (MathInset::difference_type i = Cursor_.size() - 1; i >= 0; --i) {
                MathGridInset * p = Cursor_[i].par_->asGridInset();
                if (p) {
                        idx = Cursor_[i].idx_;
index a192a82dc78e686e8734d3196095c6bf64193321..6e2742fd6505e64415185e9b946663798f44836f 100644 (file)
@@ -258,7 +258,7 @@ private:
        ///
        string macroName() const;
        ///
-       int macroNamePos() const;
+       MathInset::difference_type macroNamePos() const;
        ///
        void insert(char, MathTextCodes t);
        /// can we enter the inset? 
index a9a565160f6fe82631bfd887ad74bd42e1651e42..f65510383290efca8decca4b827c065beb24313f 100644 (file)
@@ -19,7 +19,7 @@ MathMacroArgument::MathMacroArgument(int n)
                        << n << std::endl;
        }
        str_[0] = '#';
-       str_[1] = '0' + static_cast<unsigned char>(n);
+       str_[1] = static_cast<unsigned char>('0' + n);
        str_[2] = '\0';
 }