Spreadsheet_Excel_Writer
[ class tree: Spreadsheet_Excel_Writer ] [ index: Spreadsheet_Excel_Writer ] [ all elements ]

Class: Spreadsheet_Excel_Writer_Format

Source Location: /Spreadsheet_Excel_Writer-0.9.3/Spreadsheet/Excel/Writer/Format.php

Class Overview

PEAR
   |
   --Spreadsheet_Excel_Writer_Format

Class for generating Excel XF records (formats)


Author(s):

Variables

Methods


Inherited Variables

Inherited Methods


Class Details

[line 45]
Class for generating Excel XF records (formats)


[ Top ]


Class Variables

$font_index =

[line 57]

Index to the FONT record.

Type:   integer


[ Top ]



Method Detail

getFont   [line 447]

string getFont( )

Generate an Excel BIFF FONT record.
  • Return: The FONT record

[ Top ]

getFontKey   [line 503]

string getFontKey( )

Returns a unique hash key for a font.

Used by Spreadsheet_Excel_Writer_Workbook::_storeAllFonts()

The elements that form the key are arranged to increase the probability of generating a unique key. Elements that hold a large range of numbers (eg. _color) are placed between two binary elements such as _italic

  • Return: A key for this font

[ Top ]

getXf   [line 315]

string getXf( string $style)

Generate an Excel BIFF XF record (style or cell).
  • Return: The XF record

Parameters:

string   $style   —  The type of the XF record ('style' or 'cell').

[ Top ]

getXfIndex   [line 519]

integer getXfIndex( )

Returns the index used by Spreadsheet_Excel_Writer_Worksheet::_XF()
  • Return: The index for the XF record

[ Top ]

setAlign   [line 586]

void setAlign( string $location)

Set cell alignment.
  • Access: public

Parameters:

string   $location   —  alignment for the cell ('left', 'right', etc...).

[ Top ]

setBgColor   [line 903]

void setBgColor( mixed $color)

Sets the cell's background color
  • Access: public

Parameters:

mixed   $color   —  either a string (like 'blue'), or an integer (range is [8...63]).

[ Top ]

setBold   [line 732]

void setBold( [integer $weight = 1])

Sets the boldness of the text.

Bold has a range 100..1000.

  1. (400) is normal. 1 (700) is bold.

  • Access: public

Parameters:

integer   $weight   —  Weight for the text, 0 maps to 400 (normal text),

[ Top ]

setBorder   [line 805]

void setBorder( integer $style)

Set cells borders to the same style
  • Access: public

Parameters:

integer   $style   —  style to apply for all cell borders. 1 => thin, 2 => thick.

[ Top ]

setBorderColor   [line 825]

void setBorderColor( mixed $color)

Sets all the cell's borders to the same color
  • Access: public

Parameters:

mixed   $color   —  The color we are setting. Either a string (like 'blue'), or an integer (range is [8...63]).

[ Top ]

setBottom   [line 760]

void setBottom( integer $style)

Sets the width for the bottom border of the cell
  • Access: public

Parameters:

integer   $style   —  style of the cell border. 1 => thin, 2 => thick.

[ Top ]

setBottomColor   [line 839]

void setBottomColor( mixed $color)

Sets the cell's bottom border color
  • Access: public

Parameters:

mixed   $color   —  either a string (like 'blue'), or an integer (range is [8...63]).

[ Top ]

setColor   [line 918]

void setColor( mixed $color)

Sets the cell's color
  • Access: public

Parameters:

mixed   $color   —  either a string (like 'blue'), or an integer (range is [8...63]).

[ Top ]

setFgColor   [line 888]

void setFgColor( mixed $color)

Sets the cell's foreground color
  • Access: public

Parameters:

mixed   $color   —  either a string (like 'blue'), or an integer (range is [8...63]).

[ Top ]

setFontFamily   [line 1104]

void setFontFamily( $font_family, string $fontfamily)

Sets the font family name.
  • Access: public

Parameters:

string   $fontfamily   —  The font family name. Possible values are: 'Times New Roman', 'Arial', 'Courier'.
   $font_family   — 

[ Top ]

setHAlign   [line 644]

void setHAlign( string $location)

