Wrong exported paragraph indentation when the paragraph is in a table cell.
Workaround: Iterate table`s paragraphs and set the negative indentations to zero:
IEnumerable<Table> tables = this.document.EnumerateChildrenOfType<Table>();
foreach (Table table in tables)
{
IEnumerable<Paragraph> paragraphs = table.EnumerateChildrenOfType<Paragraph>();
foreach (Paragraph paragraph in paragraphs)
{
if (paragraph.Indentation.LeftIndent < 0)
{
paragraph.Indentation.LeftIndent = 0;
}
}
}
Revisions in WordprocessingML provide a mechanism for storing information about the evolution of the
document (i.e. the set of modifications made to a document by one or more authors).
foreach (ImageInline image in document.EnumerateChildrenOfType<ImageInline>().ToList())
{
UriImageSource uriImageSource = (UriImageSource)image.Image.ImageSource;
if (uriImageSource != null && !IsValid(uriImageSource.Uri.OriginalString))
{
image.Paragraph.Inlines.Remove(image);
}
}
private static bool IsValid(string uri)
{
try
{
Path.GetExtension(uri);
}
catch (ArgumentException)
{
return false;
}
return true;
}
<w:pict ...>
<v:shape ...>
<v:fill opacity="39151f"/>
<v:path .../>
<w10:wrap anchorx="page" anchory="page"/>
</v:shape>
</w:pict>
Wrongly imported/exported table cells from nested tables (see the picture below).
Currently, the hyperlink is exported not as hyperlink text only but additionally, all the field data is included.
Steps to reproduce:
editor.InsertHyperlink(text:"telerik", uri:"http://www.telerik.com", isAnchor:false, toolTip:"Telerik site");
Actual: HYPERLINK "http://www.telerik.com" \o "Telerik site" Telerik
Expected: Telerik
Workaround:
IEnumerable<Run> runs = document.EnumerateChildrenOfType<Run>();
foreach (Run run in runs.ToList())
{
if (run.Text.Trim().StartsWith("HYPERLINK"))
{
run.Paragraph.Inlines.Remove(run);
}
}
Add support for inline lists.
When the display attribute is set to inline all items should be on the same row (see attached)