// cached files on opening. This slows LyX startup a lot. It
// would be better if this information was retrieved in a
// delayed fashion.
// cached files on opening. This slows LyX startup a lot. It
// would be better if this information was retrieved in a
// delayed fashion.
FormatCacheType & format_cache = it1->second.cache;
FormatCacheType::iterator const it2 = format_cache.find(format);
if (it2 == format_cache.end())
FormatCacheType & format_cache = it1->second.cache;
FormatCacheType::iterator const it2 = format_cache.find(format);
if (it2 == format_cache.end())
cache_dir = FileName(addName(package().user_support().absFileName(), "cache"));
if (!cache_dir.exists())
if (!cache_dir.createDirectory(0700)) {
cache_dir = FileName(addName(package().user_support().absFileName(), "cache"));
if (!cache_dir.exists())
if (!cache_dir.createDirectory(0700)) {
FormatCache & format_cache = pimpl_->cache[orig_from];
if (format_cache.from_format.empty())
format_cache.from_format =
FormatCache & format_cache = pimpl_->cache[orig_from];
if (format_cache.from_format.empty())
format_cache.from_format =
format_cache.cache[to_format] = new_item;
} else
LYXERR(Debug::FILES, "ConverterCache::add(" << orig_from << "):\n"
format_cache.cache[to_format] = new_item;
} else
LYXERR(Debug::FILES, "ConverterCache::add(" << orig_from << "):\n"