Revision history for Perl distribution Excel::Template
-0.26 Fri Jun 02 15:30:00 2005
+0.26 Thu Jun 01 17:00:00 2005
- Fixed how widths are whitelisted to allow '.' for fractions
- - Fixed how certain formats are copied
- - Added <image>
- - Added <freezepanes>
0.25 Thu May 26 11:00:00 2005
- Changed how the template file is opened to use 3-arg open() if available
lib/Excel/Template/Element/Backref.pm
lib/Excel/Template/Element/Cell.pm
lib/Excel/Template/Element/Formula.pm
-lib/Excel/Template/Element/FreezePanes.pm
lib/Excel/Template/Element/Image.pm
lib/Excel/Template/Element/Range.pm
lib/Excel/Template/Element/Var.pm
use Excel::Template::Element;
}
-sub render {
- my $self = shift;
- my ($context) = @_;
-
- my ($row, $col, $path, $offset, $scale) = map {
- $context->get($self, $_)
- } qw( ROW COL PATH OFFSET SCALE );
-
- my @offsets = (0,0);
- if ( $offset =~ /^\s*([\d.]+)\s*,\s*([\d.]+)/ ) {
- @offsets = ($1,$2);
- }
-
- my @scales = (0,0);
- if ( $scale =~ /^\s*([\d.]+)\s*,\s*([\d.]+)/ ) {
- @scales = ($1,$2);
- }
-
- $context->active_worksheet->insert_bitmap(
- $row, $col, $path, @offsets, @scales,
- );
-
- return 1;
-}
-
-sub deltas {
- return {
- COL => +1,
- };
-}
-
1;
__END__
=head1 NODE NAME
-IMAGE
+CELL
=head1 INHERITANCE
L<ELEMENT|Excel::Template::Element>
-=head1 EFFECTS
-
-This will consume one column in the current row.
-
=head1 DEPENDENCIES
None
=head1 USAGE
- <image path="/Some/Full/Path" />
- <image path="/Some/Full/Path" offset="2,5" />
- <image path="/Some/Full/Path" scale="2,0.4" />
- <image path="/Some/Full/Path" offset="4,0" scale="0,2" />
-
-Please see L<Spreadsheet::WriteExcel/> for more information about the offset and scaling options as well as any other restrictions that might be in place. This node does B<NOT> perform any sort of validation upon your parameters. You are assumed to know what you are doing.
-
-Note that the offset and scaling values are "X,Y". You I<must> provide both values, even if the Y value is 0. If you provide a 0 value for either scaling option, L<Spreadsheet::WriteExcel/> will default that to 1.
+ <image path="/Some/Full/Path"/>
=head1 AUTHOR