Answered by:
Why is a defined border not showing

Question
-
Hi all;
Please take a look at Bug3193.docx. About half way down on the left is the text "Capital Flows". I think it should have a border to its left, but it does not.
The properties for cell [0] are:
<w:tcBorders> <w:top w:val="nil"/> <w:left w:val="nil"/> <w:bottom w:val="nil"/> </w:tcBorders>
And for cell [1] that contains the text:
<w:tcBorders> <w:top w:val="nil"/> <w:bottom w:val="nil"/> </w:tcBorders>
So there is no cell level setting for the vertical border between cells [0] & [1].
The table properties are:
<w:tblPr> <w:tblStyle w:val="LightList-Accent1"/> <w:tblW w:w="0" w:type="auto"/> <w:tblLook w:val="0420" w:firstRow="1" w:lastRow="0" w:firstColumn="0" w:lastColumn="0" w:noHBand="0" w:noVBand="1"/> </w:tblPr>
So no explicit border settings and it points us to the style ListLight-Accent1. This has:
<w:tblBorders> <w:top w:val="single" w:sz="8" w:space="0" w:color="759AA5" w:themeColor="accent1"/> <w:left w:val="single" w:sz="8" w:space="0" w:color="759AA5" w:themeColor="accent1"/> <w:bottom w:val="single" w:sz="8" w:space="0" w:color="759AA5" w:themeColor="accent1"/> <w:right w:val="single" w:sz="8" w:space="0" w:color="759AA5" w:themeColor="accent1"/> </w:tblBorders>
So this should be the left & right border for cell[1]. Yet no border is drawn.
Why?
thanks - dave
What we did for the last 6 months - Made the world's coolest reporting & docgen system even more amazing
Wednesday, December 28, 2016 9:37 PM
Answers
-
Hello Dave:
Sorry for the delay.
Per analysis and help from teammates (Josh and Tom); we found that the behavior is by-design and is stated in following section of MS-OI29500, excerpt below:
2.1.240 Part 1 Section 17.7.4.17, style (Style Definition)
- The standard does not state any special behavior for "NoList", "DefaultParagraphFont", and "TableNormal" styles.
- Word ignores any child elements of a style element with id "NoList", "DefaultParagraphFont", or "TableNormal".
As the 'tblBorders' is specified in TableNormal style, it will be ignored by Word. In order to make it work, please move the 'tblBorders' to ListTable1Light-Accent5 style.
Thanks.
Tarun Chopra | Escalation Engineer | Open Specifications Support Team
- Proposed as answer by Tarun Chopra - MSFT Tuesday, January 10, 2017 5:49 AM
- Marked as answer by DavidThielen Sunday, July 16, 2017 4:43 PM
Tuesday, January 10, 2017 5:49 AM - The standard does not state any special behavior for "NoList", "DefaultParagraphFont", and "TableNormal" styles.
All replies
-
Hi Dave,
Thanks for the question about the Defined Border. A member of the Open Specification team will be responding to you shortly to work on this issue with you.
Sincerely,
Will Gregg
Thursday, December 29, 2016 4:05 PM -
Hello Dave:
I'll research and get back.
Thanks.
Tarun Chopra | Escalation Engineer | Open Specifications Support Team
Friday, December 30, 2016 12:12 AM -
Hello Dave:
Border will be shown if you add 'insideV' element to your ListLight-Accent1 style like this:
<w:insideV w:val="single" w:sz="8" w:space="0" w:color="759AA5" w:themeColor="accent1"/>
Regards
Tarun Chopra | Escalation Engineer | Open Specifications Support Team
Friday, December 30, 2016 1:33 AM -
Hi Tarun;
Based on what you said, as there is no insideV and insideH defined in the styles, and the cell props have no left/right border, does this mean the insideV/insideH are NONE (makes sense) and therefore there is no left/right border?
Now that I think that through, that makes sense. But can you verify that for me? At present our code uses the table & style props for left/right for the cell if there was no insideH/insideV.
thanks - dave
What we did for the last 6 months - Made the world's coolest reporting & docgen system even more amazing
Thursday, January 5, 2017 7:11 PM -
Hi again;
Please take a look at Bug_3193_b.docx. The document.xml has no borders set anywhere. The style ListTable1Light-Accent5 has no settings for left/right/insideH/insideV. It is basedOn TableNormal.
And TableNormal has:
<w:tblBorders> <w:top w:val="single" w:sz="4" w:space="0" w:color="ff0000"/> <w:left w:val="single" w:sz="4" w:space="0" w:color="ff0000"/> <w:bottom w:val="single" w:sz="4" w:space="0" w:color="ff0000"/> <w:right w:val="single" w:sz="4" w:space="0" w:color="ff0000"/> <w:insideH w:val="single" w:sz="4" w:space="0" w:color="00ff00"/> <w:insideV w:val="single" w:sz="4" w:space="0" w:color="00ff00"/> </w:tblBorders>
So why are there no vertical borders?
thanks - dave
What we did for the last 6 months - Made the world's coolest reporting & docgen system even more amazing
Thursday, January 5, 2017 7:37 PM -
Hello Dave:
Regarding this ----"But can you verify that for me? At present our code uses the table & style props for left/right for the cell if there was no insideH/inside."
I believe that following processing rule in section 17.4.24 in ISO 29500 answers your above query.
'If this element is omitted, then the inside vertical borders of this table shall have the border specified by the associated table style. If no inside vertical edge border is specified in the style hierarchy, then those cells in this table shall not have an inside vertical edge border.
'
Thanks
Tarun Chopra | Escalation Engineer | Open Specifications Support Team
- Edited by Tarun Chopra - MSFT Friday, January 6, 2017 6:34 AM
Friday, January 6, 2017 6:34 AM -
Hi Tarun;
Ok, everything except Bug_3193_b.docx now makes sense. But that document does have insideV/insideH set and yet they don't show. How come?
thanks - dave
What we did for the last 6 months - Made the world's coolest reporting & docgen system even more amazing
Friday, January 6, 2017 4:04 PM -
Hello Dave :
I'm looking into Bug_3193_b.dox. Hopefully will get back to you by today.
Thanks.
Tarun Chopra | Escalation Engineer | Open Specifications Support Team
Friday, January 6, 2017 4:42 PM -
Hello Dave:
Sorry for the delay.
Per analysis and help from teammates (Josh and Tom); we found that the behavior is by-design and is stated in following section of MS-OI29500, excerpt below:
2.1.240 Part 1 Section 17.7.4.17, style (Style Definition)
- The standard does not state any special behavior for "NoList", "DefaultParagraphFont", and "TableNormal" styles.
- Word ignores any child elements of a style element with id "NoList", "DefaultParagraphFont", or "TableNormal".
As the 'tblBorders' is specified in TableNormal style, it will be ignored by Word. In order to make it work, please move the 'tblBorders' to ListTable1Light-Accent5 style.
Thanks.
Tarun Chopra | Escalation Engineer | Open Specifications Support Team
- Proposed as answer by Tarun Chopra - MSFT Tuesday, January 10, 2017 5:49 AM
- Marked as answer by DavidThielen Sunday, July 16, 2017 4:43 PM
Tuesday, January 10, 2017 5:49 AM - The standard does not state any special behavior for "NoList", "DefaultParagraphFont", and "TableNormal" styles.
-
Hi;
If it's useful, the file Bug_3193_c.docx shows that Word ignores settings for those styles, even if that style is the table style (not conditional, not basedOn).
thanks - dave
What we did for the last 6 months - Made the world's coolest reporting & docgen system even more amazing
Sunday, July 16, 2017 5:39 PM -
Hello David:
Welcome back, it's good to hear from you. I'll look into your file and get back.
Thanks
Tarun Chopra | Escalation Engineer | Open Specifications Support Team
Sunday, July 16, 2017 11:22 PM -
Had an offline discussion with David; the sample file he shared was to validate our earlier understanding. We don't need any further investigation; hence marking the post as answered.
Tarun Chopra | Escalation Engineer | Open Specifications Support Team
- Proposed as answer by Tarun Chopra - MSFT Tuesday, July 18, 2017 9:02 PM
- Edited by Tarun Chopra - MSFT Tuesday, July 18, 2017 9:03 PM
Tuesday, July 18, 2017 9:02 PM