2 * \file src/FontIterator.C
3 * This file is part of LyX, the document processor.
4 * Licence details can be found in the file COPYING.
6 * \author Alfredo Braunstein
8 * Full author contact details are available in file CREDITS.
15 #include "FontIterator.h"
18 #include "paragraph.h"
21 FontIterator::FontIterator(LyXText const & text, Paragraph const & par,
23 : text_(text), par_(par), pos_(pos),
24 font_(text.getFont(par, pos)),
25 endspan_(par.fontSpan(pos).last),
26 bodypos_(par.beginOfBody())
30 LyXFont const & FontIterator::operator*() const
36 LyXFont * FontIterator::operator->()
42 FontIterator & FontIterator::operator++()
45 if (pos_ > endspan_ || pos_ == bodypos_) {
46 font_ = text_.getFont(par_, pos_);
47 endspan_ = par_.fontSpan(pos_).last;