pChart 2.x forum
http://wiki.pchart.net/forum/

Invalid font filename
http://wiki.pchart.net/forum/viewtopic.php?f=3&t=5410
Page 1 of 1

Author:  zhengwhizz [ Fri Apr 27, 2012 1:42 am ]
Post subject:  Invalid font filename

when i output chinese characters, i get this warning,

Warning: imagettfbbox() [function.imagettfbbox]: Invalid font filename in D:\dev\workspace\myphp\chart\class\pImage.class.php on line 211

Warning: imagettftext() [function.imagettftext]: Invalid font filename in D:\dev\workspace\myphp\chart\class\pDraw.class.php on line 1023
........


i'm sure the font file is correct path, and the php file is utf8 encode, i even convert the chinese characters to ascii , but the error is still there, and i can not get the correct character in the chart.

please help me?

Author:  zhengwhizz [ Fri Apr 27, 2012 1:51 am ]
Post subject:  Re: Invalid font filename

i know why,
i copied the font file from the windows\fonts to the pchart\fonts directory, and the font file already in the pchart\fonts dir when i check, but maybe the fonts file has some problem,
when i change the code like the :
$myPicture->setFontProperties(array("FontName"=>"C:\\WINDOWS\\Fonts\\SIMKAI.TTF","FontSize"=>8));
it works,
the windows fonts can not copy out ??

Page 1 of 1 All times are UTC
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/