summaryrefslogtreecommitdiffstats
path: root/lib/Spreadsheet/Template.pm
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Spreadsheet/Template.pm')
-rw-r--r--lib/Spreadsheet/Template.pm36
1 files changed, 26 insertions, 10 deletions
diff --git a/lib/Spreadsheet/Template.pm b/lib/Spreadsheet/Template.pm
index 2e4fe61..4b879c8 100644
--- a/lib/Spreadsheet/Template.pm
+++ b/lib/Spreadsheet/Template.pm
@@ -45,7 +45,9 @@ been preprocessed is a JSON file, with a structure that looks like this:
"name" : "Sheet1",
"row_heights" : [ 18, 18, 18 ],
"selection" : [ 0, 0 ],
- "autofilter" : [ 0, 0, 0, 3],
+ "autofilter" : [
+ [ [0, 0], [0, 2] ]
+ ],
"cells" : [
[
{
@@ -106,15 +108,16 @@ been preprocessed is a JSON file, with a structure that looks like this:
}
]
],
- merge : [
- ["contents":"Merged Contents","format":{"color":#000000"},
- "type":"string",
- "first_row": 0,
- "first_col": 0,
- "last_row" : 0,
- "last_col" : 3
- ]
- ]
+ "merge" : [
+ {
+ "range" : [ [1, 0], [1, 2] ],
+ "contents" : "Merged Contents",
+ "format" : {
+ "color" : "#000000"
+ },
+ "type" : "string"
+ }
+ ]
}
]
}
@@ -163,11 +166,24 @@ spreadsheet.
An array of two numbers corresponding to the (zero-based) row and column of the
cell that should be selected when the worksheet is first displayed.
+=item autofilter
+
+Enables autofilter behavior for each range of cells listed. Cell ranges are
+specified by an array of two arrays of two numbers, corresponding to the row
+and column of the top left and bottom right cell of the autofiltered range.
+
=item cells
An array of arrays of cell objects. Each innermost array represents a row,
containing all of the cell data for that row.
+=item merge
+
+An array of merge objects. Merge objects are identical to cell objects, except
+that they contain an additional C<range> key, which has a value of an array of
+two arrays of two numbers, corresponding to the row and column of the top left
+and bottom right cell of the range to be merged.
+
=back
=head2 cell