blib/lib/Graphics/Primitive/Image.pm untested

filter: Statementstmt 0.0% 0 / 13 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 0.0% 0 / 2 Podpod n/a totaltotal 0.0% 0 / 15 SCAR 6.9
CC
1
Cov
0%
BEGIN
2.0
BEGIN
2.0
CRAP 2.0
1 package Graphics::Primitive::Image;
2 use Moose;
3 use MooseX::Storage;
4  
5 extends 'Graphics::Primitive::Component';
6  
7 with qw(MooseX::Clone Graphics::Primitive::Aligned);
8 with Storage (format => 'JSON', io => 'File');
9  
10 has image => (
11 is => 'rw',
12 isa => 'Str'
13 );
14 has scale => (
15 is => 'rw',
16 isa => 'ArrayRef',
17 );
18  
19 __PACKAGE__->meta->make_immutable;
20  
21 1;
22 __END__
23 =head1 NAME
24  
25 Graphics::Primitive::Image - Image component
26  
27 =head1 DESCRIPTION
28  
29 Graphics::Primitive::Image is a Component that displays in image.
30  
31 =head1 SYNOPSIS
32  
33 use Graphics::Primitive::Image;
34  
35 my $img = Graphics::Primitive::Image->new(
36 image => '/path/to/filename'
37 );
38  
39 =head1 WARNING
40  
41 B<THIS COMPONENT IS EXPERIMENTAL.>
42  
43 =head1 METHODS
44  
45 =head2 Constructor
46  
47 =over 4
48  
49 =item I<new>
50  
51 Creates a new Graphics::Primitive::Image.
52  
53 =back
54  
55 =head2 Instance Methods
56  
57 =over 4
58  
59 =item I<horizontal_alignment>
60  
61 Set/Get the horizontal alignment of this component's image.
62  
63 =item I<image>
64  
65 Set/Get the filename of this components image.
66  
67 =item I<vertical_alignment>
68  
69 Set/Get the vertical alignment of this component's image.
70  
71 =back
72  
73 =head1 AUTHOR
74  
75 Cory Watson, C<< <gphat@cpan.org> >>
76  
77 =head1 COPYRIGHT & LICENSE
78  
79 Copyright 2008-2010 by Cory G Watson.
80  
81 This program is free software; you can redistribute it and/or modify it
82 under the same terms as Perl itself.