1Spreadsheet::ParseExcelU:s:eWrorCkosnhtereitb(u3t)ed PerSlprDeoacdusmheenetta:t:iPoanrseExcel::Worksheet(3)
2
3
4
5   get_tab_color()
6       Return color index of tab, or undef if not set.
7
8   is_sheet_hidden()
9       Return true if sheet is hidden
10
11   is_row_hidden($row)
12       In scalar context, return true if $row is hidden In array context,
13       return an array whose elements are true if the corresponding row is
14       hidden.
15
16   is_col_hidden($col)
17       In scalar context, return true if $col is hidden In array context,
18       return an array whose elements are true if the corresponding column is
19       hidden.
20

NAME

22       Spreadsheet::ParseExcel::Worksheet - A class for Worksheets.
23

SYNOPSIS

25       See the documentation for Spreadsheet::ParseExcel.
26

DESCRIPTION

28       This module is used in conjunction with Spreadsheet::ParseExcel. See
29       the documentation for Spreadsheet::ParseExcel.
30

Methods

32       The "Spreadsheet::ParseExcel::Worksheet" class encapsulates the
33       properties of an Excel worksheet. It has the following methods:
34
35           $worksheet->get_cell()
36           $worksheet->row_range()
37           $worksheet->col_range()
38           $worksheet->get_name()
39           $worksheet->get_h_pagebreaks()
40           $worksheet->get_v_pagebreaks()
41           $worksheet->get_merged_areas()
42           $worksheet->get_row_heights()
43           $worksheet->get_col_widths()
44           $worksheet->get_default_row_height()
45           $worksheet->get_default_col_width()
46           $worksheet->get_header()
47           $worksheet->get_footer()
48           $worksheet->get_margin_left()
49           $worksheet->get_margin_right()
50           $worksheet->get_margin_top()
51           $worksheet->get_margin_bottom()
52           $worksheet->get_margin_header()
53           $worksheet->get_margin_footer()
54           $worksheet->get_paper()
55           $worksheet->get_start_page()
56           $worksheet->get_print_order()
57           $worksheet->get_print_scale()
58           $worksheet->get_fit_to_pages()
59           $worksheet->is_portrait()
60           $worksheet->is_centered_horizontally()
61           $worksheet->is_centered_vertically()
62           $worksheet->is_print_gridlines()
63           $worksheet->is_print_row_col_headers()
64           $worksheet->is_print_black_and_white()
65           $worksheet->is_print_draft()
66           $worksheet->is_print_comments()
67
68   get_cell($row, $col)
69       Return the "Cell" object at row $row and column $col if it is defined.
70       Otherwise returns undef.
71
72           my $cell = $worksheet->get_cell($row, $col);
73
74   row_range()
75       Returns a two-element list "($min, $max)" containing the minimum and
76       maximum defined rows in the worksheet. If there is no row defined $max
77       is smaller than $min.
78
79           my ( $row_min, $row_max ) = $worksheet->row_range();
80
81   col_range()
82       Returns a two-element list "($min, $max)" containing the minimum and
83       maximum of defined columns in the worksheet. If there is no column
84       defined $max is smaller than $min.
85
86           my ( $col_min, $col_max ) = $worksheet->col_range();
87
88   get_name()
89       The "get_name()" method returns the name of the worksheet.
90
91           my $name = $worksheet->get_name();
92
93   get_h_pagebreaks()
94       The "get_h_pagebreaks()" method returns an array ref of row numbers
95       where a horizontal page break occurs.
96
97           my $h_pagebreaks = $worksheet->get_h_pagebreaks();
98
99       Returns "undef" if there are no pagebreaks.
100
101   get_v_pagebreaks()
102       The "get_v_pagebreaks()" method returns an array ref of column numbers
103       where a vertical page break occurs.
104
105           my $v_pagebreaks = $worksheet->get_v_pagebreaks();
106
107       Returns "undef" if there are no pagebreaks.
108
109   get_merged_areas()
110       The "get_merged_areas()" method returns an array ref of cells that are
111       merged.
112
113           my $merged_areas = $worksheet->get_merged_areas();
114
115       Each merged area is represented as follows:
116
117           [ $start_row, $start_col, $end_row, $end_col]
118
119       Returns "undef" if there are no merged areas.
120
121   get_row_heights()
122       The "get_row_heights()" method returns an array_ref of row heights in
123       scalar context, and an array in list context.
124
125           my $row_heights = $worksheet->get_row_heights();
126
127       Returns "undef" if the property isn't set.
128
129   get_col_widths()
130       The "get_col_widths()" method returns an array_ref of column widths in
131       scalar context, and an array in list context.
132
133           my $col_widths = $worksheet->get_col_widths();
134
135       Returns "undef" if the property isn't set.
136
137   get_default_row_height()
138       The "get_default_row_height()" method returns the default row height
139       for the worksheet. Generally 12.75.
140
141           my $default_row_height = $worksheet->get_default_row_height();
142
143   get_default_col_width()
144       The "get_default_col_width()" method returns the default column width
145       for the worksheet. Generally 8.43.
146
147           my $default_col_width = $worksheet->get_default_col_width();
148
149   get_header()
150       The "get_header()" method returns the worksheet header string. This
151       string can contain control codes for alignment and font properties.
152       Refer to the Excel on-line help on headers and footers or to the
153       Spreadsheet::WriteExcel documentation for set_header().
154
155           my $header = $worksheet->get_header();
156
157       Returns "undef" if the property isn't set.
158
159   get_footer()
160       The "get_footer()" method returns the worksheet footer string. This
161       string can contain control codes for alignment and font properties.
162       Refer to the Excel on-line help on headers and footers or to the
163       Spreadsheet::WriteExcel documentation for set_header().
164
165           my $footer = $worksheet->get_footer();
166
167       Returns "undef" if the property isn't set.
168
169   get_margin_left()
170       The "get_margin_left()" method returns the left margin of the worksheet
171       in inches.
172
173           my $margin_left = $worksheet->get_margin_left();
174
175       Returns "undef" if the property isn't set.
176
177   get_margin_right()
178       The "get_margin_right()" method returns the right margin of the
179       worksheet in inches.
180
181           my $margin_right = $worksheet->get_margin_right();
182
183       Returns "undef" if the property isn't set.
184
185   get_margin_top()
186       The "get_margin_top()" method returns the top margin of the worksheet
187       in inches.
188
189           my $margin_top = $worksheet->get_margin_top();
190
191       Returns "undef" if the property isn't set.
192
193   get_margin_bottom()
194       The "get_margin_bottom()" method returns the bottom margin of the
195       worksheet in inches.
196
197           my $margin_bottom = $worksheet->get_margin_bottom();
198
199       Returns "undef" if the property isn't set.
200
201   get_margin_header()
202       The "get_margin_header()" method returns the header margin of the
203       worksheet in inches.
204
205           my $margin_header = $worksheet->get_margin_header();
206
207       Returns a default value of 0.5 if not set.
208
209   get_margin_footer()
210       The "get_margin_footer()" method returns the footer margin of the
211       worksheet in inches.
212
213           my $margin_footer = $worksheet->get_margin_footer();
214
215       Returns a default value of 0.5 if not set.
216
217   get_paper()
218       The "get_paper()" method returns the printer paper size.
219
220           my $paper = $worksheet->get_paper();
221
222       The value corresponds to the formats shown below:
223
224           Index   Paper format            Paper size
225           =====   ============            ==========
226             0     Printer default         -
227             1     Letter                  8 1/2 x 11 in
228             2     Letter Small            8 1/2 x 11 in
229             3     Tabloid                 11 x 17 in
230             4     Ledger                  17 x 11 in
231             5     Legal                   8 1/2 x 14 in
232             6     Statement               5 1/2 x 8 1/2 in
233             7     Executive               7 1/4 x 10 1/2 in
234             8     A3                      297 x 420 mm
235             9     A4                      210 x 297 mm
236            10     A4 Small                210 x 297 mm
237            11     A5                      148 x 210 mm
238            12     B4                      250 x 354 mm
239            13     B5                      182 x 257 mm
240            14     Folio                   8 1/2 x 13 in
241            15     Quarto                  215 x 275 mm
242            16     -                       10x14 in
243            17     -                       11x17 in
244            18     Note                    8 1/2 x 11 in
245            19     Envelope  9             3 7/8 x 8 7/8
246            20     Envelope 10             4 1/8 x 9 1/2
247            21     Envelope 11             4 1/2 x 10 3/8
248            22     Envelope 12             4 3/4 x 11
249            23     Envelope 14             5 x 11 1/2
250            24     C size sheet            -
251            25     D size sheet            -
252            26     E size sheet            -
253            27     Envelope DL             110 x 220 mm
254            28     Envelope C3             324 x 458 mm
255            29     Envelope C4             229 x 324 mm
256            30     Envelope C5             162 x 229 mm
257            31     Envelope C6             114 x 162 mm
258            32     Envelope C65            114 x 229 mm
259            33     Envelope B4             250 x 353 mm
260            34     Envelope B5             176 x 250 mm
261            35     Envelope B6             176 x 125 mm
262            36     Envelope                110 x 230 mm
263            37     Monarch                 3.875 x 7.5 in
264            38     Envelope                3 5/8 x 6 1/2 in
265            39     Fanfold                 14 7/8 x 11 in
266            40     German Std Fanfold      8 1/2 x 12 in
267            41     German Legal Fanfold    8 1/2 x 13 in
268            256    User defined
269
270       The two most common paper sizes are "1 = "US Letter"" and "9 = A4".
271       Returns 9 by default.
272
273   get_start_page()
274       The "get_start_page()" method returns the page number that printing
275       will start from.
276
277           my $start_page = $worksheet->get_start_page();
278
279       Returns 0 if the property isn't set.
280
281   get_print_order()
282       The "get_print_order()" method returns 0 if the worksheet print "page
283       order" is "Down then over" (the default) or 1 if it is "Over then
284       down".
285
286           my $print_order = $worksheet->get_print_order();
287
288   get_print_scale()
289       The "get_print_scale()" method returns the workbook scale for printing.
290       The print scale factor can be in the range 10 .. 400.
291
292           my $print_scale = $worksheet->get_print_scale();
293
294       Returns 100 by default.
295
296   get_fit_to_pages()
297       The "get_fit_to_pages()" method returns the number of pages wide and
298       high that the printed worksheet page will fit to.
299
300           my ($pages_wide, $pages_high) = $worksheet->get_fit_to_pages();
301
302       Returns (0, 0) if the property isn't set.
303
304   is_portrait()
305       The "is_portrait()" method returns true if the worksheet has been set
306       for printing in portrait mode.
307
308           my $is_portrait = $worksheet->is_portrait();
309
310       Returns 0 if the worksheet has been set for printing in horizontal
311       mode.
312
313   is_centered_horizontally()
314       The "is_centered_horizontally()" method returns true if the worksheet
315       has been centered horizontally for printing.
316
317           my $is_centered_horizontally = $worksheet->is_centered_horizontally();
318
319       Returns 0 if the property isn't set.
320
321   is_centered_vertically()
322       The "is_centered_vertically()" method returns true if the worksheet has
323       been centered vertically for printing.
324
325           my $is_centered_vertically = $worksheet->is_centered_vertically();
326
327       Returns 0 if the property isn't set.
328
329   is_print_gridlines()
330       The "is_print_gridlines()" method returns true if the worksheet print
331       "gridlines" option is turned on.
332
333           my $is_print_gridlines = $worksheet->is_print_gridlines();
334
335       Returns 0 if the property isn't set.
336
337   is_print_row_col_headers()
338       The "is_print_row_col_headers()" method returns true if the worksheet
339       print "row and column headings" option is turned on.
340
341           my $is_print_row_col_headers = $worksheet->is_print_row_col_headers();
342
343       Returns 0 if the property isn't set.
344
345   is_print_black_and_white()
346       The "is_print_black_and_white()" method returns true if the worksheet
347       print "black and white" option is turned on.
348
349           my $is_print_black_and_white = $worksheet->is_print_black_and_white();
350
351       Returns 0 if the property isn't set.
352
353   is_print_draft()
354       The "is_print_draft()" method returns true if the worksheet print
355       "draft" option is turned on.
356
357           my $is_print_draft = $worksheet->is_print_draft();
358
359       Returns 0 if the property isn't set.
360
361   is_print_comments()
362       The "is_print_comments()" method returns true if the worksheet print
363       "comments" option is turned on.
364
365           my $is_print_comments = $worksheet->is_print_comments();
366
367       Returns 0 if the property isn't set.
368

AUTHOR

370       Current maintainer 0.60+: Douglas Wilson dougw@cpan.org
371
372       Maintainer 0.40-0.59: John McNamara jmcnamara@cpan.org
373
374       Maintainer 0.27-0.33: Gabor Szabo szabgab@cpan.org
375
376       Original author: Kawai Takanori kwitknr@cpan.org
377
379       Copyright (c) 2014 Douglas Wilson
380
381       Copyright (c) 2009-2013 John McNamara
382
383       Copyright (c) 2006-2008 Gabor Szabo
384
385       Copyright (c) 2000-2006 Kawai Takanori
386
387       All rights reserved.
388
389       You may distribute under the terms of either the GNU General Public
390       License or the Artistic License, as specified in the Perl README file.
391
392
393
394perl v5.32.1                      2021-01-S2p7readsheet::ParseExcel::Worksheet(3)
Impressum