- Fixed Makefile.PL so that it uses PM_FILTER instead of rolling its own
[p5sagit/Excel-Template.git] / lib / Excel / Template / Element / Formula.pm
1 package Excel::Template::Element::Formula;
2
3 use strict;
4
5 BEGIN {
6     use vars qw(@ISA);
7     @ISA = qw(Excel::Template::Element::Cell);
8
9     use Excel::Template::Element::Cell;
10 }
11
12 sub render { $_[0]->SUPER::render( $_[1], 'write_formula' ) }
13 #{
14 #    my $self = shift;
15 #    my ($context) = @_;
16 #
17 #    return $self->SUPER::render( $context, 'write_formula' );
18 #}
19
20 1;
21 __END__
22
23 =head1 NAME
24
25 Excel::Template::Element::Formula - Excel::Template::Element::Formula
26
27 =head1 PURPOSE
28
29 To write formulas to the worksheet
30
31 =head1 NODE NAME
32
33 FORMULA
34
35 =head1 INHERITANCE
36
37 Excel::Template::Element::Cell
38
39 =head1 ATTRIBUTES
40
41 All attributes a CELL can have, a FORMULA can have, including the ability to be
42 referenced using the 'ref' attribute.
43
44 =head1 CHILDREN
45
46 None
47
48 =head1 EFFECTS
49
50 This will consume one column on the current row. 
51
52 =head1 DEPENDENCIES
53
54 None
55
56 =head1 USAGE
57
58   <formula text="=(1 + 2)"/>
59   <formula>=SUM(A1:A5)</formula>
60
61   <formula text="$Param2"/>
62   <formula>=(A1 + <var name="Param">)</formula>
63
64 In the above example, four formulas are written out. The first two have the
65 formula hard-coded. The second two have variables. The third and fourth items
66 have another thing that should be noted. If you have a formula where you want a
67 variable in the middle, you have to use the latter form. Variables within
68 parameters are the entire parameter's value.
69
70 =head1 AUTHOR
71
72 Rob Kinyon (rob.kinyon@gmail.com)
73
74 =head1 SEE ALSO
75
76 CELL
77
78 =cut