* Buffer.cpp (getLanguages):

- assure the buffer language is in the list.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33569 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Jürgen Spitzmüller 2010-02-25 18:00:43 +00:00
parent 9f67cede58
commit 86f1641299

View File

@ -2212,6 +2212,9 @@ std::set<Language const *> Buffer::getLanguages() const
void Buffer::getLanguages(std::set<Language const *> & languages) const
{
ParConstIterator end = par_iterator_end();
// add the buffer language, even if it's not actively used
languages.insert(language());
// iterate over the paragraphs
for (ParConstIterator it = par_iterator_begin(); it != end; ++it)
it->getLanguages(languages);
// also children