]> git.lyx.org Git - lyx.git/commitdiff
small stuff
authorAndré Pönitz <poenitz@gmx.net>
Fri, 30 Aug 2002 08:36:35 +0000 (08:36 +0000)
committerAndré Pönitz <poenitz@gmx.net>
Fri, 30 Aug 2002 08:36:35 +0000 (08:36 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@5182 a592a061-630c-0410-9148-cb99ea01b6c8

src/mathed/BUGS
src/mathed/math_cursor.C
src/mathed/math_mathmlstream.C
src/mathed/math_parser.C

index f24207b8e7ebfc99b2f80d95fb22d1d5d0367f9e..c4e263b71eed6d8b5a80bed41e72d97061f6bf6e 100644 (file)
@@ -32,16 +32,8 @@ General hints for bug reports:
 
   - plain ASCII text please, not much more than 70 chars per column 
 
-----------------------------------------------------------------------
-
-- \matrm{xy} gets written as \mathrm{x}\mathrm{y}
-
 Dekel:
 
-- LyX crashes when you define a recursive macro
-
-pp - It is possible to put two or more consecutive spaces in math text mode
-
 - InsetFormula::validate is broken
 
 
@@ -106,13 +98,6 @@ From: 
 - Some math symbols aren't very well supported (to my knowledge). I'm 
   thinking of [] options.
 
-Herbert Voss:
-
-- it's not possible to enter superscript when the
-  ^-char works as a dead key. with the second ^-
-  or the space the cursor jumps outside the mathbox.
-
-
 Jules Bean:
 
 a) If something's easy & quick in LaTeX then it should be easy & quick in
index 3752ae051e8b05bf7b8600d37c3b97488d1d2e31..692c63b773e6dad48588cb5d80335e3861d4d831 100644 (file)
@@ -817,8 +817,8 @@ void MathCursor::normalize()
                        MathScriptInset * p = array()[i].nucleus()->asScriptInset();
                        if (p) {
                                p->removeEmptyScripts();
-                               //if (p->empty())
-                               //      array().erase(i);
+                               if (!p->hasUp() && !p->hasDown() && p->nuc().size() == 1)
+                                       array()[i] = p->nuc()[0];
                        }
                }
        }
index 1c7f74ed4c9adedf49a57269856c3017158385d2..81b1a73ca8ccb8eb1b5bc5d841e58adb8f00ab18 100644 (file)
 using std::ostream;
 using std::strlen;
 
+namespace {
+
+       bool isAlpha(char c) 
+       {
+               return ('a' <= c && c <= 'z') || ('A' <= c && c <= 'Z');
+       }
+
+}
 
 WriteStream::WriteStream(ostream & os, bool fragile, bool latex)
        : os_(os), fragile_(fragile), firstitem_(false), latex_(latex),
@@ -68,7 +76,7 @@ WriteStream & operator<<(WriteStream & ws, char const * s)
 WriteStream & operator<<(WriteStream & ws, char c)
 {
        if (ws.pendingSpace()) {
-               if (isalpha(c))
+               if (isAlpha(c))
                        ws.os() << ' ';
                ws.pendingSpace(false);
        }
index 1f7e3b570687cc95bc42cd0c225e94b8cdb09645..9a7cfe5f016127084782c9b4a17de0279310c426 100644 (file)
@@ -687,7 +687,7 @@ void Parser::parse1(MathGridInset & grid, unsigned flags,
                        ++cellcol;
                        //lyxerr << " column now " << cellcol << " max: " << grid.ncols() << "\n";
                        if (cellcol == grid.ncols()) {
-                               lyxerr << "adding column " << cellcol << "\n";
+                               //lyxerr << "adding column " << cellcol << "\n";
                                grid.addCol(cellcol - 1);
                        }
                        cell = &grid.cell(grid.index(cellrow, cellcol));
@@ -870,7 +870,7 @@ void Parser::parse1(MathGridInset & grid, unsigned flags,
                        for (int i = 0; i < cols; ++i) {
                                ++cellcol;
                                if (cellcol == grid.ncols()) {
-                                       lyxerr << "adding column " << cellcol << "\n";
+                                       //lyxerr << "adding column " << cellcol << "\n";
                                        grid.addCol(cellcol - 1);
                                }
                                cell = &grid.cell(grid.index(cellrow, cellcol));