https://bugs.documentfoundation.org/show_bug.cgi?id=123189

            Bug ID: 123189
           Summary: DOCX FILEOPEN Table level fill color setting in DOCX
                    documents is ignored by Microsoft Word but not by
                    LibreOffice Writer
           Product: LibreOffice
           Version: 6.3.0.0.alpha0+ Master
          Hardware: All
                OS: All
            Status: UNCONFIRMED
          Severity: normal
          Priority: medium
         Component: Writer
          Assignee: [email protected]
          Reporter: [email protected]

Created attachment 148921
  --> https://bugs.documentfoundation.org/attachment.cgi?id=148921&action=edit
Example file from Word 2013

Microsoft Word stores the table level background fill color setting in OOXML
(DOCX) files, but doesn't actually use it. This causes problems, when there is
a fill color set on the table level, but the fill color of the individual cells
is set to auto.

This bug can only be reproduced by using Microsoft Word.

Steps to reproduce:
    1. Create a new text document in Microsoft Word.
    2. Insert a 1 column wide, 3 row height table.
    3. Select the whole table and set the background fill color for the whole
table to black.
    4. select the second and third rows and change the background fill to auto.
    5. Delete the first row of the table.
    6. Save the file as DOCX.
    7. Open the file both in LibreOffice Writer and Microsoft Word.

Actual results:
The background in LibreOffice Writer turns black because the table level
setting is interpreted.

Expected results:
LibreOffice Writer should ignore the table level background color fill setting
and just use the per cell level settings just like Microsoft Word does.

Additional details:
After poking around on the user interface and getting an understanding what
actually happens on the XML level I determined, that Microsoft Word doesn't
actually have a table level background fill color option despite what it tells:

1. The user can set a table level fill color but this just actually turns all
individual cell setting at once. This is evident if you change individual cells
fill color after changing the “table” fill color: When you check the “table”
level setting you will actually see the background color of the selected cell
and not what was formerly set as “table” level setting.

2. Changing the fill color of an individual cell to “auto” turns it into color
of the background behind the table, and not the color of the table, because the
table doesn't actually have a color, only the cells have. This behavior is the
complete opposite of what LibreOffice Writer does, which actually has a real
table level background fill property.

3. Despite all of the above, if a table level fill color was set when the
document was edited it is still stored in the XML file somewhere between
<w:tbl> (table) and the first <w:tc> (table cell) tag (so, as a table level
setting) in a tag like this: <w:shd w:val="clear" w:color="auto"
w:fill="000000" w:themeFill="text1"/>. This setting is kept in the file even if
every single cell has been altered or deleted after the table level fill color
was set – and despite that Microsoft Word doesn't even have a “real” table
level fill color setting. The best thing to do is probably ignore this
altogether when importing a DOCX file.

Version: 6.3.0.0.alpha0+
Build ID: fcc5fc76c33de566cb2d02be541dcbde29d1eb8a
CPU threads: 4; OS: Windows 6.3; UI render: GL; VCL: win; 
Locale: hu-HU (hu_HU); UI-Language: en-US
Calc: threaded

-- 
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Libreoffice-bugs mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs

Reply via email to