Set cell horizontal alignment.
  • Access: public

Parameters:

string   $location   —  alignment for the cell ('left', 'right', etc...).

[ Top ]

setItalic   [line 953]

void setItalic( )

Sets the font style as italic
  • Access: public

[ Top ]

setLeft   [line 782]

void setLeft( integer $style)

Sets the width for the left border of the cell
  • Access: public

Parameters:

integer   $style   —  style of the cell left border. 1 => thin, 2 => thick.

[ Top ]

setLeftColor   [line 863]

void setLeftColor( mixed $color)

Sets the cell's left border color
  • Access: public

Parameters:

mixed   $color   —  either a string (like 'blue'), or an integer (range is [8...63]).

[ Top ]

setLocked   [line 1082]

void setLocked( )

Locks a cell.
  • Access: public

[ Top ]

setMerge   [line 717]

void setMerge( )

This is an alias for the unintuitive setAlign('merge')
  • Access: public

[ Top ]

setNumFormat   [line 1030]

void setNumFormat( integer $num_format)

Sets the numeric format.

It can be date, time, currency, etc...

  • Access: public

Parameters:

integer   $num_format   —  The numeric format.

[ Top ]

setOutLine   [line 1050]

void setOutLine( )

Sets outlining for a font.
  • Access: public

[ Top ]

setPattern   [line 931]

void setPattern( [integer $arg = 1])

Sets the fill pattern attribute of a cell
  • Access: public

Parameters:

integer   $arg   —  Optional. Defaults to 1. Meaningful values are: 0-18,
  1. meaning no background.

[ Top ]

setRight   [line 793]

void setRight( integer $style)

Sets the width for the right border of the cell
  • Access: public

Parameters:

integer   $style   —  style of the cell right border. 1 => thin, 2 => thick.

[ Top ]

setRightColor   [line 875]

void setRightColor( mixed $color)

Sets the cell's right border color
  • Access: public

Parameters:

mixed   $color   —  either a string (like 'blue'), or an integer (range is [8...63]).

[ Top ]

setScript   [line 1072]

void setScript( integer $script)

Sets the script type of the text
  • Access: public

Parameters:

integer   $script   —  The value for script type. Possible values are:
  1. => superscript, 2 => subscript.

[ Top ]

setShadow   [line 1060]

void setShadow( )

Sets font as shadow.
  • Access: public

[ Top ]

setSize   [line 964]

void setSize( integer $size)

Sets the font size
  • Access: public

Parameters:

integer   $size   —  The font size (in pixels I think).

[ Top ]

setStrikeOut   [line 1040]

void setStrikeOut( )

Sets font as strikeout.
  • Access: public

[ Top ]

setTextRotation   [line 986]

void setTextRotation( integer $angle)

Sets the orientation of the text
  • Access: public

Parameters:

integer   $angle   —  The rotation angle for the text (clockwise). Possible

[ Top ]

setTextWrap   [line 974]

void setTextWrap( )

Sets text wrapping
  • Access: public

[ Top ]

setTop   [line 771]

void setTop( integer $style)

Sets the width for the top border of the cell
  • Access: public

Parameters:

integer   $style   —  style of the cell top border. 1 => thin, 2 => thick.

[ Top ]

setTopColor   [line 851]

void setTopColor( mixed $color)

Sets the cell's top border color
  • Access: public

Parameters:

mixed   $color   —  either a string (like 'blue'), or an integer (range is [8...63]).

[ Top ]

setUnderline   [line 943]

void setUnderline( integer $underline)

Sets the underline of the text
  • Access: public

Parameters:

integer   $underline   —  The value for underline. Possible values are:
  1. => underline, 2 => double underline.

[ Top ]

setUnLocked   [line 1092]

void setUnLocked( )

Unlocks a cell. Useful for unprotecting particular cells of a protected sheet.
  • Access: public

[ Top ]

setVAlign   [line 684]

void setVAlign( string $location)

Set cell vertical alignment.
  • Access: public

Parameters:

string   $location   —  alignment for the cell ('top', 'vleft', 'vright', etc...).

[ Top ]


Documentation generated on Mon, 11 Mar 2019 15:47:14 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.