use Excel::Template::Format;
# This is a helper object. It is not instantiated by the user, nor does it
-# represent an XML object. Rather, every container will use this object to
+# represent an XML node. Rather, every container will use this object to
# maintain the context for its children.
my %isAbsolute = map { $_ => ~~1 } qw(
my $self = $class->SUPER::new(@_);
$self->{ACTIVE_WORKSHEET} = undef;
- $self->{ACTIVE_FORMAT} = Excel::Template::Format->blank_format($self);
+ $self->{FORMAT_OBJECT} = Excel::Template::Format->new;
+ $self->{ACTIVE_FORMAT} = $self->{FORMAT_OBJECT}->blank_format($self);
$self->{WORKSHEET_NAMES} = undef;
$self->{__MARKS} = {};
return $prev_val unless defined $obj_val;
# Prevent divide-by-zero issues.
- return $val if $op eq '/' and $val == 0;
+ return $prev_val if $op eq '/' and $val == 0;
my $new_val;
for ($op)
return @{ $self->{REFERENCES}{$ref}[-1] };
}
+sub format_object { $_[0]{FORMAT_OBJECT} }
+
1;
__END__
=head2 add_reference
+=head2 format_object
+
=head2 get
=head2 get_all_references