Slightly off-topic here:
I've been having trouble with my pyx installation that I get from
darwinports. Everything works fine when I use the source
installation. But with port, pyx always can't find certain font size
files. This problem has been posed twice over the last several
months, though I'm not sure it's been properly resolved, so I thought
I'd bring it up again.
Magnus Lie Hetland wrote:
> Just tried to install PyX via DarwinPorts -- but that didn't work
> very well. PyX can't find the file 10pt.lfs, even though it has been
> properly installed by the install script. I guess perhaps it's in a
> directory that PyX doesn't look in (although it strikes me as odd
> that the ports install would install it in the wrong place...).
>
> Anyway, it's in /opt/local/share/pyx -- how can I make PyX look
> there? Edit a .pyxrc file? Run kpsewhich? Move the lfs file to
> somewhere pyx might look?
Klaus Wolfinger wrote:
> I' have the same problem (working with SuSE Linux9.3). Did you find
> a solution ?
This appears to be a persistent issue with the darwinports
installation of pyx. And here's one more strange twist to the story.
If I attempt to create text using the same command twice, the second
time it seems to work perfectly.
>>> from pyx import *
>>>
>>> c = canvas.canvas()
>>> c.text(0, 0, "Hello, world!")
Traceback (most recent call last):
File "<stdin>", line 1, in ?
File "/opt/local/lib/python2.4/site-packages/pyx/canvas.py", line
308, in text
return self.insert(self.texrunner.text(x, y, atext, *args,
**kwargs))
File "/opt/local/lib/python2.4/site-packages/pyx/text.py", line
1197, in text
self.execute(expr, self.defaulttexmessagesdefaultrun +
self.texmessagesdefaultrun + texmessages)
File "/opt/local/lib/python2.4/site-packages/pyx/text.py", line
960, in execute
raise IOError("%sNo LaTeX font size files (*.lfs) available.
Check your installation." % lfserror)
IOError: File '10pt.lfs' is not available or not readable. No LaTeX
font size files (*.lfs) available. Check your installation.
>>> c.text(0, 0, "Hello, world!")
<pyx.text.textbox instance at 0x11f1800>
>>> c.stroke(path.line(0, 0, 2, 0))
>>> c.writeEPSfile("hello")
>>> c.writePDFfile("hello")
Why would something fail the first time but succeed a second time? I
might note that if you try emitting different text, it comes up with
the same error again but then succeeds on the second and subsequent
instances:
>>> c.text(0, 0, "Different Text Here")
Traceback (most recent call last):
File "<stdin>", line 1, in ?
File "/opt/local/lib/python2.4/site-packages/pyx/canvas.py", line
308, in text
return self.insert(self.texrunner.text(x, y, atext, *args,
**kwargs))
File "/opt/local/lib/python2.4/site-packages/pyx/text.py", line
1197, in text
self.execute(expr, self.defaulttexmessagesdefaultrun +
self.texmessagesdefaultrun + texmessages)
File "/opt/local/lib/python2.4/site-packages/pyx/text.py", line
960, in execute
raise IOError("%sNo LaTeX font size files (*.lfs) available.
Check your installation." % lfserror)
IOError: File '10pt.lfs' is not available or not readable. No LaTeX
font size files (*.lfs) available. Check your installation.
>>> c.text(0, 0, "Different Text Here")
<pyx.text.textbox instance at 0x1214c10>
>>> c.text(0, 1, "Different Text Here")
<pyx.text.textbox instance at 0x1293148>
>>>
I'd be interested to hear everyone's thoughts. This has been a
problem for me on all _three_ separate vanilla installations on both
intel and ppc machines. It has been an issue since I started working
with pyx 0.7. It'd be great if we could get this all sorted out.
Regards,
Tom Kornack
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
PyX-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/pyx-user