git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@5398 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Dekel Tsur 2002-10-14 20:19:32 +00:00
parent a6c2a6d154
commit 6bc60cc596
2 changed files with 19 additions and 1 deletions

View File

@ -1,3 +1,6 @@
2002-10-14 Dekel Tsur <dekelts@tau.ac.il>
* math_factory.C (initSymbols): iffont.
2002-10-14 André Pönitz <poenitz@gmx.net>

View File

@ -94,13 +94,27 @@ void initSymbols()
std::ifstream fs(filename.c_str());
string line;
bool skip = false;
while (std::getline(fs, line)) {
int charid = 0;
int fallbackid = 0;
latexkeys tmp;
if (line.size() > 0 && line[0] == '#')
continue;
// special case of \iffont / \fi
if (line.size() >= 7 && line.substr(0, 6) == "iffont") {
istringstream is(line);
string tmp;
is >> tmp;
is >> tmp;
skip = !math_font_available(tmp);
continue;
} else if (line.size() >= 3 && line.substr(0, 3) == "end") {
skip = false;
continue;
} else if (skip)
continue;
// special case of pre-defined macros
if (line.size() > 8 && line.substr(0, 5) == "\\def\\") {
//lyxerr << "defining: '" << line << "'\n";
@ -110,6 +124,7 @@ void initSymbols()
}
istringstream is(line);
latexkeys tmp;
is >> tmp.name >> tmp.inset;
if (isFontName(tmp.inset))
is >> charid >> fallbackid >> tmp.extra >> tmp.xmlname;