]> git.lyx.org Git - lyx.git/blobdiff - src/TextMetrics.cpp
(finishing patch -- question was restored, but there were still problems)
[lyx.git] / src / TextMetrics.cpp
index b9e55a34f806e2ff0ce9027731a452b5ecc0c3da..ea8e07fae67ddf732c4f377f918455cf4a3e6a67 100644 (file)
@@ -1053,6 +1053,10 @@ Dimension TextMetrics::rowHeight(pit_type const pit, pos_type const first,
                maxdesc = max(maxdesc, maxfontmetrics.maxDescent());
        }
 
+       // This is nicer with box insets:
+       ++maxasc;
+       ++maxdesc;
+
        ParagraphList const & pars = text_->paragraphs();
        Inset const & inset = text_->inset();
 
@@ -2128,15 +2132,7 @@ void TextMetrics::drawParagraph(PainterInfo & pi, pit_type pit, int x, int y) co
 
                // Take this opportunity to spellcheck the row contents.
                if (row_has_changed && lyxrc.spellcheck_continuously) {
-                       WordLangTuple wl;
-                       // dummy variable, not used.
-                       static docstring_list suggestions;
-                       pos_type from = row.pos();
-                       pos_type to = row.endpos();
-                       while (from < row.endpos()) {
-                               text_->getPar(pit).spellCheck(from, to, wl, suggestions, false);
-                               from = to + 1;
-                       }
+                       text_->getPar(pit).spellCheck();
                }
 
                // Don't paint the row if a full repaint has not been requested