Issue 120576

Summary: [From Symphony]the background color from table style are lost for table in the docx file
Product: Writer Reporter: bjcheny <companycy>
Component: open-importAssignee: AOO issues mailing list <issues>
Status: CLOSED FIXED QA Contact:
Severity: Normal    
Priority: P3 CC: bjdujing, companycy, liushenf, zhangjf
Version: 4.0.0-dev   
Target Milestone: 4.0.0   
Hardware: All   
OS: Windows XP   
Issue Type: ENHANCEMENT Latest Confirmation in: ---
Developer Difficulty: ---
Attachments:
Description Flags
Sample docx has table style applied
none
patch for i120576 to fix background color in table style in docx
none
patch for background color in table style in docx zhangjf: review+

Description bjcheny 2012-08-15 06:04:40 UTC
Created attachment 78945 [details]
Sample docx has table style applied

Check all tables in the sample file "test document formatting.docx", and background color from table styles in some tables are different from MS.
Comment 1 bjcheny 2012-08-16 03:03:19 UTC
Created attachment 78970 [details]
patch for i120576 to fix background color in table style in docx

Patch for i120576 to fix background color in table style in docx.

It is based on the knowledge of background color from wiki on table style as below:
http://wiki.openoffice.org/wiki/Table_Style_in_Writerfilter

The change is composed of below parts:
1. For the w:tcPr under w:style, it's used for whole table. It should be sprmed.
2. On how to apply different kinds of table styles, it follows the sequence from wiki as below. That means ne/nw/se/sw table style can overwrite all other types if existing.

wholeTable
band1Horz band2Horz
band1Vert band2Vert
firstCol lastCol
firstRow lastRow
neCell nwCell seCell swCell

3. Fix a typo for resetRowProp. It's related to all row properties.
Comment 2 bjcheny 2012-08-21 08:17:29 UTC
Created attachment 79033 [details]
patch for background color in table style in docx

Change path for patch from writerfilter to main when creating.
Comment 3 zhang jianfang 2012-08-26 12:41:19 UTC
Comment on attachment 79033 [details]
patch for background color in table style in docx

Thanks, the wiki document explain the fix clearly. I will deliver it.
Comment 4 SVN Robot 2012-08-26 12:55:41 UTC
"zhangjf" committed SVN revision 1377430 into trunk:
#i120576#, the background color from table style are lost for table in the do...
Comment 5 zhang jianfang 2012-08-26 12:56:21 UTC
Change to resolved state
Comment 6 Du Jing 2012-08-28 01:51:53 UTC
verified on the build 1377620
Comment 7 Shenfeng Liu 2012-10-09 05:44:00 UTC
set Target Milestone to AOO 3.5.0 for PM purpose.