phpbar.de logo

Mailinglisten-Archive

[php] ImagePSText

[php] ImagePSText

mhe mhe at ltcgroup.de
Mon Nov 1 16:55:36 CET 2004


Am Mon, 01 Nov 2004 16:03:20 +0100 schrieb Andreas Heigl <a.heigl at wdv.de>:

> Der folgende Code erzeugt regelmäßig die Fehlermeldung
>
> 'PHP Warning: imagepstext(): libt1 returned error 14 in /path/to/script.php
> on line 8'

hi,

error 14 ist definiert in t1lib.h als T1ERR_FILE_OPEN_ERR ,
also, eine notwendige Datei wurde nicht gefunden oder
es gab beim Oeffnen einer Datei einen Fehler, Bezug Schrift irgendwas ..
kann dir nicht genau sagen welche, muesste man richtung t1lib mal
noch genauer schauen ..

6:  $font = imagepsloadfont('/path/to/fontfile.pfb');
7:  imagePSEncodeFont( $font, '/path/to/encfile.enc');

diese sind involviert, sind die bei dir wirklich so im system
vorhanden die dateien ? was spricht gegen freetype ?

schaumal hier .. http://de3.php.net/manual/de/function.imagepstext.php in den kommentaren

bye,
  Mathias

=================================================
a at url dot de
18-Feb-2002 03:16
a note on kernnig:
t1lib tries to load a corresponding afm file in the directory of the font file.
it does this by replacing the extension (.PFB .pfb) with ".afm". note that this has to be a lowercase afm! usually windows-ps-fonts have file names in all-uppercase, so try renaming the *.AFM file to *.afm.

i also noticed that sometimes this gives an error -2. it seems like t1lib chokes on windows-linebreaks in the afm file.

try 'recode dos..lat1 fontfile.afm' and check again.

if it all works, combinations like "Ta" or "Te" should show the second letter slightly moved to the capital T (on normal fonts like Times

================================================

php::bar PHP Wiki   -   Listenarchive