cvs: php4(PHP_4_2_0) /ext/gd gd.c

From: Date: Tue, 03 Sep 2002 13:09:30 +0000
Subject: cvs: php4(PHP_4_2_0) /ext/gd gd.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-13803@lists.php.net to get a copy of this message
sniper Tue Sep 3 09:09:30 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/gd gd.c Log: Patch by Melvyn to make ttf/ft string functions work again. Index: php4/ext/gd/gd.c diff -u php4/ext/gd/gd.c:1.179.2.2 php4/ext/gd/gd.c:1.179.2.3 --- php4/ext/gd/gd.c:1.179.2.2 Mon Jun 3 22:35:00 2002 +++ php4/ext/gd/gd.c Tue Sep 3 09:09:29 2002 @@ -18,7 +18,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: gd.c,v 1.179.2.2 2002/06/04 02:35:00 sniper Exp $ */ +/* $Id: gd.c,v 1.179.2.3 2002/09/03 13:09:29 sniper Exp $ */ /* gd 1.2 is copyright 1994, 1995, Quest Protein Database Center, Cold Spring Harbor Labs. */ @@ -2655,8 +2655,12 @@ Give the bounding box of a text using fonts via freetype2 */ PHP_FUNCTION(imageftbbox) { -#if HAVE_LIBGD20 && HAVE_LIBFREETYPE && HAVE_GD_STRINGFTEX +#if HAVE_LIBGD20 && HAVE_LIBFREETYPE +# if HAVE_GD_STRINGFTEX php_imagettftext_common(INTERNAL_FUNCTION_PARAM_PASSTHRU, TTFTEXT_BBOX, 1); +# else + php_imagettftext_common(INTERNAL_FUNCTION_PARAM_PASSTHRU, TTFTEXT_BBOX, 0); +# endif #else php_error(E_WARNING, "%s(): No FreeType 2 support in this PHP build", get_active_function_name(TSRMLS_C)); RETURN_FALSE; @@ -2668,8 +2672,12 @@ Write text to the image using fonts via freetype2 */ PHP_FUNCTION(imagefttext) { -#if HAVE_LIBGD20 && HAVE_LIBFREETYPE && HAVE_GD_STRINGFTEX +#if HAVE_LIBGD20 && HAVE_LIBFREETYPE +# if HAVE_GD_STRINGFTEX php_imagettftext_common(INTERNAL_FUNCTION_PARAM_PASSTHRU, TTFTEXT_DRAW, 1); +# else + php_imagettftext_common(INTERNAL_FUNCTION_PARAM_PASSTHRU, TTFTEXT_DRAW, 0); +# endif #else php_error(E_WARNING, "%s(): No FreeType 2 support in this PHP build", get_active_function_name(TSRMLS_C)); RETURN_FALSE;

« previous php.cvs (#13803) next »