From: <lph...@us...> - 2005-12-27 00:48:02
|
Update of /cvsroot/tikiwiki/tiki/lib/wiki-plugins In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12661/lib/wiki-plugins Modified Files: wikiplugin_chart.php Log Message: Adding support for PostScript in graph-engine back Index: wikiplugin_chart.php =================================================================== RCS file: /cvsroot/tikiwiki/tiki/lib/wiki-plugins/wikiplugin_chart.php,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- wikiplugin_chart.php 26 Dec 2005 21:33:24 -0000 1.1 +++ wikiplugin_chart.php 27 Dec 2005 00:47:51 -0000 1.2 @@ -71,6 +71,8 @@ } elseif( function_exists( 'pdf_new' ) ) $disp = tra( "Chart as PDF" ); + elseif( function_exists( 'ps_new' ) ) + $disp = tra( "Chart as PostScript" ); else return "<b>no valid renderer for plugin</b><br />"; @@ -81,6 +83,13 @@ $disp = '<a href="' . _wikiplugin_chart_uri( $params, 'PDF' ) . '">' . $disp . '</a>'; } + elseif( function_exists( 'ps_new' ) ) + { + $params['format'] = isset( $format ) ? $format : 'A4'; + $params['orientation'] = isset( $orientation ) ? $orientation : 'landscape'; + + $disp = '<a href="' . _wikiplugin_chart_uri( $params, 'PS' ) . '">' . $disp . '</a>'; + } return $disp; } |