Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 0.9.4

Bug #8175 Error in reference with the Excel ColorIndex colors
Submitted: 2006-07-10 18:40 UTC
From: guillaume at cybercat dot ca Assigned: progi1984
Status: Closed Package: Spreadsheet_Excel_Writer
PHP Version: 5.1.4 OS: N/A
Roadmaps: (Not assigned)    
Subscription  


 [2006-07-10 18:40 UTC] guillaume at cybercat dot ca (Guillaume Hébert)
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).

Comments

 [2009-08-05 17:24 UTC] progi1984 (Franck Lefevre)
-Status: Open +Status: Closed -Assigned To: +Assigned To: progi1984
Open the http://sc.openoffice.org/excelfileformat.pdf Go the page 196 (5.74.3 Built-In Default Colour Tables). You have colour tables (for biff5 and biff8). And in your case, violet (alias color #21 on the another webpage) corresponds to 0x1C in BIFF8.