Hi Michael,

Sorry for the late answer. We investigated the issue and finally could 
reproduce it on a recent version of Ubuntu. It turns out that pdftex is 
sensitive to the number format of the font descriptor values StemV. It only 
works for integer. We checked in a workaround to use integers (see changeset 
3682, https://sourceforge.net/p/pyx/code/3682/) and also reported the issue to 
the pdftex folks [email protected] (not yet visible in the list archive 
http://tug.org/pipermail/pdftex/2016-July/thread.html).

Best,


Jörg and André 

Am 27.05.2016 um 09:21 schrieb Michael Hartmann <[email protected]>:

> Hello,
> 
> I've had a strange problem regarding a PyX plot last week. I don't know if
> it's the fault of PyX, but I want to report the problem anyhow.
> 
> When I try to include a PDF created by PyX in a LaTeX document using
> \includegraphics, pdflatex aborts.
> 
> The PDF is created by this code (the code is attached: plot.py: the output is
> also attached: plot.pdf):
> 
>  1 from pyx import *
>  2
>  3 text.set(text.LatexRunner)
>  4 text.preamble(r"\usepackage{mathabx}")
>  5
>  6 c = canvas.canvas()
>  7 c.text(0,0, r"$\widebar{X}$")
>  8 c.writePDFfile()
> 
> I load the mathabx package, create a canvas and write \widebar{X} to the
> canvas. PyX creates a PDF which looks fine to me in several PDF viewers
> (okular, evince, xpdf). However, I get the warning:
> 
> "We are about to extract font information for the Type 1 font 'TeX-mathx10'
> from its pfb file. This is bad practice (and it's slow). You should use an afm
> file instead."
> 
> If I now try to include this PDF in a LaTeX document (see attachement
> text.tex), pdflatex crashes and prints the error:
> 
> "<plot.pdf, id=1, 11.07693pt x 10.43765pt> <use plot.pdf> 
> [1{/var/lib/texmf/font
> s/map/pdftex/updmap/pdftex.map} <./plot.pdfInternal Error (0): Call to Object
> where the object was type 2, not the expected type 1
> 
> I've solved my problem by not using \widebar. But I don't know if this is a
> problem of mathabx, of PyX or pdflatex. Unfortunately, I don't know how one
> can check if a PDF file is valid.
> 
> I use PyX 0.14 and pdfTeX 3.14159265-2.6-1.40.15 (TeX Live 2015/dev/Debian) on
> Debian 8.4.
> 
> Best whishes,
> 
> --Michael
> <plot.pdf><plot.py><text.tex>------------------------------------------------------------------------------
> What NetFlow Analyzer can do for you? Monitors network bandwidth and traffic
> patterns at an interface-level. Reveals which users, apps, and protocols are 
> consuming the most bandwidth. Provides multi-vendor support for NetFlow, 
> J-Flow, sFlow and other flows. Make informed decisions using capacity 
> planning reports. 
> https://ad.doubleclick.net/ddm/clk/305295220;132659582;e_______________________________________________
> PyX-user mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/pyx-user

-- 
by  _ _      _    Dr. André Wobst, Amselweg 22, 85716 Unterschleißheim
   / \ \    / )   [email protected], http://www.wobsta.de/
  / _ \ \/\/ /    PyX - High quality PostScript and PDF figures
 (_/ \_)_/\_/     with Python & TeX: visit http://pyx.sourceforge.net/

Attachment: smime.p7s
Description: S/MIME cryptographic signature

------------------------------------------------------------------------------
Attend Shape: An AT&T Tech Expo July 15-16. Meet us at AT&T Park in San
Francisco, CA to explore cutting-edge tech and listen to tech luminaries
present their vision of the future. This family event has something for
everyone, including kids. Get more information and register today.
http://sdm.link/attshape
_______________________________________________
PyX-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/pyx-user

Reply via email to