X-Git-Url: http://git.vpit.fr/?p=perl%2Fmodules%2FLaTeX-TikZ.git;a=blobdiff_plain;f=lib%2FLaTeX%2FTikZ%2FSet%2FPolyline.pm;h=987c321d380f3cb7efce1437b8d68f29a09cc2ef;hp=a1992a5d11790e0bd677745bb28e6ee38bfeeaa8;hb=6832c809e7591e1c3e2809654f814c298d28d2ef;hpb=95aada0ec5b3c5a0d78ed0ad53436b0e70860bc7 diff --git a/lib/LaTeX/TikZ/Set/Polyline.pm b/lib/LaTeX/TikZ/Set/Polyline.pm index a1992a5..987c321 100644 --- a/lib/LaTeX/TikZ/Set/Polyline.pm +++ b/lib/LaTeX/TikZ/Set/Polyline.pm @@ -83,6 +83,32 @@ sub path { ($set->closed ? 'cycle' : ()); } +=head2 C + +=cut + +sub begin { + my $set = shift; + + my @points = $set->points; + return undef unless @points; + + $points[0]->begin; +} + +=head2 C + +=cut + +sub end { + my $set = shift; + + my @points = $set->points; + return undef unless @points; + + $points[-1]->end; +} + LaTeX::TikZ::Interface->register( polyline => sub { shift;