From ced8f27b153492fd95a710f7d7254773626d1953 Mon Sep 17 00:00:00 2001 From: ellson Date: Wed, 14 Nov 2007 21:57:54 +0000 Subject: [PATCH] Use "swig -php5" so that we can use gv:: class methods as advertised --- tclpkg/gv/Makefile.am | 2 +- tclpkg/gv/demo/modgraph.php | 30 +++++++++++++++--------------- 2 files changed, 16 insertions(+), 16 deletions(-) diff --git a/tclpkg/gv/Makefile.am b/tclpkg/gv/Makefile.am index 15d790133..990e640a7 100644 --- a/tclpkg/gv/Makefile.am +++ b/tclpkg/gv/Makefile.am @@ -113,7 +113,7 @@ libgv_php_la_LIBADD = $(BASELIBS) @PHP_LIBS@ libgv_php_la_LDFLAGS = -module -avoid-version $(PHP_data): gv_php.cpp gv_php.cpp: gv.i - $(SWIG) -c++ -php -o gv_php.cpp $(srcdir)/gv.i + $(SWIG) -c++ -php5 -o gv_php.cpp $(srcdir)/gv.i pkgpythondir = $(pkglibdir)/python PYTHON_data = gv.py diff --git a/tclpkg/gv/demo/modgraph.php b/tclpkg/gv/demo/modgraph.php index 8055baba9..e1e34c76e 100755 --- a/tclpkg/gv/demo/modgraph.php +++ b/tclpkg/gv/demo/modgraph.php @@ -10,19 +10,19 @@ include("gv.php"); # author: John Ellson -$G = digraph("G"); -$N = protonode($G); -$E = protoedge($G); - -setv($G, "rankdir", "LR"); -setv($G, "nodesep", "0.05"); -setv($N, "shape", "box"); -setv($N, "width", "0"); -setv($N, "height", "0"); -setv($N, "margin", ".03"); -setv($N, "fontsize", "8"); -setv($N, "fontname", "helvetica"); -setv($E, "arrowsize", ".4"); +$G = gv::digraph("G"); +$N = gv::protonode($G); +$E = gv::protoedge($G); + +gv::setv($G, "rankdir", "LR"); +gv::setv($G, "nodesep", "0.05"); +gv::setv($N, "shape", "box"); +gv::setv($N, "width", "0"); +gv::setv($N, "height", "0"); +gv::setv($N, "margin", ".03"); +gv::setv($N, "fontsize", "8"); +gv::setv($N, "fontname", "helvetica"); +gv::setv($E, "arrowsize", ".4"); $f = fopen("/proc/modules", "r"); while ( ! feof($f)) { @@ -40,7 +40,7 @@ while ( ! feof($f)) { } fclose($f); -#layout($G, "dot"); -#render($G, "png"); +#gv::layout($G, "dot"); +#gv::render($G, "png"); ?> -- 2.40.0