]> git.lyx.org Git - features.git/blobdiff - src/frontends/qt4/GuiSpellchecker.cpp
start work on less-likely-to-misuse iterators.
[features.git] / src / frontends / qt4 / GuiSpellchecker.cpp
index 86d628c77abac66fe9ac0139d096528271fdb193..9c4ad163cc63f43d01baee4c4c644d4c609948bd 100644 (file)
@@ -333,8 +333,8 @@ void GuiSpellchecker::check()
 
        ptrdiff_t start = 0;
        ptrdiff_t total = 0;
-       DocIterator it = DocIterator(buffer().inset());
-       for (start = 0; it != cur; it.forwardPos())
+       DocIterator it = doc_iterator_begin(buffer().inset());
+       for (start = 1; it != cur; it.forwardPos())
                ++start;
 
        for (total = start; it; it.forwardPos())