Bug 101757

Summary: Import and export OOXML table styles
Product: LibreOffice Reporter: Yousuf Philips (jay) (retired) <philipz85>
Component: WriterAssignee: Not Assigned <libreoffice-bugs>
Status: NEW ---    
Severity: enhancement CC: aron.budea, heiko.tietze, kelemeng, libreoffice, rb.henschel, rijal.it, ubap.dev, zen
Priority: medium Keywords: filter:ooxml
Version: Inherited From OOo   
Hardware: All   
OS: All   
See Also: https://bugs.documentfoundation.org/show_bug.cgi?id=34391
https://bugs.documentfoundation.org/show_bug.cgi?id=77796
https://bugs.documentfoundation.org/show_bug.cgi?id=136638
https://bugs.documentfoundation.org/show_bug.cgi?id=152711
Whiteboard:
Crash report or crash signature: Regression By:
Bug Depends on:    
Bug Blocks: 88173, 101756, 104444    

Description Yousuf Philips (jay) (retired) 2016-08-27 17:51:50 UTC
With writer now able to handle table styles (bug 34391), as well as import and export ODF table styles, the importing and exporting of OOXML table styles is the next step forward.

Table styles are defined in the /word/styles.xml file as multiple <w:style w:type="table"> tags, and here is the default style assigned to inserted tables.

<w:style w:type="table" w:styleId="TableGrid">
  <w:name w:val="Table Grid" />
  <w:basedOn w:val="TableNormal" />
  <w:uiPriority w:val="59" />
  <w:rsid w:val="00CA4017" />
  <w:pPr>
    <w:spacing w:after="0" w:line="240" w:lineRule="auto" />
  </w:pPr>
  <w:tblPr>
    <w:tblInd w:w="0" w:type="dxa" />
    <w:tblBorders>
      <w:top w:val="single" w:sz="4" w:space="0" w:color="auto" />
      <w:left w:val="single" w:sz="4" w:space="0" w:color="auto" />
      <w:bottom w:val="single" w:sz="4" w:space="0" w:color="auto" />
      <w:right w:val="single" w:sz="4" w:space="0" w:color="auto" />
      <w:insideH w:val="single" w:sz="4" w:space="0" w:color="auto" />
      <w:insideV w:val="single" w:sz="4" w:space="0" w:color="auto" />
    </w:tblBorders>
    <w:tblCellMar>
      <w:top w:w="0" w:type="dxa" />
      <w:left w:w="108" w:type="dxa" />
      <w:bottom w:w="0" w:type="dxa" />
      <w:right w:w="108" w:type="dxa" />
    </w:tblCellMar>
  </w:tblPr>
</w:style>

Tables are associated with a table style (<w:tblStyle>) in /word/document.xml and define which properties/elements of the style are visible on the table or not (<w:tblLook>).

<w:tbl>
  <w:tblPr>
    <w:tblStyle w:val="TableGrid" />
    <w:tblW w:w="0" w:type="auto" />
    <w:tblLook w:val="04A0" w:firstRow="1" w:lastRow="0" w:firstColumn="1" w:lastColumn="0" w:noHBand="0" w:noVBand="1" />
  </w:tblPr>
</w:tbl>

More details can be found in the links below
http://officeopenxml.com/WPstyleTableStyles.php
Comment 1 Buovjaga 2016-12-18 18:09:52 UTC
*** Bug 104689 has been marked as a duplicate of this bug. ***