<?php
/*
* Module written/ported by Xavier Noguer <xnoguer@rezebra.com>
*
* The majority of this is _NOT_ my code. I simply ported it from the
* PERL Spreadsheet::WriteExcel module.
*
* The author of the Spreadsheet::WriteExcel module is John McNamara
* <jmcnamara@cpan.org>
*
* I _DO_ maintain this code, and John McNamara has nothing to do with the
* porting of this code to PHP. Any questions directly related to this
* class library should be directed to me.
*
* License Information:
*
* Spreadsheet_Excel_Writer: A library for generating Excel Spreadsheets
* Copyright (c) 2002-2003 Xavier Noguer xnoguer@rezebra.com
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
require_once EXCEL_WRITER_ROOT . 'Writer/Parser.php';
require_once EXCEL_WRITER_ROOT . 'Writer/BIFFwriter.php';
/**
* Class for generating Excel Spreadsheets
*
* @author Xavier Noguer <xnoguer@rezebra.com>
* @category FileFormats
* @package Spreadsheet_Excel_Writer
*/
class Spreadsheet_Excel_Writer_Worksheet extends Spreadsheet_Excel_Writer_BIFFwriter
{
/**
* Name of the Worksheet
* @var string
*/
var $name;
/**
* Index for the Worksheet
* @var integer
*/
var $index;
/**
* Reference to the (default) Format object for URLs
* @var object Format
*/
var $_url_format;
/**
* Reference to the parser used for parsing formulas
* @var object Format
*/
var $_parser;
/**
* Filehandle to the temporary file for storing data
* @var resource
*/
var $_filehandle;
/**
* Boolean indicating if we are using a temporary file for storing data
* @var bool
*/
var $_using_tmpfile;
/**
* Maximum number of rows for an Excel spreadsheet (BIFF5)
* @var integer
*/
var $_xls_rowmax;
/**
* Maximum number of columns for an Excel spreadsheet (BIFF5)
* @var integer
*/
var $_xls_colmax;
/**
* Maximum number of characters for a string (LABEL record in BIFF5)
* @var integer
*/
var $_xls_strmax;
/**
* First row for the DIMENSIONS record
* @var integer
* @see _storeDimensions()
*/
var $_dim_rowmin;
/**
* Last row for the DIMENSIONS record
* @var integer
* @see _storeDimensions()
*/
var $_dim_rowmax;
/**
* First column for the DIMENSIONS record
* @var integer
* @see _storeDimensions()
*/
var $_dim_colmin;
/**
* Last column for the DIMENSIONS record
* @var integer
* @see _storeDimensions()
*/
var $_dim_colmax;
/**
* Array containing format information for columns
* @var array
*/
var $_colinfo;
/**
* Array containing the selected area for the worksheet
* @var array
*/
var $_selection;
/**
* Array containing the panes for the worksheet
* @var array
*/
var $_panes;
/**
* The active pane for the worksheet
* @var integer
*/
var $_active_pane;
/**
* Bit specifying if panes are frozen
* @var integer
*/
var $_frozen;
/**
* Bit specifying if the worksheet is selected
* @var integer
*/
var $selected;
/**
* The paper size (for printing) (DOCUMENT!!!)
* @var integer
*/
var $_paper_size;
/**
* Bit specifying paper orientation (for printing). 0 => landscape, 1 => portrait
* @var integer
*/
var $_orientation;
/**
* The page header caption
* @var string
*/
var $_header;
/**
* The page footer caption
* @var string
*/
var $_footer;
/**
* The horizontal centering value for the page
* @var integer
*/
var $_hcenter;
/**
* The vertical centering value for the page
* @var integer
*/
var $_vcenter;
/**
* The margin for the header
* @var float
*/
var $_margin_head;
/**
* The margin for the footer
* @var float
*/
var $_margin_foot;
/**
* The left margin for the worksheet in inches
* @var float
*/
var $_margin_left;
/**
* The right margin for the worksheet in inches
* @var float
*/
var $_margin_right;
/**
* The top margin for the worksheet in inches
* @var float
*/
var $_margin_top;
/**
* The bottom margin for the worksheet in inches
* @var float
*/
var $_margin_bottom;
/**
* First row to reapeat on each printed page
* @var integer
*/
var $title_rowmin;
/**
* Last row to reapeat on each printed page
* @var integer
*/
var $title_rowmax;
/**
* First column to reapeat on each printed page
* @var integer
*/
var $title_colmin;
/**
* First row of the area to print
* @var integer
*/
var $print_rowmin;
/**
* Last row to of the area to print
* @var integer
*/
var $print_rowmax;
/**
* First column of the area to print
* @var integer
*/
var $print_colmin;
/**
* Last column of the area to print
* @var integer
*/
var $print_colmax;
/**
* Whether to use outline.
* @var integer
*/
var $_outline_on;
/**
* Auto outline styles.
* @var bool
*/
var $_outline_style;
/**
* Whether to have outline summary below.
* @var bool
*/
var $_outline_below;
/**
* Whether to have outline summary at the right.
* @var bool
*/
var $_outline_right;
/**
* Outline row level.
* @var integer
*/
var $_outline_row_level;
/**
* Whether to fit to page when printing or not.
* @var bool
*/
var $_fit_page;
/**
* Number of pages to fit wide
* @var integer
*/
var $_fit_width;
/**
* Number of pages to fit high
* @var integer
*/
var $_fit_height;
/**
* Reference to the total number of strings in the workbook
* @var integer
*/
var $_str_total;
/**
* Reference to the number of unique strings in the workbook
* @var integer
*/
var $_str_unique;
/**
* Reference to the array containing all the unique strings in the workbook
* @var array
*/
var $_str_table;
/**
* Merged cell ranges
* @var array
*/
var $_merged_ranges;
/**
* Charset encoding currently used when calling writeString()
* @var string
*/
var $_input_encoding;
/**
* Constructor
*
* @param string $name The name of the new worksheet