mirror of
https://git.lyx.org/repos/lyx.git
synced 2025-01-10 18:58:10 +00:00
Tweaks.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@22793 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
049dea1eb1
commit
2e82ca7198
@ -86,6 +86,19 @@ bool layout2layout(FileName const & filename, FileName const & tempfile)
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
std::string translateRT(TextClass::ReadType rt)
|
||||||
|
{
|
||||||
|
switch (rt) {
|
||||||
|
case TextClass::BASECLASS:
|
||||||
|
return "textclass";
|
||||||
|
case TextClass::MERGE:
|
||||||
|
return "input file";
|
||||||
|
case TextClass::MODULE:
|
||||||
|
return "module file";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
} // namespace anon
|
} // namespace anon
|
||||||
|
|
||||||
|
|
||||||
@ -199,20 +212,8 @@ bool TextClass::read(FileName const & filename, ReadType rt)
|
|||||||
{ "tocdepth", TC_TOCDEPTH }
|
{ "tocdepth", TC_TOCDEPTH }
|
||||||
};
|
};
|
||||||
|
|
||||||
switch (rt) {
|
LYXERR(Debug::TCLASS, "Reading " + translateRT(rt) + ": " +
|
||||||
case BASECLASS:
|
to_utf8(makeDisplayPath(filename.absFilename())));
|
||||||
LYXERR(Debug::TCLASS, "Reading textclass ");
|
|
||||||
break;
|
|
||||||
case MERGE:
|
|
||||||
LYXERR(Debug::TCLASS, "Reading input file ");
|
|
||||||
break;
|
|
||||||
case MODULE:
|
|
||||||
LYXERR(Debug::TCLASS, "Reading module file ");
|
|
||||||
break;
|
|
||||||
default:
|
|
||||||
BOOST_ASSERT(false);
|
|
||||||
}
|
|
||||||
LYXERR(Debug::TCLASS, to_utf8(makeDisplayPath(filename.absFilename())));
|
|
||||||
|
|
||||||
Lexer lexrc(textClassTags,
|
Lexer lexrc(textClassTags,
|
||||||
sizeof(textClassTags) / sizeof(textClassTags[0]));
|
sizeof(textClassTags) / sizeof(textClassTags[0]));
|
||||||
@ -450,15 +451,10 @@ bool TextClass::read(FileName const & filename, ReadType rt)
|
|||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (rt == MODULE)
|
LYXERR(Debug::TCLASS, "Finished reading " + translateRT(rt) + ": " +
|
||||||
LYXERR(Debug::TCLASS, "Finished reading module file "
|
to_utf8(makeDisplayPath(filename.absFilename())));
|
||||||
<< to_utf8(makeDisplayPath(filename.absFilename())));
|
|
||||||
else if (rt == MERGE)
|
if (rt == BASECLASS) {
|
||||||
LYXERR(Debug::TCLASS, "Finished reading input file "
|
|
||||||
<< to_utf8(makeDisplayPath(filename.absFilename())));
|
|
||||||
else { // we are at top level here.
|
|
||||||
LYXERR(Debug::TCLASS, "Finished reading textclass "
|
|
||||||
<< to_utf8(makeDisplayPath(filename.absFilename())));
|
|
||||||
if (defaultlayout_.empty()) {
|
if (defaultlayout_.empty()) {
|
||||||
lyxerr << "Error: Textclass '" << name_
|
lyxerr << "Error: Textclass '" << name_
|
||||||
<< "' is missing a defaultstyle." << endl;
|
<< "' is missing a defaultstyle." << endl;
|
||||||
|
Loading…
Reference in New Issue
Block a user