>  기사  >  백엔드 개발  >  在linux 下 pdflib 多语言有关问题

在linux 下 pdflib 多语言有关问题

WBOY
WBOY원래의
2016-06-13 13:50:03855검색

在linux 下 pdflib 多语言问题
关键代码如下:

PHP code
<!--

Code highlighting produced by Actipro CodeHighlighter (freeware)
http://www.CodeHighlighter.com/

-->
$path =  getcwd()."/src/fonts/newfont.TTF";
if(!PDF_set_parameter($p, "FontOutline", "myfont=$path"))
{
     PDEBUG("set parameter fontoutline fail", __FILE__, __LINE__);
}

[color=#FF0000]$fonthand = PDF_load_font($this->pdf, "myfont", "unicode", ""); //此行报错[/color]
if($fonthand == NULL)
{
     PDEBUG("failed to search for a font and prepare it for later use",__LINE__,__FILE__);
}

if(!pdf_setfont($p, $fonthand, $big))
{
    pdebug("设置字体失败",__line__,__file__);
    return false;
}




提示错误为:
Unicode and glyph id addressing not supported in PDFlib Lite'

到网上找了N久没答案,请高手指教

我用的pdflib 版本是 7.0.3


------解决方案--------------------
PDF_load_font 这个函数你定义了?

网页头部有没有调用这个函数所在的网页?!!!
------解决方案--------------------
pdflib lite不支持 unicode
------解决方案--------------------
学习
jf
------解决方案--------------------
探讨
引用:
引用:
pdflib lite不支持 unicode


谢谢!

请问在 pdflib lite下有其他办法自己添加字体吗?比如说越南语,thai……

用UTF-8试试
貌似只有UTF-8支持越南语

성명:
본 글의 내용은 네티즌들의 자발적인 기여로 작성되었으며, 저작권은 원저작자에게 있습니다. 본 사이트는 이에 상응하는 법적 책임을 지지 않습니다. 표절이나 침해가 의심되는 콘텐츠를 발견한 경우 admin@php.cn으로 문의하세요.