PHPExcel_Style

# Class: PHPExcel_Style_Color Source Location: /PHPExcel/Style/Color.php
### Class Overview
PHPExcel_Style_Color #### Author(s): #### Copyright: Copyright (c) 2006 - 2011 PHPExcel (http://www.codeplex.com/PHPExcel) Implements interfaces: PHPExcel_IComparable | ### Constants COLOR_BLACK COLOR_BLUE COLOR_DARKBLUE COLOR_DARKGREEN COLOR_DARKRED COLOR_DARKYELLOW COLOR_GREEN COLOR_RED COLOR_WHITE COLOR_YELLOW | ### Methods applyFromArray bindParent changeBrightness __construct getActiveCell getActiveSheet getARGB getBlue getGreen getHashCode getIsSupervisor getRed getRGB getSelectedCells getSharedComponent getStyleArray indexedColor setARGB setRGB __clone
### Class Details [line 36] PHPExcel_Style_Color #### Tags:
copyright: | Copyright (c) 2006 - 2011 PHPExcel (http://www.codeplex.com/PHPExcel)
[ Top ] ### Class Methods ### static method changeBrightness [line 332]
`static string changeBrightness( string $hex, float $adjustPercentage)`
Adjust the brightness of a color #### Tags:
return: | The adjusted colour as an RGB value (e.g. FF00CCCC or CCDDEE
access: | public
#### Parameters:
string | $hex | The colour as an RGB value (e.g. FF00CCCC or CCDDEE
float | $adjustPercentage | The percentage by which to adjust the colour as a float from -1 to 1
[ Top ] ### static method getBlue [line 317]
`static void getBlue( $RGB, [ $hex = true])`
#### Tags:
access: | public
#### Parameters:
| $RGB |
| $hex |
[ Top ] ### static method getGreen [line 309]
`static void getGreen( $RGB, [ $hex = true])`
#### Tags:
access: | public
#### Parameters:
| $RGB |
| $hex |
[ Top ] ### static method getRed [line 301]
`static void getRed( $RGB, [ $hex = true])`
#### Tags:
access: | public
#### Parameters:
| $RGB |
| $hex |
[ Top ] ### static method indexedColor [line 365]
`static PHPExcel_Style_Color indexedColor( int $pIndex, [ $background = false])`
Get indexed color #### Tags:
access: | public
#### Parameters:
int | $pIndex |
| $background |
[ Top ] ### method applyFromArray [line 214]
`PHPExcel_Style_Color applyFromArray( [array $pStyles = null])`
Apply styles from array $objPHPExcel->getActiveSheet()->getStyle('B2')->getFont()->getColor()->applyFromArray( array('rgb' => '808080') ); #### Tags:
throws: | Exception
access: | public
#### Parameters:
array | $pStyles | Array containing style information
[ Top ] ### method bindParent [line 106]
`PHPExcel_Style_Color bindParent( mixed $parent, string $parentPropertyName)`
Bind parent. Only used for supervisor #### Tags:
access: | public
#### Parameters:
mixed | $parent |
string | $parentPropertyName |
[ Top ] ### constructor __construct [line 90]
`PHPExcel_Style_Color __construct( [string $pARGB = PHPExcel_Style_Color::COLOR_BLACK], [ $isSupervisor = false])`
Create a new PHPExcel_Style_Color #### Tags:
access: | public
#### Parameters:
string | $pARGB |
| $isSupervisor |
[ Top ] ### method getActiveCell [line 173]
`string getActiveCell( )`
Get the currently active cell coordinate in currently active sheet. Only used for supervisor #### Tags:
return: | E.g. 'A1'
access: | public
[ Top ] ### method getActiveSheet [line 151]
`PHPExcel_Worksheet getActiveSheet( )`
Get the currently active sheet. Only used for supervisor #### Tags:
access: | public
[ Top ] ### method getARGB [line 237]
`string getARGB( )`
Get ARGB #### Tags:
access: | public
[ Top ] ### method getHashCode [line 453]
`string getHashCode( )`
Get hash code #### Tags:
return: | Hash code
access: | public
[ Top ] ### method getIsSupervisor [line 118]
`boolean getIsSupervisor( )`
Is this a supervisor or a real style component? #### Tags:
access: | public
[ Top ] ### method getRGB [line 268]
`string getRGB( )`
Get RGB #### Tags:
access: | public
[ Top ] ### method getSelectedCells [line 162]
`string getSelectedCells( )`
Get the currently active cell coordinate in currently active sheet. Only used for supervisor #### Tags:
return: | E.g. 'A1'
access: | public
[ Top ] ### method getSharedComponent [line 129]
`PHPExcel_Style_Color getSharedComponent( )`
Get the shared style component for the currently active cell in currently active sheet. Only used for style supervisor #### Tags:
access: | public
[ Top ] ### method getStyleArray [line 184]
`array getStyleArray( array $array)`
Build style array from subcomponents #### Tags:
access: | public
#### Parameters:
array | $array |
[ Top ] ### method setARGB [line 250]
`PHPExcel_Style_Color setARGB( [string $pValue = PHPExcel_Style_Color::COLOR_BLACK])`
Set ARGB #### Tags:
access: | public
#### Parameters:
string | $pValue |
[ Top ] ### method setRGB [line 281]
`PHPExcel_Style_Color setRGB( [string $pValue = '000000'])`
Set RGB #### Tags:
access: | public
#### Parameters:
string | $pValue |
[ Top ] ### method __clone [line 466]
`void __clone( )`
Implement PHP __clone to create a deep clone, not just a shallow copy. #### Tags:
access: | public
[ Top ] ### Class Constants #### COLOR_BLACK = 'FF000000' [line 39] [ Top ] #### COLOR_BLUE = 'FF0000FF' [line 43] [ Top ] #### COLOR_DARKBLUE = 'FF000080' [line 44] [ Top ] #### COLOR_DARKGREEN = 'FF008000' [line 46] [ Top ] #### COLOR_DARKRED = 'FF800000' [line 42] [ Top ] #### COLOR_DARKYELLOW = 'FF808000' [line 48] [ Top ] #### COLOR_GREEN = 'FF00FF00' [line 45] [ Top ] #### COLOR_RED = 'FFFF0000' [line 41] [ Top ] #### COLOR_WHITE = 'FFFFFFFF' [line 40] [ Top ] #### COLOR_YELLOW = 'FFFFFF00' [line 47] [ Top ] Documentation generated on Sun, 27 Feb 2011 16:29:07 -0800 by phpDocumentor 1.4.3