|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2003-10-12 21:55 UTC] sniper@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sat Oct 25 15:00:01 2025 UTC |
Description: ------------ imagepsloadfont() returns int, not resource, despite what the docs say. I believe this causes functions like imagepstext() to fail when looking for a custom- loaded font. My understanding is that imagepsloadfont is supposed to return an int > 5 to avoid conflict with the built-ins. Reproduce code: --------------- $font = imagepsloadfont("/Library/WebServer/Documents/meta/MetaBolRom.pfb"); // or locate your .pfb files on your machine echo gettype($font); imagepstext ($im, "Testing... It worked!", $font, 32, $white, $black, 32, 32); Expected result: ---------------- "int" Actual result: -------------- "resource Warning: imagepstext(): libt1 returned error -4 in / Library/WebServer/Documents/index.php on line xx"