(I'm sorry for the delayed answer.)
On 9/15/07, Hans Hagen wrote:
> Andrea Valle wrote:
> > ** WARNING ** Invalid CMap
> > ** ERROR ** pdf_ref_obj(): passed invalid object.
>
> i wonder what that object is .. and who generates the ref, could be a
> special but you do nothing special in the example so i'm puzzled ... do
> others have this problem?
Yes. I don't remember whether I already complained about it or not,
but here's another (minimal) example to reproduce it:
\starttext
\startformula
a+b=\int_{i=0}^{\infty}\Gamma\,dx
\stopformula
\stoptext
The main problem (besides being quite slow for the default LM) is that
"font loading" in ConTeXt+XeTeX now does the following:
if ("FontName" is a valid font) then
use "FontName"
else
use "[FontName]"
end
And that one forgets the third possibility: about the old tfm fonts
which should be loaded without any quotes, for example rm-lmr12
\font\a="rm-lmr12" works, but \font\a="rm-lmr12" at 12pt doesn't, and
ConTeXt tries to use that one. Normally TeX would stop: generate and
report the error at that point, but ConTeXt currently skips those
errors on purpose and tries to use an unexisting font, so it results
in a broken PDF.
What about
\definefontsynonym [...] [rm-lmr12] [type=tfm]
\definefontsynonym [...] [lmodern12-regular] [type=otf]
or, use the already existing mechanism:
\definefontsynonym [...] [tfm:rm-lmr12] [...]
\definefontsynonym [...] [file:lmodern12-regular] [...]
I know it's ugly, but I guess that one either needs:
a) being more precise in font specifications inside ConTeXt and tell
XeTeX exactly what kind of font needs to be loaded (an installed one,
otf file inside texmf tree, or the old tfm)
b) a harmless way to ask XeTeX if some font exists (instead of the
current ugly hack)
c) a new "extremely permissive" mode in XeTeX, which would accept the
same synax for al the three kinds of fonts
The fastest way to fix this is to create the third possibility in the
if-else statement (I forgot where that one was, but I can take a
look), but as an intermediate solution (until XeTeX gets more
functionality in that respect, if ever), I guess that a) would be a
must, although the definitions might look slightly less elegant/clean
than they're now.
Mojca
PS: to be honest, I'm still using the XeTeX version from TeXLive 2007
which is a bit old. I remember that Jonathan has promissed to look
into the problem described above some time ago (\font\a="rm-lmr12" vs.
\font\a="rm-lmr12" at 12pt), but I have no idea about what has
happened later with it. But in any case: this problem should be fixed
inside ConTeXt first.
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the
Wiki!
maillist : [email protected] / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________