> I'm having real problems working with LyX and child document. It's very very > slow when typing text. >> This is a very mysterious mystery. >> rh
A possible explanation for this. For each keystroke, updateMacros() is called, which calls InsetInclude::loadIfNeeded(), which then calls theBufferList::getBuffer(). This function iterates over all loaded buffers and if the wanted file is not loaded yet it will be loaded. As a consequence, having 5 child documents leads to comparing 2+3+4+5+6=20 times two filenames. In FileName::operator==(), two new FileName objects are constructed (lhs and rhs) and in the constructor QFileInfo::isFileExists() is called. This leads thus already to accessing the filesystem 40 times.Then, both QFileInfo objects are refreshed, which makes it 80 times. Having a thesis with 10 chapters in separate child documents, would cause 260 filesystem checks for each character !! Typing at a speed of 10 characters per second, thus leads to 2600 network files to be accessed.. per second ... Time to mess up things ? Vincent
