diff -Naur GD-SVG-0.27/Changes GD-SVG-0.28/Changes --- GD-SVG-0.27/Changes 2005-06-21 21:27:53.000000000 -0400 +++ GD-SVG-0.28/Changes 2006-05-22 12:36:13.000000000 -0400 @@ -1,5 +1,8 @@ Revision history for Perl extension GD::SVG. +0.28 Mon May 22 12:35:55 EDT 2006 + - fixed result codes that were causing broken tests + 0.26 Mon Oct 18 11:29:40 CDT 2004 - added kludgey support for GD::Image::copy() - added a new example script diff -Naur GD-SVG-0.27/SVG.pm GD-SVG-0.28/SVG.pm --- GD-SVG-0.27/SVG.pm 2005-09-14 09:46:14.000000000 -0400 +++ GD-SVG-0.28/SVG.pm 2006-05-22 12:35:40.000000000 -0400 @@ -7,7 +7,7 @@ use vars qw($VERSION @ISA @EXPORT @EXPORT_OK %EXPORT_TAGS $AUTOLOAD); require Exporter; -$VERSION = '0.27'; +$VERSION = '0.28'; # $Id: GD::SVG.diff,v 1.1 2008/08/14 14:23:26 todd Exp $ # Conditional support for side-by-side raster generation. Off for now. @@ -709,7 +709,7 @@ # are we trying to draw a pie? elsif ($end - $start > 180 && ($fill_style == 0 || $fill_style == 4)) { $self->filledArc($cx,$cy,$width,$height,$start,$start+180,$color_index,$fill_style); - $self->filledArc($cx,$cy,$width,$height,$start+180,$end,$color_index,$fill_style); + $result = $self->filledArc($cx,$cy,$width,$height,$start+180,$end,$color_index,$fill_style); } else { diff -Naur GD-SVG-0.27/examples/generate_test_image.pl GD-SVG-0.28/examples/generate_test_image.pl --- GD-SVG-0.27/examples/generate_test_image.pl 2005-09-14 09:35:22.000000000 -0400 +++ GD-SVG-0.28/examples/generate_test_image.pl 2006-05-22 12:31:30.000000000 -0400 @@ -294,34 +294,36 @@ $image->stringUp(gdGiantFont,370,$yoffset+100,'gdGiantFont',$black); $image->stringUp($font_class->Giant,550,$yoffset+100,"$font_class->Giant",$black); -# Fetch all elements of the source image -my @elements = $image->{img}->getElements; -foreach (@elements) { - my $att = $_->getAttributes(); - # Points|rectangles, circles, lines - my $x = $att->{x} || $att->{cx} || $att->{x1}; - my $y = $att->{y} || $att->{cy} || $att->{y1}; + +if ($image_type eq 'GD::SVG') { + # Fetch all elements of the source image + my @elements = $image->{img}->getElements; + foreach (@elements) { + my $att = $_->getAttributes(); + # Points|rectangles, circles, lines + my $x = $att->{x} || $att->{cx} || $att->{x1}; + my $y = $att->{y} || $att->{cy} || $att->{y1}; - # Get the first point for polygons - unless ($x && $y) { - my $points = $att->{points}; - my @points = split(/\s/,$att->{points}); - if ($points) { - ($x,$y) = split(',',$points[0]); - print STDERR "$x $y\n"; + # Get the first point for polygons + unless ($x && $y) { + my $points = $att->{points}; + my @points = split(/\s/,$att->{points}); + if ($points) { + ($x,$y) = split(',',$points[0]); + print STDERR "$x $y\n"; + } } - } - # Paths - unless ($x && $y) { - my @d = split(/\s/,$att->{d}); - if (@d) { - ($x,$y) = split(',',$d[0]); - $x =~ s/^M//; # Remove the style directive + # Paths + unless ($x && $y) { + my @d = split(/\s/,$att->{d}); + if (@d) { + ($x,$y) = split(',',$d[0]); + $x =~ s/^M//; # Remove the style directive + } + print STDERR "$x $y\n"; } - print STDERR "$x $y\n"; } - } print $image->$image_type(); diff -Naur GD-SVG-0.27/t/1.t GD-SVG-0.28/t/1.t --- GD-SVG-0.27/t/1.t 2005-06-21 21:27:57.000000000 -0400 +++ GD-SVG-0.28/t/1.t 2006-05-22 12:35:17.000000000 -0400 @@ -5,7 +5,7 @@ # change 'tests => 1' to 'tests => last_test_to_print'; -use Test::More tests => 50; +use Test::More tests => 49; BEGIN { use_ok('GD::SVG') }; ######################### @@ -70,7 +70,6 @@ ok($polygon->vertices > 0,'vertices ok'); ok($image->polygon($polygon,$black),'create polygon ok'); ok($image->filledPolygon($polygon,$black),'create filledPolygon ok'); -ok($polygon->offset(10,10) > 0,'polygon offset ok'); # Fonts ok(GD::SVG::Font->Tiny > 0,'GD::SVG::Font->Tiny ok');