Try writing \hookrightarrow in mathed without having the type1 symbol fonts.
The result is weird: "lhook ->".
The following patch fixes this - it makes mathed behave the same as in 1.2.x.
Index: src/mathed/math_factory.C
===================================================================
RCS file: /usr/local/lyx/cvsroot/lyx-devel/src/mathed/math_factory.C,v
retrieving revision 1.63
diff -u -p -r1.63 math_factory.C
--- src/mathed/math_factory.C 20 Sep 2002 12:36:36 -0000 1.63
+++ src/mathed/math_factory.C 13 Oct 2002 22:01:13 -0000
@@ -94,22 +94,37 @@ void initSymbols()
std::ifstream fs(filename.c_str());
string line;
+ bool disable = 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, 7) == "\\iffont") {
+ istringstream is(line);
+ string tmp;
+ is >> tmp;
+ is >> tmp;
+ disable = !math_font_available(tmp);
+ continue;
+ } else if (line.size() >= 3 && line.substr(0, 3) == "\\fi") {
+ disable = false;
+ continue;
+ }
+
// special case of pre-defined macros
if (line.size() > 8 && line.substr(0, 5) == "\\def\\") {
//lyxerr << "defining: '" << line << "'\n";
istringstream is(line);
- MathMacroTable::create(MathAtom(new MathMacroTemplate(is)));
+ if (!disable)
+ MathMacroTable::create(MathAtom(new
+MathMacroTemplate(is)));
continue;
}
istringstream is(line);
+ latexkeys tmp;
is >> tmp.name >> tmp.inset;
if (isFontName(tmp.inset))
is >> charid >> fallbackid >> tmp.extra >> tmp.xmlname;
Index: lib/symbols
===================================================================
RCS file: /usr/local/lyx/cvsroot/lyx-devel/lib/symbols,v
retrieving revision 1.31
diff -u -p -r1.31 symbols
--- lib/symbols 19 Sep 2002 13:44:48 -0000 1.31
+++ lib/symbols 13 Oct 2002 22:01:13 -0000
@@ -762,24 +762,32 @@ $ mathnormal 0 0 s
#
# pre-defined macros
#
-
-\def\longleftrightarrow{\leftarrow\kern-2mm\rightarrow}
-\def\Longleftrightarrow{\Leftarrow\kern-2mm\Rightarrow}
+\def\longleftrightarrow{\leftarrow\kern-8mm\rightarrow}
+\def\Longleftrightarrow{\Leftarrow\kern-8mm\Rightarrow}
\def\doteq{\stackrel{\cdot}{\=}}
-\def\longrightarrow{\lyxbar\kern-2mm\rightarrow}
-\def\longleftarrow{\leftarrow\kern-2mm\lyxbar}
-\def\mapsto{\mapstochar\kern-2mm\rightarrow}
-\def\longmapsto{\mapstochar\kern-2mm\lyxbar\kern-6mu\rightarrow}
-\def\Longrightarrow{\lyxeq\kern-2mm\Rightarrow}
-\def\Longleftarrow{\Leftarrow\kern-2mm\lyxeq}
-\def\models{\vert\kern-2mm\lyxeq}
-\def\hookrightarrow{\lhook\kern-2mm\rightarrow}
-\def\hookleftarrow{\leftarrow\kern-2mm\rhook}
+
+\iffont cmsy
+\def\longrightarrow{\lyxbar\kern-6mm\rightarrow}
+\def\longleftarrow{\leftarrow\kern-6mm\lyxbar}
+\def\mapsto{\mapstochar\kern-4mm\rightarrow}
+\def\longmapsto{\mapstochar\kern-3mm\lyxbar\kern-6mu\rightarrow}
+\def\Longrightarrow{\lyxeq\kern-5mm\Rightarrow}
+\def\Longleftarrow{\Leftarrow\kern-5mm\lyxeq}
+\def\models{\vert\kern-3mm\lyxeq}
+\fi
+\iffont cmm
+\def\hookrightarrow{\lhook\kern-8mm\rightarrow}
+\def\hookleftarrow{\leftarrow\kern-8mm\rhook}
\def\bowtie{\triangleright\kern-2mm\triangleleft}
+\fi
+\iffont msa
\def\dashrightarrow{\lyxdabar\lyxdabar\lyxright}
\def\dashleftarrow{\lyxleft\lyxdabar\lyxdabar}
\def\dasharrow{\dashrightarrow}
-\def\Join{\ltimes\kern-2mm\rtimes}
+\fi
+\iffont msb
+\def\Join{\ltimes\kern-12mm\rtimes}
+\fi
\def\mathcircumflex{\mbox{\^{}}}
neq lyxsymbol 185 0 mathrel x