cvs: gd /libgd/src gdft.c /libgd/tests CMakeLists.txt Makefile.am /libgd/tests/gdimagestringftex CMakeLists.txt Makefile.am gdimagestringftex_returnfontpathname.c

[email protected] ("Takeshi Abe") Mon, 20 Apr 2009 08:58:14 -0000
Newsgroups php.gd.cvs
Message-ID <cvstabe1240217894@cvsserver>
tabe		Mon Apr 20 08:58:14 2009 UTC

  Added files:                 
    /gd/libgd/tests/gdimagestringftex	CMakeLists.txt Makefile.am 
                                     	gdimagestringftex_returnfontpathname.c 

  Modified files:              
    /gd/libgd/src	gdft.c 
    /gd/libgd/tests	CMakeLists.txt Makefile.am 
  Log:
  removed unused assignment to fontpath
  
http://cvs.php.net/viewvc.cgi/gd/libgd/src/gdft.c?r1=1.41&r2=1.42&diff_format=u
Index: gd/libgd/src/gdft.c
diff -u gd/libgd/src/gdft.c:1.41 gd/libgd/src/gdft.c:1.42
--- gd/libgd/src/gdft.c:1.41	Wed Apr 15 17:24:45 2009
+++ gd/libgd/src/gdft.c	Mon Apr 20 08:58:14 2009
@@ -960,8 +960,6 @@
       /* 2.0.29: we can return the font path if desired */
       if (strex->flags & gdFTEX_RETURNFONTPATHNAME) 
         strex->fontpath = strdup(font->fontpath);
-      else
-        strex->fontpath = 0;
     }
 
   matrix.xx = (FT_Fixed) (cos_a * (1 << 16));
http://cvs.php.net/viewvc.cgi/gd/libgd/tests/CMakeLists.txt?r1=1.11&r2=1.12&diff_format=u
Index: gd/libgd/tests/CMakeLists.txt
diff -u gd/libgd/tests/CMakeLists.txt:1.11 gd/libgd/tests/CMakeLists.txt:1.12
--- gd/libgd/tests/CMakeLists.txt:1.11	Tue Mar 17 17:29:28 2009
+++ gd/libgd/tests/CMakeLists.txt	Mon Apr 20 08:58:14 2009
@@ -47,6 +47,7 @@
 		gdimagefilltoborder
 		freetype
 		xpm
+		gdimagestringftex
 	)
 
 	IF (WIN32)
http://cvs.php.net/viewvc.cgi/gd/libgd/tests/Makefile.am?r1=1.5&r2=1.6&diff_format=u
Index: gd/libgd/tests/Makefile.am
diff -u gd/libgd/tests/Makefile.am:1.5 gd/libgd/tests/Makefile.am:1.6
--- gd/libgd/tests/Makefile.am:1.5	Tue Mar 17 17:29:28 2009
+++ gd/libgd/tests/Makefile.am	Mon Apr 20 08:58:14 2009
@@ -1,7 +1,7 @@
 ## Process this file with automake to produce Makefile.in -*-Makefile-*-
 AUTOMAKE_OPTIONS = foreign 1.7
 
-SUBDIRS = gd2 gdimagecolordeallocate gdimagecolortransparent gdimagefill gdimagefilltoborder gdtest jpeg gdimagearc gdimagecolorexact gdimagecopy gdimagefilledellipse gdimageline gdimagepixelate gdtiled freetype gdimagecolorclosest gdimagecolorreplace gdimagecolorresolve gdimagecopyrotated gdimagefilledrectangle gdimagerectangle gdimagesetpixel gif png xpm
+SUBDIRS = gd2 gdimagecolordeallocate gdimagecolortransparent gdimagefill gdimagefilltoborder gdtest jpeg gdimagearc gdimagecolorexact gdimagecopy gdimagefilledellipse gdimageline gdimagepixelate gdtiled freetype gdimagecolorclosest gdimagecolorreplace gdimagecolorresolve gdimagecopyrotated gdimagefilledrectangle gdimagerectangle gdimagesetpixel gif png xpm gdimagestringftex
 
 EXTRA_DIST = CMakeLists.txt
 

http://cvs.php.net/viewvc.cgi/gd/libgd/tests/gdimagestringftex/CMakeLists.txt?view=markup&rev=1.1
Index: gd/libgd/tests/gdimagestringftex/CMakeLists.txt
+++ gd/libgd/tests/gdimagestringftex/CMakeLists.txt
SET(TESTS_FILES
	gdimagestringftex_returnfontpathname
)

FOREACH(test_name ${TESTS_FILES})
	add_executable(${test_name} "${test_name}.c")
	target_link_libraries (${test_name} ${GDTESTS_TARGET_LINK})
	get_target_property(test_path ${test_name} LOCATION)
	ADD_TEST(${test_name} ${test_path})
ENDFOREACH(test_name)

http://cvs.php.net/viewvc.cgi/gd/libgd/tests/gdimagestringftex/Makefile.am?view=markup&rev=1.1
Index: gd/libgd/tests/gdimagestringftex/Makefile.am
+++ gd/libgd/tests/gdimagestringftex/Makefile.am
## Process this file with automake to produce Makefile.in -*-Makefile-*-

EXTRA_DIST = CMakeLists.txt gdimagestringftex_returnfontpathname.c

http://cvs.php.net/viewvc.cgi/gd/libgd/tests/gdimagestringftex/gdimagestringftex_returnfontpathname.c?view=markup&rev=1.1
Index: gd/libgd/tests/gdimagestringftex/gdimagestringftex_returnfontpathname.c
+++ gd/libgd/tests/gdimagestringftex/gdimagestringftex_returnfontpathname.c
#include "gd.h"
#include "gdtest.h"

int main()
{
	gdFTStringExtra strex;
	char path[2048];

	sprintf(path, "%s/freetype/DejaVuSans.ttf", GDTEST_TOP_DIR);
	strex.flags = gdFTEX_RETURNFONTPATHNAME;
	strex.fontpath = NULL;
	gdImageStringFTEx(NULL, NULL, 0, path, 72, 0, 0, 0, "hello, gd", &strex);
	if (!strex.fontpath) {
		return 1;
	}
	if (strcmp(path, strex.fontpath) != 0) {
		return 2;
	}
	gdFree(strex.fontpath);
	return 0;
}