Completed
Last Updated: 31 Jul 2017 08:48 by ADMIN
ADMIN
Tanya
Created on: 20 Jul 2017 17:18
Category: WordsProcessing
Type: Bug Report
0
WordsProcessing: Normal is not assigned as a paragraph style when such is not explicitly applied to the element
When a paragraph doesn't have applied a style, the Normal style should be automatically applied. Currently, similar paragraph obtains its style from the parent.

This is reproducible when exporting to PDF and RTF.

Workaround: Check if there is a paragraph without style ID and if so, set it to Normal:

foreach (var paragraph in this.document.EnumerateChildrenOfType<Paragraph>())
{
    var value = paragraph.StyleId;
    if (string.IsNullOrEmpty(value))
    {
        paragraph.StyleId = "Normal";
    }
}

Available in LIB Version 2017.2.731.
0 comments