From: Vincent Pit Date: Wed, 21 Jul 2010 10:35:35 +0000 (+0200) Subject: Kids of Set::{Circle,Line,Rectangle} should be Set::Points, not Points X-Git-Tag: v0.01~33 X-Git-Url: http://git.vpit.fr/?p=perl%2Fmodules%2FLaTeX-TikZ.git;a=commitdiff_plain;h=98f997b4a99a2d7cb6ce6bed78f0be22361ad909 Kids of Set::{Circle,Line,Rectangle} should be Set::Points, not Points --- diff --git a/lib/LaTeX/TikZ/Set/Circle.pm b/lib/LaTeX/TikZ/Set/Circle.pm index b1d83b8..f1bbeab 100644 --- a/lib/LaTeX/TikZ/Set/Circle.pm +++ b/lib/LaTeX/TikZ/Set/Circle.pm @@ -15,6 +15,8 @@ Version 0.01 our $VERSION = '0.01'; +use LaTeX::TikZ::Set::Point; + use LaTeX::TikZ::Tools; use Any::Moose; @@ -24,8 +26,9 @@ with 'LaTeX::TikZ::Set::Op'; has 'center' => ( is => 'ro', - does => 'LaTeX::TikZ::Point', + isa => 'LaTeX::TikZ::Set::Point', required => 1, + coerce => 1, ); subtype 'LaTeX::TikZ::Set::Circle::Radius' diff --git a/lib/LaTeX/TikZ/Set/Line.pm b/lib/LaTeX/TikZ/Set/Line.pm index 6e73e38..13c4618 100644 --- a/lib/LaTeX/TikZ/Set/Line.pm +++ b/lib/LaTeX/TikZ/Set/Line.pm @@ -15,20 +15,24 @@ Version 0.01 our $VERSION = '0.01'; +use LaTeX::TikZ::Set::Point; + use Any::Moose; with 'LaTeX::TikZ::Set::Op'; has 'from' => ( is => 'ro', - does => 'LaTeX::TikZ::Point', + isa => 'LaTeX::TikZ::Set::Point', required => 1, + coerce => 1, ); has 'to' => ( is => 'ro', - does => 'LaTeX::TikZ::Point', + isa => 'LaTeX::TikZ::Set::Point', required => 1, + coerce => 1, ); sub path { diff --git a/lib/LaTeX/TikZ/Set/Rectangle.pm b/lib/LaTeX/TikZ/Set/Rectangle.pm index 88af295..ddb66fc 100644 --- a/lib/LaTeX/TikZ/Set/Rectangle.pm +++ b/lib/LaTeX/TikZ/Set/Rectangle.pm @@ -15,20 +15,24 @@ Version 0.01 our $VERSION = '0.01'; +use LaTeX::TikZ::Set::Point; + use Any::Moose; with 'LaTeX::TikZ::Set::Op'; has 'from' => ( is => 'ro', - does => 'LaTeX::TikZ::Point', + isa => 'LaTeX::TikZ::Set::Point', required => 1, + coerce => 1, ); has 'to' => ( is => 'ro', - does => 'LaTeX::TikZ::Point', + isa => 'LaTeX::TikZ::Set::Point', required => 1, + coerce => 1, ); has 'width' => (