PEAR is archived and read-only

This mirror preserves historical PEAR package releases and metadata so existing references remain available.

Home » File Formats » Spreadsheet_Excel_Writer » Bug #8175

Error in reference with the Excel ColorIndex colors

Details

Submitted2006-07-10 18:40 UTC
Fromguillaume at cybercat dot ca
Assignedprogi1984
StatusClosed
PackageSpreadsheet_Excel_Writer
PHP Version5.1.4
OSN/A
Roadmaps(Not assigned)

Comments

[2006-07-10 18:40 UTC] guillaume at cybercat dot ca

Description:
------------
In the "Format::setFgColor" section of the documentation, there's a link pointing to:
http://www.mvps.org/dmcritchie/excel/colors.htm

The text following that link reads:
"Beware that the color indexes listed there are displaced by 1 with respect to those used by Spreadsheet_Excel_Writer."

I believe the color indexes are displaced by 7 (not by 1 as stated in the documentation).

Test script:
---------------
$foo =& $workbook->addformat();
$foo->setFgColor(22);
$worksheet->writeString(1, 1, 'FOOBAR', $foo);

Expected result:
----------------
I expect the background to be violet (color #21).

Actual result:
--------------
The background is Gray 25% (color #15).