Subject: | Graphics::Primitve::Brush: unnecessary restriction to Int for "width" member |
Graphics::Primitve::Brush defines an "Int" restriction for the member "width":
has 'width' => ( is => 'rw', isa => 'Int', default => sub { 0 } );
This is unnecessary strict. "Num" is better, as underlying drivers may allow floating numbers here. Especially the Cairo driver allows "double" for set_line_width and many other methods.
I did not check other type restrictions for other members and classes, but it's possible that more members should be allowed to a "Num".
Regards,
Slaven